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

Re: [amibroker] LAstvalue



PureBytes Links

Trading Reference Links

Thanks for responding Graham.

I solved it in a roundabout manner with the following code:

x=Osc>0;
OscLPV=ValueWhen(Cross(0,osc),Ref(Osc,-1),1);
pstv_osc=IIf(x,Osc,Osclpv);


Regards


R
On 12/24/06, Graham <kavemanperth@xxxxxxxxx> wrote:
>
> lastvalue gives the last value in the whole chart
> just remove the lastvalue part
>
>
> --
> Cheers
> Graham
> AB-Write >< Professional AFL Writing Service
> Yes, I write AFL code to your requirements
> http://www.aflwriting.com
>
>
> On 24/12/06, Rakesh Sahgal <rakeshsahgal@xxxxxxxxx> wrote:
> >
> >  Is the following the correct manner in which to record the LAST
> > POSITIVE value of an oscillator before the value becomes negative?
> >
> >
> > x=Osc>0;
> >
> > OscLPV=ValueWhen(x,LastValue(Osc),1);
> >
> > pstv_osc_val=IIf(x,Osc,Osclpv);
> >
> >
> > TIA for any help in correcting the above.
> >
> > Regards
> >
> >
> > R
> >
>
>
>
> 
>

Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.432 / Virus Database: 268.15.26/600 - Release Date: 12/23/2006 4:47 PM