[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 your response, but I don't think 
that will do what I want. Here are a couple of the scans I use to create 
composite tickers for the Nasdaq and the NDX. I use these in some breadth 
indicators. Some of the discussion about the OLE Automation Object led me to 
believe that this process can be automated with some kind of script from outside 
of AmiBroker, however I just don't know how to do it. Any help would be 
appreciated. 
 

//Calculates composites for Nasdaq
//use Apply to|use filter|market|nasdaq
Filter=1;
nquppts=IIf<FONT 
size=1>(C>Ref<FONT 
size=1>(C,-1<FONT 
size=1>),C-Ref<FONT 
size=1>(C,-1<FONT 
size=1>),0);
nqdnpts=IIf<FONT 
size=1>(C<Ref<FONT 
size=1>(C,-1<FONT 
size=1>),Ref<FONT 
size=1>(C,-1<FONT 
size=1>)-C,0<FONT 
size=1>);
AddToComposite(nquppts, <FONT 
color=#ff00ff size=1>"~nquppoints", 
"x" ); 

AddToComposite(nqdnpts, <FONT 
color=#ff00ff size=1>"~nqdnpoints", 
"x" ); 

Buy = 0; 

 
//Calculates composites for NDX 
//use Apply to|use filter| Watchlist|Nasdaq 100 

Filter=1;
uppts=IIf<FONT 
size=1>(C>Ref<FONT 
size=1>(C,-1<FONT 
size=1>)AND V>0<FONT 
size=1>, C-Ref<FONT 
size=1>(C,-1<FONT 
size=1>),0);
dnpts=IIf<FONT 
size=1>(C<Ref<FONT 
size=1>(C,-1<FONT 
size=1>)AND V>0<FONT 
size=1>, Ref<FONT 
size=1>(C,-1<FONT 
size=1>)-C,0);
isup=IIf<FONT 
size=1>(C>Ref<FONT 
size=1>(C,-1<FONT 
size=1>),1,<FONT 
color=#ff00ff size=1>0);
isdn=IIf<FONT 
size=1>(C<Ref<FONT 
size=1>(C,-1<FONT 
size=1>),1,<FONT 
color=#ff00ff size=1>0);
dnvol=IIf<FONT 
size=1>(C<Ref<FONT 
size=1>(C,-1<FONT 
size=1>),V,0);
upvol=IIf<FONT 
size=1>(C>Ref<FONT 
size=1>(C,-1<FONT 
size=1>),V,0<FONT 
size=1>);
AddToComposite(uppts, <FONT 
color=#ff00ff size=1>"~Ndxuppoints", 
"x" ); 

AddToComposite(dnpts, <FONT 
color=#ff00ff size=1>"~Ndxdnpoints", 
"x" ); 

AddToComposite(isup, <FONT 
color=#ff00ff size=1>"~Ndxupstocks", 
"x" ); 

AddToComposite(isdn, <FONT 
color=#ff00ff size=1>"~Ndxdnstocks", 
"x" ); 

AddToComposite(upvol, <FONT 
color=#ff00ff size=1>"~Ndxupvol", <FONT 
color=#ff00ff size=1>"x"); 

AddToComposite(dnvol, <FONT 
color=#ff00ff size=1>"~Ndxdnvol ", 
"x" ); 

Buy = 0<FONT 
size=1>;
<BLOCKQUOTE 
>
  ----- Original Message ----- 
  <DIV 
  >From: 
  <A title=gkavanag@xxxxxxxxxxxxxx 
  href="">Graham 
  To: <A title=amibroker@xxxxxxxxxxxxxxx 
  href="">amibroker@xxxxxxxxxxxxxxx 
  Sent: Saturday, February 08, 2003 4:08 
  PM
  Subject: RE: [amibroker] Automating 
  Composite Updating
  
  
  <SPAN 
  >I think all you need is to use marketif() with in IIf 
  statement. I have done this to create composites of different sectors and 
  groups. Mine is just for the same scan against different sectors, but similar 
  I would say could be done with different scans and markets.
  <SPAN 
  >Here is example I do for the composite 
  name
  <SPAN 
  lang=EN-AU 
  >xyz = 
  WriteIf( SectorID()==1, "~BPIEgy",  "~BPIASX" ); 
  <SPAN 
  > 
  
  <FONT face="Times New Roman" color=blue 
  size=2><SPAN 
  >Cheers,<FONT 
  color=blue><SPAN 
  >Graham
  <SPAN 
  > 
  <SPAN 
  >-----Original 
  Message-----From: 
  SkruySkweril [mailto:scrombie@xxxxxxxxxxxxx] <SPAN 
  >Sent: Sunday, 9 February 2003 7:50 
  AMTo: 
  amibroker@xxxxxxxxxxxxxxx<SPAN 
  >Subject: [amibroker] Automating Composite 
  Updating
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >Hello,
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >I have a number of scans for 
  creating composites that I run each day on several different markets and 
  watchlists. It's very time consuming because I've been pulling up each scan, 
  one at a time, changing the setting in "Apply to" and waiting until that is 
  finished and then repeating until all my composites are updated. Some 
  recent threads on this list have given me hope that a means to 
  automate the updating of these composites exist. However, I don't know where 
  to start. In pseudocode what I'm trying to accomplish is 
  this:
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >Use scan#1
  
  <SPAN 
  >Apply to 
  market#1
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >Use scan#2
  
  <SPAN 
  >Apply to 
  market#2
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >Use scan#3
  
  <SPAN 
  >Apply to 
  watchlist#1
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >Use scan#4
  
  <SPAN 
  >Apply to 
  watchlist#2
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >etc.
  
  <FONT face="Times New Roman" 
  size=2> 
  
  <SPAN 
  >I would very much appreciate if 
  someone could explain how this could be done or maybe even provide an example. 
  I'm sure that I'm not the only one that could benefit.
  <FONT face="Times New Roman" 
  size=2><SPAN 
  ><FONT 
  face="Courier New">Post AmiQuote-related messages ONLY to: 
  amiquote@xxxxxxxxxxxxxxx <SPAN 
  >(Web page: 
  <A 
  href="">http://groups.yahoo.com/group/amiquote/messages/)<FONT 
  face="Courier New">Check group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  Your use of Yahoo! Groups is subject to 
  the Yahoo! Terms of 
  Service. 
  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.