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

[amibroker] Help on intraday scaleing into a trade



PureBytes Links

Trading Reference Links

I'm trying to average into a trade that is simulating an intraday 
trade with daily bars.  I have 3 price points to enter and i'm 
effectively averaging down.  I also want to only take at a maximum of 
10 trades, not counting the averaging down, even though I might have 
many more stocks that I could enter. So the only way that I could 
figure out is to use the following code:

// get the average price based on the low of the stock
BuyPrice = IIf(trigger8, (triggerprice * 1 + Lmt_price7 * 1 + 
Lmt_price8 * 1)/3, If(trigger7, (triggerprice * 1 + Lmt_price7 * 1)/ 
2,  Lmt_price  ));
// increase the number of shares based on how many time we average 
down
PositionSize = IIf(trigger8, -9, IIf(trigger7, -6, -3  ));

This code get the correct entry price and the correct number of 
shares, i.e. up to 3 times as many shares but because i'm changing the 
PositionSize variable I have lost control over limiting the maximum 
number of stocks to trade to 10.  I also want to use a percentage of 
the available equity so as the profit increase I will buy more shares.

I've played around with sigscalein and looked at the examples provided 
but they are different in that they seem to all using the Closing 
price for the extra entries and are  entering the stocks on multiple 
days, not the same day. I haven't been able to get anything to work 
with sigscalein.  Any ideas? I really stuck at this point.

Thanks,
Mark




------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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/