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

Re: [amibroker] is this a valid system.



PureBytes Links

Trading Reference Links

John,
Unfortunately it is not valid. The expression "ValueWhen(x,C,0)" gets a future date. Apparently, the "n" argument in ValueWhen must be greater than 1 to get a 
date in the past. 

Bill S.


At 4/24/02 7:42:00 PM, you wrote:
> my second atempt of this post, as the first didnt make the 
>group.
>
>hi can anyone post a reply as to wether this formula is valid.
> I think i am having a prob understanding the valuewhen function, 
>because from checking it against the chart , it doesnt seem to do 
>what i was trying to write.
> it seems to get some very good results so it probably is looking 
>ahead in the tests.
> when running the explorer it will find stocks for the data on 
>the last bar, i thought if it looks ahead that it would not find an 
>exploration on the last bar as it would need to look past the last 
>bar to place a buy.
>
> Just curious if it is a valid system as the results are O.K.
> any simple explanation of this formula would help.
>
> thanks: john. 
>
>
>nn=(Cross(MA(C,5),C)); /*sell */ 
>
>x=Cross(C,MA(C,5)); /*buy */ 
>
>q=IIf(ValueWhen(nn,C,1)<ValueWhen(x,C,0),1,0);
>zz=IIf(q,Cross(C,MA(C,5)),0);
>Buy=zz;
>Filter=zz;
>Sell=Cross(MA(C,5),C);
>Buy=ExRem(Buy,Sell);
>
>Sell=ExRem(Sell,Buy);
>
>AddColumn(C,"c"); 
>
>
>
>
>
>
> 
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 
>
>
>
-----------------------------------------------------------------------------------------------------------------------
Bill Schmidt