[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [amibroker] Automating Composite Updating



PureBytes Links

Trading Reference Links




Thank 
you for sharing you nice example!
<FONT face=Arial color=#0000ff 
size=2> 
<FONT face=Arial color=#0000ff 
size=2>Herman

  <FONT face=Tahoma 
  size=2>-----Original Message-----From: SkruySkweril 
  [mailto:scrombie@xxxxxxxxxxxxx]Sent: Sunday, February 09, 2003 2:50 
  PMTo: amibroker@xxxxxxxxxxxxxxxSubject: Re: [amibroker] 
  Automating Composite Updating
  I was able to solve my problem thanks to 
  Tomasz's example in the "readme" file documenting the changes for  AB 
  version 4.24.0. Although I know nothing about Jscript or OLE and had no hope 
  of being able to understand it, the example Tomasz provided was 
  clear enough that I only had to modify his example a little to suit my 
  need. I'm including my modified file so that others who might have similar 
  needs may benefit. To modify my file to suit your particular need, 
  you need only change the path in the AA.LoadFormula command to the path to 
  your AFL scan and change the AA.Filter command to whatever "market", "group", 
  "watchlist", etc. you wish to scan on. Repeat the section between the 
  /*********/ as many times as you have different settings to work with. Also, I 
  added the "Composites.js"  file as a command under Tools/Customize so 
  that updating my composites is now a one click operation. Is this a great 
  program, or what?
   
   
   
  /* create AB object */AB = new 
  ActiveXObject("Broker.Application");
   
  /* retrieve automatic analysis object */AA = 
  AB.Analysis;
   
  /* load formula from external file 
  */AA.LoadFormula("C:\\program 
  files\\amibroker\\afl\\composites\\UPDNpoints_s.afl");
  <FONT face=Arial 
  size=2>/************************************************************************************************/
  /* setup filters *//* backtest over symbols 
  present in market 0 only (zero-based number) */AA.ClearFilters(); 
  AA.Filter( 0, "market" ) = 1;
   
  /* set apply to and range */AA.ApplyTo = 2; 
  // use filtersAA.RangeMode = 0; // use all available quotes
   
  /* run backtest and display report 
  */AA.scan();
  <FONT face=Arial 
  size=2>/*************************************************************************************************/
   
  /* Composites # 2 *//* load formula from 
  external file */AA.LoadFormula("C:\\program 
  files\\amibroker\\afl\\composites\\nqUPDNpoints_s.afl");
   
  /* setup filters *//* backtest over symbols 
  present in market 0 only (zero-based number) */AA.ClearFilters(); 
  AA.Filter( 0, "market" ) = 3;
   
  /* set apply to and range */AA.ApplyTo = 2; 
  // use filtersAA.RangeMode = 0; // use all available quotes
   
  /* run backtest and display report 
  */AA.scan();
   
  /* Composites #3 *//* load formula from 
  external file */AA.LoadFormula("C:\\program 
  files\\amibroker\\afl\\composites\\NdxComposites_s.afl");
   
  /* optional: load settings */// 
  AA.LoadSettings("the_path_to_the_settings_file.abs");
   
  /* setup filters *//* backtest over symbols 
  present in market 0 only (zero-based number) */AA.ClearFilters(); 
  AA.Filter( 0, "watchlist" ) = 0;
   
  /* set apply to and range */AA.ApplyTo = 2; 
  // use filtersAA.RangeMode = 0; // use all available quotes
   
  /* run backtest and display report 
  */AA.scan();
   
  /* Composites #4 *//* load formula from external file 
  */AA.LoadFormula("C:\\program 
  files\\amibroker\\afl\\composites\\OnqComposites_s.afl");
   
  /* setup filters *//* backtest over symbols present in market 0 only 
  (zero-based number) */AA.ClearFilters(); AA.Filter( 0, "watchlist" ) = 
  2;
   
  /* set apply to and range */AA.ApplyTo = 2; // use 
  filtersAA.RangeMode = 0; // use all available quotes
   
  /* run backtest and display report */AA.scan();
   
  /* Composites #5 *//* load formula from external file 
  */AA.LoadFormula("C:\\program 
  files\\amibroker\\afl\\composites\\OnyseComposites_s.afl");
   
  /* setup filters *//* backtest over symbols present in market 0 only 
  (zero-based number) */AA.ClearFilters(); AA.Filter( 0, "watchlist" ) = 
  1;
   
  /* set apply to and range */AA.ApplyTo = 2; // use 
  filtersAA.RangeMode = 0; // use all available quotes
   
  /* run backtest and display report */AA.scan();Post 
  AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page: <A 
  href="">http://groups.yahoo.com/group/amiquote/messages/)Check 
  group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  Your use of Yahoo! Groups is subject to the <A 
  href="">Yahoo! Terms of Service. 







Yahoo! Groups Sponsor


  ADVERTISEMENT









Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html



Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.