PureBytes Links
Trading Reference Links
|
First thing that comes to mind is, make sure MnGain has no Null values
in the array... this will, in my experience, cause the LLV & HHV
functions to stop working... use Nz() to remove all Nulls...
--- In amibroker@xxxxxxxxxxxxxxx, "Ken Close" <ken45140@xxx> wrote:
>
> I have the most basic statement using LLV but I get blank values in
the AA
> window.
>
> I am checking for the max gain over a period and the minimum (or lowest)
> gain over the same period.
>
> I have:
> AllDates = DateNum();
>
> Price0 = ValueWhen(Nmnth1,Price,1);
>
> Price1 = ValueWhen(Nmnth1,Price,2);
>
> MnGain = 100 * (Price0 - Price1)/Price1;
>
> Per1 = BarsSince(AllDates == StartDate);
>
> MnGainH = HHV(MnGain,Per1);
>
> MnGainL = LLV(MnGain,Per1);
>
> AddColumn(MnGain,"MnGain",1.2);
>
> AddColumn(MnGainH,"Highest MnGain",1.2,colorDefault, Col, 120);
>
> AddColumn(MnGainL,"Lowest MnGain",1.2,colorDefault, Col, 120);
>
>
>
> When I run this, I get proper results in the McGainH column and
blanks in
> the McGainL column.
>
>
>
> What detail am I missing in this?
>
>
>
> I have tried this line substituted,
>
> MnGainL = IIf(MnGain<0,LLV(MnGain,Per1),LLV(MnGain,25));
>
>
>
> And I get values where MnGain is > 0 and where the Period is a fixed 25
> instead of the Per1, and blank values where MnGain is < 0.
>
>
>
> It seems that LLV does not like the Per1 value for the period but
the HHV
> function works OK with Per1 as the Period. Why?
>
>
>
> Must be basic but can someone educate me on this simple problem?
>
>
>
> Thanks,
>
> Ken
>
------------------------------------
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|