PureBytes Links
Trading Reference Links
|
One way is
BuyCond = YourNormalBuyConditions;
sell =YourSellConditions;
Buy = buyCond and barssince(Sell)>=3;
On 11/26/05, Roy Ewing <slickums76@xxxxxxxxx> wrote:
> I asked this before, no response, so maybe restating the issue might help.
>
> How can I backtest for the 3-day settlement period?
>
> The scenario is this, using a single stock example:
>
> 1. Buy in min 100 share blocks.
> 2. "All in" trading, so I must wait for "settlement" before I buy next
> pick.
> 3. I buy the stock, it hits my sell trigger, I then sell it.
> 4. I can't buy again for 3 days. Yes, I know the broker will "lend"
> you the money until settlement, but would prefer to not go the "free
> ride" route, yet.
> 5. After the 3rd day, my new (hopefully much larger) equity is
> available, and I am ready to trade again.
>
> So how to simulate this in backtesting?
>
> What I need is a simple function that says: "Buy IF last SELL was at
> least 3 days ago, OR equity >= buyprice*100 (min block size)",
> otherwise go to next bar.
>
> I have experimented with HOLD, but nothing close yet. It looks
> simple, so I hope I am just overlooking a function ready made to do this.
>
> Thanks for ANY ideas 8-).
>
> Roy
>
>
>
>
>
>
> 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 other support material please check also:
> http://www.amibroker.com/support.html
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
>
>
--
Cheers
Graham
AB-Write >< Professional AFL Writing Service
Yes, I write AFL code to your requirements
http://e-wire.net.au/~eb_kavan/ab_write.htm
------------------------ Yahoo! Groups Sponsor --------------------~-->
Try Online Currency Trading with GFT. Free 50K Demo. Trade
24 Hours. Commission-Free.
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~->
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 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/
<*> 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/
|