Equitycurve on the Chartpane
Author: mheb
Creation Date: 7/19/2011 9:18 AM
profile picture

mheb

#1
Hello
I tried to draw a equity curve on the chartpane using this code

CODE:
Please log in to see this code.


but I can't get the same profit as on the performance tab. did I missed something with the NetProfitAsOfBar
or has anybody already did the equitycurve on the chartpane.
any help appreciate

regards

michael
profile picture

Eugene

#2
QUOTE:
but I can't get the same profit as on the performance tab.

It shouldn't work. As the QuickRef remark states:
QUOTE:
In portfolio simulation mode, all trades are pre-executed using 1 share per Position, and then position sizing is applied after the fact. So NetProfitAsOfBarPercent will always be based on 1 share while the Strategy is executing.

QUOTE:
has anybody already did the equitycurve on the chartpane.

I. Yes, it's been awhile (ca. 5.1 times in 2009?) but after a minimal modification, the code still works with 6.2:

WealthScript Techniques | Interacting Dynamically with Portfolio Level Equity

Make sure to have Community.Components installed and carefully read all the remarks/notes (it's unofficial unsupported excercise).

II. Another approach (to get the portfolio equity): Limit Monthly Drawdown / Portfolio Equity Tracker
profile picture

mheb

#3
Hello Eugene

thanks for your quick reply, I'll test these solutions.

regards

michael
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).