Export Detailed Equity Curve Values from Optimization Report

Questions about MultiCharts and user contributed studies.
trader0311
Posts: 50
Joined: 28 Sep 2014
Has thanked: 7 times

Export Detailed Equity Curve Values from Optimization Report

Postby trader0311 » 19 Jul 2016

Hi,

I would like to run an optimization and somehow have the "detailed" or mark-to-market equity curves from each result of the optimization exported or written to an excel file.

I would like to do some additional analysis of the equity curves and need an easy way to get this into excel. At the moment I know of no easy way to do this. There might be 50 equity curves or 500. It all depends.

Is there some code that can be written to accomplish this? Or is there another way that I am not aware of?

User avatar
fbertram
Posts: 166
Joined: 16 Oct 2014
Location: Seattle, USA
Has thanked: 36 times
Been thanked: 76 times
Contact:

Re: Export Detailed Equity Curve Values from Optimization Re

Postby fbertram » 19 Jul 2016

Hi trader0311,

afaik, there is no straightforward way to do what you are trying to do, but there are workarounds. Here is what I would do:

make sure you have ELCollections installed.

create a MapNN like this:

Code: Select all

variable: ID(MapNN.New);
fill the map in your code like this:

Code: Select all

value1 = MapNN.Put(ID, date, YourEquity);
write the map to disk like this:

Code: Select all

value1 = MapNN.WriteFile(ID, "YourFileName.csv");
This code will create a CSV file with the date in the first column and the equity in the second column, which you can load into Excel. You will probably want to make sure that you assign different file names for every set of parameters, I leave that exercise to your imagination.

All the best, Felix

trader0311
Posts: 50
Joined: 28 Sep 2014
Has thanked: 7 times

Re: Export Detailed Equity Curve Values from Optimization Re

Postby trader0311 » 20 Jul 2016

Thank you so much for your help. I will look into this method and make sure I have the necessary ELCollections installed.


Return to “MultiCharts”