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

Re: [amibroker] Backtesting with different selling delays according to an if condition



PureBytes Links

Trading Reference Links

Hello,

Yes of course it is possible. AmiBroker's REF() function accepts
VARIABLE periods.

In your example:

buy = ...something...
sell = your_original_sell_condition;

variabledelay = IIF( Open > 1.05 * Close, 0, -1 ); // delay is 0 close goes 5% below open otherwise delay is one day

sell = Ref( sell, variabledelay );

Best regards,
Tomasz Janeczko
===============
AmiBroker - the comprehensive share manager.
http://www.amibroker.com


----- Original Message -----
From: <torebecca@xxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Sunday, July 29, 2001 5:02 AM
Subject: [amibroker] Backtesting with different selling delays according to an if condition


> is it possible to back test so that for instance you have a buy
> condition that will buy at whenever you set in the settings... but
> the delay for selling varies according to an if condition
>
> ie
> if share goes down 5% in a day... sell at the close of that day
> else sell at the beginning of the next day...
>
> hopefully this one should be easy to answer ;)
>
>
>
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>