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

Re: [amibroker] Plotforeign



PureBytes Links

Trading Reference Links




Jayson,
 
donīt wanna cause you a headache. I never thought 
creating the IM200īs in AB would be such a big deal.
 
Well, here comes the code:
 
1./ in indicator builder
 

sym="~"+IndustryID(1);
C=Foreign(sym,"C");
O=Foreign(sym,"o");
H=Foreign(sym,"h");
L=Foreign(sym,"l");
V=Foreign(sym,"V");
I=Foreign(sym,"I");
x=C/I; 
PlotForeign("x",sym,colorRed,styleLine|styleOwnScale);
2./ in exploration<FONT 
face="Courier New" color=#000000>
Filter=Minimum=<FONT 
face="Courier New" color=#0000ff>MA<FONT face="Courier New" 
color=#6600aa>(<FONT face="Courier New" 
color=#000000>Volume<FONT face="Courier New" 
color=#6600aa>,50<FONT 
face="Courier New" color=#6600aa>)>=<FONT face="Courier New" 
color=#ff00ff>20000 
AND<FONT 
face="Courier New" color=#6600aa> <FONT face="Courier New" 
color=#000000>Close<FONT face="Courier New" 
color=#6600aa>>=<FONT face="Courier New" 
color=#ff00ff>5.00 <FONT 
face="Courier New" color=#000000>AND<FONT face="Courier New" 
color=#6600aa> StrLeft<FONT 
face="Courier New" color=#6600aa>(<FONT face="Courier New" 
color=#0000ff>Name(),<FONT 
face="Courier New" color=#ff00ff>1<FONT face="Courier New" 
color=#6600aa>) != "!"<FONT 
face="Courier New" color=#6600aa> <FONT face="Courier New" 
color=#000000>AND 
(StrRight<FONT 
face="Courier New" color=#6600aa>(<FONT face="Courier New" 
color=#0000ff>Name(),<FONT 
face="Courier New" color=#ff00ff>2<FONT face="Courier New" 
color=#6600aa>) != " 
P");
sym="~"<FONT 
face="Courier New" color=#6600aa>+<FONT face="Courier New" 
color=#0000ff>IndustryID<FONT face="Courier New" 
color=#6600aa>(1<FONT 
face="Courier New" color=#6600aa>); <FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * <FONT face="Courier New" 
color=#000000>C<FONT face="Courier New" 
color=#6600aa>,sym,"C"<FONT 
face="Courier New" color=#6600aa>);<FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * <FONT face="Courier New" 
color=#000000>O<FONT face="Courier New" 
color=#6600aa>,sym,"O"<FONT 
face="Courier New" color=#6600aa>);<FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * <FONT face="Courier New" 
color=#000000>H<FONT face="Courier New" 
color=#6600aa>,sym,"H"<FONT 
face="Courier New" color=#6600aa>);<FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * <FONT face="Courier New" 
color=#000000>L<FONT face="Courier New" 
color=#6600aa>,sym,"L"<FONT 
face="Courier New" color=#6600aa>);<FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * <FONT face="Courier New" 
color=#000000>V<FONT face="Courier New" 
color=#6600aa>,sym,"V"<FONT 
face="Courier New" color=#6600aa>); <FONT face="Courier New" 
color=#0000ff>
AddToComposite(<FONT 
face="Courier New" color=#000000>Filter<FONT face="Courier New" 
color=#6600aa> * 1<FONT 
face="Courier New" color=#6600aa>,sym,<FONT face="Courier New" 
color=#ff00ff>"I"<FONT face="Courier New" 
color=#6600aa>);
Buy=<FONT 
face="Courier New" color=#ff00ff>0<FONT face="Courier New" 
color=#6600aa>;
I tried to mimic Ronīs requirements 
for building the indexing filter as close as I could but am not sure at this 
point if itīs just similar or exactly the same.
Anyways, what leaves me puzzled mainly 
is that the same index line chart is displayed and  n o t  the one 
making up the group the selected stock belongs to.
Again, donīt cause yourself a 
headache.
Appreciate your help and hope to pay back 
once!
Markus
 
<BLOCKQUOTE 
>
  ----- Original Message ----- 
  <DIV 
  >From: 
  <A title=jcasavant@xxxxxxxxxxxx 
  href="">Jayson 
  To: <A title=amibroker@xxxxxxxxxxxxxxx 
  href="">amibroker@xxxxxxxxxxxxxxx 
  Sent: Wednesday, May 07, 2003 4:22 
  PM
  Subject: RE: [amibroker] 
Plotforeign
  
  <SPAN 
  class=705331914-07052003>Markus,
  send 
  me your whole afl (either here or privately) and I will have a 
  look
   
  Regards,
   
  Jayson 
  <FONT face=Tahoma 
  size=2>-----Original Message-----From: <A 
  href="">funnybiz@xxxxxx 
  [mailto:funnybiz@xxxxxx]Sent: Wednesday, May 07, 2003 10:07 
  AMTo: <A 
  href="">amibroker@xxxxxxxxxxxxxxxSubject: 
  Re: [amibroker] Plotforeign
  Graham,
   
  thanks for caring.
   
  Well, my index chart is based on EOD data and 
  created by addtocomposite.
   
  I rebuild it every day.
   
  The thing that concerns me is that the index 
  chart (i.e. the group index) is always the same no mater from which index 
  group the stock comes from.
   
  Do you know what I mean??
   
  Markus
  <BLOCKQUOTE 
  >
    ----- Original Message ----- 
    <DIV 
    >From: 
    <A title=gkavanagh@xxxxxxxxxxxxx 
    href="">Graham 
    To: <A title=amibroker@xxxxxxxxxxxxxxx 
    href="">amibroker@xxxxxxxxxxxxxxx 
    Sent: Wednesday, May 07, 2003 1:38 
    PM
    Subject: RE: [amibroker] 
    Plotforeign
    
    
    <SPAN 
    >Is the index a live chart 
    updated daily with external data, or a composite? If composite then you need 
    to renew the composite daily
    <SPAN 
    > 
    
    <FONT face="Times New Roman" color=teal 
    size=3><SPAN 
    >Cheers,<FONT 
    color=teal size=3><SPAN 
    >Graham
    <FONT 
    face="Times New Roman" color=#339966 size=2><SPAN 
    ><A 
    href=""><SPAN 
    >http://groups.msn.com/ASXShareTrading
    <FONT 
    face="Times New Roman" color=#339966 size=2><SPAN 
    ><A 
    href=""><SPAN 
    >http://groups.msn.com/FMSAustralia
    <SPAN 
    >-----Original 
    Message-----From: <A 
    href="">funnybiz@xxxxxx [mailto:funnybiz@xxxxxx] 
    Sent: Wednesday, 7 May 
    2003 6:36 PMTo: Amibroker 
    (Yahoo-Forum)Subject: 
    [amibroker] Plotforeign
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >Hello,
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >Iīve noticed that the index I 
    wanted to overlay to stock charts remains always the same (at least looks 
    like).
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >Could someone please tell me 
    why?
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >Thanks a 
    lot
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >Markus
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <SPAN 
    >- - - - - 
    
    
    <FONT face="Times New Roman" 
    size=2> 
    
    <FONT face="Courier New" color=#6600aa 
    size=2><SPAN 
    >sym=<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"~"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >+<FONT 
    face="Courier New" color=blue><SPAN 
    >IndustryID<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >1<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=black 
    size=2><SPAN 
    >C<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"C"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=black 
    size=2><SPAN 
    >O<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"o"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=black 
    size=2><SPAN 
    >H<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"h"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=black 
    size=2><SPAN 
    >L<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"l"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=black 
    size=2><SPAN 
    >V<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"V"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=#6600aa 
    size=2><SPAN 
    >I=<FONT 
    face="Courier New" color=blue><SPAN 
    >Foreign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(sym,<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >"I"<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Courier New" color=#6600aa 
    size=2><SPAN 
    >x=<FONT 
    face="Courier New" color=black><SPAN 
    >C<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >/I; 
    <FONT face="Courier New" color=blue 
    size=2><SPAN 
    >PlotForeign<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >(<FONT 
    face="Courier New" color=fuchsia><SPAN 
    >x<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >,sym,<FONT 
    face="Courier New" color=black><SPAN 
    >colorRed<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >,<FONT 
    face="Courier New" color=black><SPAN 
    >styleLine<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >|<FONT 
    face="Courier New" color=black><SPAN 
    >styleOwnScale<FONT 
    face="Courier New" color=#6600aa><SPAN 
    >);
    <FONT face="Times New Roman" 
    size=2><SPAN 
    ><FONT 
    face="Courier New">Send BUG REPORTS to bugs@xxxxxxxxxxxxx<FONT 
    face="Courier New"><FONT 
    face="Courier New">Send SUGGESTIONS to 
    suggest@xxxxxxxxxxxxx<FONT 
    face="Courier New">-----------------------------------------<FONT 
    face="Courier New">Post AmiQuote-related messages ONLY to: 
    amiquote@xxxxxxxxxxxxxxx (Web 
    page: <A 
    href="">http://groups.yahoo.com/group/amiquote/messages/)<FONT 
    face="Courier New">--------------------------------------------<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. 
    Send BUG REPORTS to bugs@xxxxxxxxxxxxxSend 
    SUGGESTIONS to 
    suggest@xxxxxxxxxxxxx-----------------------------------------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. 
    Send BUG REPORTS to bugs@xxxxxxxxxxxxxSend 
  SUGGESTIONS to 
  suggest@xxxxxxxxxxxxx-----------------------------------------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. 
  Send 
  BUG REPORTS to bugs@xxxxxxxxxxxxxSend SUGGESTIONS to 
  suggest@xxxxxxxxxxxxx-----------------------------------------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












Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
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.