Re: [amibroker] Simulate several Pending orders

 

Hi again,


this template is working fine, but now that I'm addressing the the buyprice issue... it seems a bit bit tricky, since I'm considering that each position is opened at the price level defined in the order variable.

In one small range bar for example, only one order is triggered (which works fine in the example code you provided), but in a large range bar three orders might be triggered, and in this case the buy price must be a weighted average of those price levels defined in order variable (weighted by position size).

Do you see a simple approach for this or maybe I'm missing something?

Thanks in advance for your help,

BRegards,
pm


__._,_.___

Posted by: pmxgs0@gmail.com
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (0)

Check out the automatic photo album with 2 photo(s) from this topic.
ehgdcggj.png eeffiibe.png
Save time and get your email on the go with the Yahoo Mail App
Get the beautifully designed, lighting fast, and easy-to-use, Yahoo Mail app today. Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.

**** 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/


.

__,_._,___

Related Posts


EmoticonEmoticon

:)
:(
=(
^_^
:D
=D
=)D
|o|
@@,
;)
:-bd
:-d
:p
:ng
:lv