PureBytes Links
Trading Reference Links
|
Hello,
I have trouble finding coming up with the proper
code for determining the value of all open positions for any given day
(determined by the close!)
Is it this:
for (trade = bo.GetFirstOpenPos(); trade; trade = bo.GetNextOpenPos())
{
Value_open_positions = Value_open_positions + trade.GetPositionValue() trade.AddCustomMetric ("Open Position Value", trade.Value_open_positions);
} Incidentally, GetPositionValue doesn´t indicate if it uses closing prices.
__________ Information from ESET Smart Security, version of virus signature database 4581 (20091107) __________
The message was checked by ESET Smart Security.
http://www.eset.com
__._,_.___
**** 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/
__,_._,___
|
|