Max draw down coding.
Max draw down coding.
26 Apr 2013, 08:17
Hi,
please give me the right way to code the max draw down so it is inline with the way you calculate the back testing draw down.
Account.Balance is used I would think and based on historical high and declining low.
Thanks..
Replies
kricka
26 Apr 2013, 17:22
Hi,
tried to compile /forum/calgo-reference-samples/823 and came up with an error. Please correct so I can test and use the sample.
Thanks..
@kricka
cAlgo_Fanatic
26 Apr 2013, 18:01
Can you please recopy the code and let us know if you get the error? Also, let us know what error you are getting.
@cAlgo_Fanatic
cAlgo_Development
30 Apr 2013, 12:50
OK, code is corrected. Refresh the page and try again please.
@cAlgo_Development
cAlgo_Fanatic
26 Apr 2013, 11:31
Please see this sample for Max DrawDown.
In the example this is the function that calculates it which is called when the position closes, in the OnPositionClosed event:
@cAlgo_Fanatic