[TUTORIAL] Complete Backtesting and Analysis Setup (100% Free)

Here’s is the parameters. I converted 1M to 15 M.

Check if you have given your “terminal.exe” administrator privileges so that it’s allowed to write/read files from your [I]experts/files[/I] folder. I assume you have installed the root folder in your Program Files (x86).

I have a feeling you’re trolling me.

If not, once again, your .mq4 files are ONLY used to modify the source code. You CANNOT do anything with them with your MT4 until you’ve compiled them to generate the matching .ex4 file. MT4 only uses .ex4 files.

Yeah, you’are absolutely right. Now i got it.
Thank you very much Clark.!!

Awesome! It’s great that you got it working. :slight_smile:

It turns out it was a problem with their latest metatrader build not compiling. Apparently the older mt4s do it fine, but I haven’t had much luck with it.

ClarkFX, first of all thank you for a very nice detailed post. I am still reading it all. I see your py code converts csv data to hst file, but was wondering if you have a PY code that will convert HST file to CSV file? My broker is FXDD, and they provide more than 10 years of historic 1M data for their feed in HST format. I would like to use this data in non MT terminals but I have to first import it into MT4 history center and then from there export it to csv. so was wondering if there is an easier way to go from hst files to csv files. you can google “fxdd 1m data” and first link is the historic data.

thanks,

MetaTrader 4 has that capability itself. Simply load the chart and go to File -> Save As. It will save all data from that chart. To increase the display of your charts, go to Tools -> Options -> Charts tab -> Max bars in history & Max bars in chart.

ClarkFX, thank you for quick response. I was actually looking for a way to do the double hop import export process.

Here is what you are suggesting…

1: download data from fxdd.com
3: import hst file into MT platform
3: export data from MT platform to CSV

here is what I am looking for…

1: Download data from FXDD.com
2: convert hst file to csv using python

thanks,

The procedures end up with the same results. The first one just requires one extra step. Without creating any extra tools, it’s the only thing we can really do.

Great tutorial! Thanks :slight_smile:

Thanks alansach, glad you enjoyed it.

Hi Clark,

My testing always stops after day 1, any idea why? I ticked “use date” and set a range yet it always stop after the first day.

Thanks in advance!

Hi,

I was trying my hands out doing backtesting and imported dukascopy data and ran a new MT4 offline for backtesting. However I keep getting this error message. Answers I found seems to suggest I need to get online and then offline once, before this error will disappear. However, every time I get online, the data will be replaced by the server’s data and the dates are too little for backtesting on M5.

Any advice will be greatly appreciated.

Thank you so much ClarkFX for this wonderful tutorial. Simple, easy to read even easier to apply. A must for all backtesting EA’s. Thank you again bro

Hey guys, it appears that I had accidentally unsubscribed to this thread, so I wasn’t getting any notifications via email when questions popped up. I apologize. :slight_smile:

Have you set the ‘Max bars in history’ and ‘Max bars in chart’ correctly? It’s under Tools -> Options -> Charts. I have it currently set to 10,000,000 for both just to be safe.

Hope that helps or if you have already fixed it, please let others know.

G’day ClarkFX, hope all is well. Bro, just wondering what the conversion factor is for weekly and monthly charts with your D2MT4.py script. My broker opens 10pm Sunday and close 10pm Friday so I presume 7200 (5 x 1440) works for weekly but how do you factor in different days for the month? Also I noticed the buildinfo is 2005.12.24. Is this build still valid or is there an update version somewhere.Thanks Bro.

Hi,

I am currently using 10080 for weekly and 43200 for monthly.

Hope that helps. :slight_smile:

Thanks a ton!