PureBytes Links
Trading Reference Links
|
I'm not a guru, but I think if 'right extend' is not set on the
study, the LastValue() will return 0 because the last value of the
study array will be undefined.
--- In amibroker@xxxxxxxxxxxxxxx, "Bruce Nutter" <bdnutter@xxxx>
wrote:
> Gurus and Jayson
> I tried this code so I could see the difference between the two
> horizontal lines. But the results I get in the interpretation
window is
> shown below. Could some guru please tell me why this does not work.
(For
> those of you who might ask yes the labels of my horizontal study
lines
> are "re" and "su")
> Formula code:
> x=LastValue(Study("re"));
> y=LastValue(Study("su"));
> WriteVal(x);
> WriteVal(y);
> WriteVal(x-y);
> Interpretation window result:
> 0
> 0
> 0
>
>
> Bruce
>
> -----Original Message-----
> From: Jayson [mailto:jcasavant@x...]
> Sent: Tuesday, October 14, 2003 9:49 AM
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: RE: [amibroker] How do I subtract the difference between
two
> horizontal study lines? (in AFL)
>
> Brian,
> have a look in the help files for Study(). You can name your trend
line
> than call its value in a code.
>
> for instance in this exploration I have named 2 study lines and
called
> the last value of each and subtracted one from the other....
>
>
> Filter=C>0;
> x=LastValue(Study("s1"));
> y=LastValue(Study("s2"));
> AddColumn(x,"");
> AddColumn(y,"");
> AddColumn(x-y,"");
>
>
> Regards,
> Jayson
> -----Original Message-----
> From: Bruce Nutter [mailto:bdnutter@x...]
> Sent: Tuesday, October 14, 2003 12:26 PM
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: [amibroker] How do I subtract the difference between two
> horizontal study lines? (in AFL)
> Gurus,
> Does anybody know how to subtract between two horizontal study
lines in
> AFL code? I have to study lines that I move around to calculate
entry
> and exit points. What I'd like to do is to show that vertical
distance
> between these two horizontal lines in the interpretation window.
Would
> one of you gurus please let me know how to do this?
> Bruce
>
> Send BUG REPORTS to bugs@xxxx
> Send SUGGESTIONS to suggest@xxxx
> -----------------------------------------
> 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!
> <http://docs.yahoo.com/info/terms/> Terms of Service.
>
>
>
>
> Yahoo! Groups Sponsor
>
>
> ADVERTISEMENT
>
>
<http://rd.yahoo.com/M=244522.3707890.4968055.1261774/D=egroupweb/S=17
05
>
632198:HM/A=1595056/R=0/SIG=124p07ne0/*http:/ashnin.com/clk/muryutaita
ke
> nattogyo?YH=3707890&yhad=1595056> Click Here!
>
>
> <http://us.adserver.yahoo.com/l?
M=244522.3707890.4968055.1261774/D=egrou
> pmail/S=:HM/A=1595056/rand=181959293>
>
> Send BUG REPORTS to bugs@xxxx
> Send SUGGESTIONS to suggest@xxxx
> -----------------------------------------
> 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!
> <http://docs.yahoo.com/info/terms/> Terms of Service.
------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->
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 http://docs.yahoo.com/info/terms/
|