Hi, I was mixing and remixing data un some excel files and I was starting to think about the development of a macro do calculate the drawdown of an equity.
So I suppose I have the equity sotred trade by trade in the cells of my spreadsheet, I can graph it and from the graph evalutae the maximum drawdonw, it would be nice anyway to get the info elsewhere and maybe with some more details.
Before starting my visualbasic adveture I thought it would be better to ask whether something similar is already available.
Thanks, bye
smodato
has anybody developed an excel macro
-
- Contributing Member
- Posts: 7
- Joined: Sun Dec 19, 2004 7:41 pm
-
- Contributing Member
- Posts: 7
- Joined: Sun Dec 19, 2004 7:41 pm
OK, here's the spreadsheet, I've included Mark Johnson's "Thirteen" equity curve for an example of use. Appreciate any feedback from you or any else who uses it.
Read the Notes then press the button "Calc Ratios" on the "Go" sheet.
Cheers.
Fixed an error in drawdown calc and added drawdown length.
Read the Notes then press the button "Calc Ratios" on the "Go" sheet.
Cheers.
Fixed an error in drawdown calc and added drawdown length.
- Attachments
-
- Equity_Statistics.zip
- Equity_Statistics.xls is an Excel2002 spreadsheet, (~551KB)
- (180 KiB) Downloaded 1600 times
Last edited by bazzacontango on Wed Jan 19, 2005 7:15 am, edited 1 time in total.
Thanks, very much, I launche the macro on the file as downloaded and I got an error, run time 1004, the debugger showed this:
Selection.Sort Key1:=Range("M10"), Order1:=xlDescending, Header:= _
xlGuess, OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal inMrk Johnson's average of 5 worst DD calculation.
I will look into the code to understand it, it is a great job anyway, I'm sure it will help my analyses very much.
Bye
Smodato
Selection.Sort Key1:=Range("M10"), Order1:=xlDescending, Header:= _
xlGuess, OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal inMrk Johnson's average of 5 worst DD calculation.
I will look into the code to understand it, it is a great job anyway, I'm sure it will help my analyses very much.
Bye
Smodato
-
- Contributing Member
- Posts: 7
- Joined: Sun Dec 19, 2004 7:41 pm
-
- Contributing Member
- Posts: 7
- Joined: Sun Dec 19, 2004 7:41 pm
An updated version of the spreadsheet has been uploaded.
It fixes an issue with the drawdown initialization and added drawdown length calculation.
Note: the drawdown lengths and dates are sorted by longest drawdown, and do not correspond to the deepest drawdowns. So ddindex 1 row, has the deepest% and the longest in calendar days.
It fixes an issue with the drawdown initialization and added drawdown length calculation.
Note: the drawdown lengths and dates are sorted by longest drawdown, and do not correspond to the deepest drawdowns. So ddindex 1 row, has the deepest% and the longest in calendar days.