Birt's EA review
The truth the EA marketers don't want you to know.
The truth the EA marketers don't want you to know.
In general, backtesting using the data from the MT4 history center might be ok for EAs that are not scalping or pip hunting. If you’re dealing with such an EA or any kind of EA that closes trades within 1-15 pips, though, even the smallest feed differences might have a very large impact.
The issue is caused by the Metatrader terminal not having access to the real tick data, but only to minute bar data in the best case, which forces it to give your strategy backtest “false” ticks, generated through a process of interpolation of the data for the smallest timeframe available. This is most likely not important to an EA that uses a stoploss and takeprofit target of over 100 pips, but in the case of EAs that attempt to scalp a few pips here and there, your backtest could be totally misleading.
So, it is very important to try testing using data with a quality as high as possible, which is why I put together some resources, all of which I use in my backtesting when needed.
Dukascopy is universally acclaimed as one of the best brokers nowadays. Personally, I’ve never had anything to do with them so I cannot confirm or deny that, but many people classify it as “the best ECN broker” and I have yet to read bad things about them. From my point of view, their major drawbacks are the lack of a MT4 client (it’s possible to run MT4 EAs, but very tricky) and a very high minimum deposit limit.
Unlike many other brokers or data feed providers, Dukascopy offers free tick data spanning from April 2007 (for most currencies) to now. Despite being offered at no cost, it’s commercial-quality data and it actually approaches the 99% quality displayed in the strategy tests (which, by the way, is just a number in the FXT header). From what I can tell, it is updated hourly and the source is none other than the Dukascopy data feed server. Bottom line is: I couldn’t wish for a better data quality.
Since the data is downloaded in files that span only 1 hour, some tools are necessary to download and parse it. I’m a fan of the PHP simplicity, so I chose that to write the scripts. They’re not commercial quality code, but they work. Feel free to do whatever you want with the code, but don’t forget to give credit where it’s due.
Special note: these scripts are provided for the tech-savvy people who want to keep really up-to-date on their tick data. If you’ve no idea where to start with them, just ignore them and skip to the Prepared data section below.
You can download the archive here.
Edit 16.11.2009: updated the archive with the fix Futron posted in the comments section.
Edit 30.12.2009: updated the archive to fix a minor bug.
Edit 21.04.2010: updated the process script to resume if the output file exists, effectively allowing incremental CSV generation.
You will find 3 scripts inside:
A minimum requirement to run these scripts is a command line PHP with the CURL extension. If you’re using a windows box, I’m pretty sure there are installer packages with it, use the mighty Google to find one. On recent OS X releases it’s installed by default while on Linux distributions it might or might not be installed, but if it’s not, it’s typically easy to do it. I’ve only tested on Linux, but I don’t see why it shouldn’t work on other setups.
Due to the size of these files, it’s not feasible for me to host them, so I decided to upload them as torrents. To download these files, you will need a torrent client. For windows, I can recommend µTorrent – it’s very good, small and reliable torrent manager.
Please try to seed everything you download at least to 1.0 ratio.
The tracker hosting the torrent files is Legit Torrents, a tracker for legal torrents just like its name suggests. I thank them by these means for providing tracking services for the tick data torrents.
As a last piece of info before the links, I will update the files (by seeding new torrents) as my time permits, but, honestly, managing the torrents for each pair is a pain in the ass, which is why you shouldn’t expect them to be updated more than once per month.
To download the torrent files, just follow the links and click the torrent link in there.
It has been brought to my attention by a friend that Dukascopy prohibits redistributing the data, so I removed the torrent files, even though I think they are just provisioning against commercial redistribution. I will add a Windows do-it-yourself section instead.
Start by going to the windows PHP download section and fetching the latest binary version as a zip file.
Once you’ve done that, unpack it to c:\php\ and also unpack the scripts from dukascopy_php_scripts.zip in the same directory.
Rename c:\php\php.ini-development to c:\php\php.ini.
Edit c:\php\php.ini, search for
;extension=php_curl.dll
and remove the semicolon in front of the line and add an “ext/” in front of “php_curl.dll” so that it looks like this:
extension=ext/php_curl.dll
Save the file and exit.
Edit 21.04.2010: if you run into a zip error and your PHP installation has an ext/php_zip.dll, apply the above for extension=ext/php_zip.dll.
Click start->run and type
cmd
then click ok (or alternatively type
cmd
then hit enter in the windows 7/vista “search programs and files” box in the start menu).
Type
cd \php
in the command window.
Type
php download_dukascopy_data.php
Have a coffee. Have another coffee. Go sleep. Go to work. Go to the gym. Go to a club. Wait some more. I’m not kidding, it takes ages. You can check the progress by watching the currency pair directories get filled. You can change the array at the beginning of the file to switch the order or to remove some pairs you don’t want. The number next to each pair is the timestamp at which to start downloading. If you get any strange errors, run the process again when it’s finished – it will only download any files that were missed in the first step due to network errors.
Edit 23.11.2009: if you want to easily convert from a regular date to a unix timestamp, you can use Epoch Converter, a very easy to use online tool.
When the download is finished, assuming you wanted to get the EURUSD data up to 01.11.2009, you’d type
php process_dukascopy_data.php EURUSD 200702 200911 EURUSD.csv
and the output will be placed in EURUSD.csv.
Alternatively, you can type
process.bat
which will batch process all the currency data. It’s mostly safe to ignore the error spam at this step.
This should be it, if everything went ok you should have your CSV files in the same c:\php folder.
Warning: make sure you have enough space on your harddisk. The downloaded tick files have over 7.5 GB while the CSV files have close to 60 GB at the time of this writing.
Now, in order to use the CSV files, you need to perform some steps
I’ll go through each step below:
To convert the data to an FXT file (and the accompanying HST files) usable in Metatrader 4, you need a new script that you can download here.
This script is based on GainData2fxt.mq4, an older script by an author that I couldn’t determine and on FXTHeader.mqh, written by stringo@codebase.mql4.com. The first one has suffered major modifications at my hand, while the second one was only modified here and there to adapt it to the updated FXT header structure.
Edit 21.04.2010: this script has been updated to allow switching the GMT offset of the resulting FXT & HST files and to allow exporting the real spread in the file.
You have to perform the following steps in order to convert the CSV data:
After the script above has finished running, you will end up with a lot of files in your “experts\files” folder. At this point, exit the MT4 terminal then proceed to moving any .HST files from “experts\files” to “history\your_server_name”. Pay very close attention if you have multiple server directories in your “history” folder – you will have to move them into the one that’s correct for active account!
Note: unless you modify the CSV or get a new one, the HST files only need to be generated and moved once.
After moving the HST files, move the generated FXT file from “experts\files” to “tester\history”.
Since the recent MT4 clients no longer offer the ability to use custom FXT files, a special loader is needed. You can download it here, it works only with the MT4 version commonly known as 225 (version 4.00 build 225).
To use the files you created in a backtest, you will have to copy the exe inside fxt_loader.zip into the folder of your MT4 client and instead of running terminal.exe, run “fxt loader.exe”. If you’re worried about running executable files and you can do a manual patch, here are the offsets and data:
hex offset -> old byte -> new byte
1402FC -> EE -> 00
1402FD -> 02 -> 00
14041B -> 9D -> 00
14041C -> 01 -> 00
140521 -> 97 -> 00
What the loader does is disabling the MT4 default behavior to regenerate the backtest files every time you start a new test – so, if a file is already there, a new one will not be generated. By placing the FXT file you generated with the script in the tester\history folder, you ensure that it’s the file it is going to use for your backtest; of course, the selected backtest currency pair and timeframe must coincide with what you generated the FXT with.
Edit 24.09.2009: As an alternative to the loader above, you can use this loader which, in addition to what the other one does, will also let you run multiple instances of the terminal from the same installation folder. Read the comments below for more info and the patched offsets.
Edit 29.03.2010: Added a build 226 loader. It also includes an MQL script for the people who don’t want to run EXE files or who have particularly dumb antivirus packages; if you want to use the script version, start MT4 then put the script on any chart to enable the FXT functionality. However, keep in mind that while you can start more than an instance of the same MT4 client with the loader, you can’t do so with the script. If you want the patch offsets, they can be found in the script. Note that running the script on a build other than 226 (225 for example) will surely make it crash, so double check what build you’re running before you use it. On a separate note, you can make a similar script for build 225 by using the offsets posted above.
That’s easy: if your test is running and the file in tester\history was not recreated, it usually means everything is ok.
This is a sensitive issue for many EAs. The Dukascopy data seems to be GMT-based all around the year, so the GMT offset that you need to use is 0. As of 21.04.2010, the Dukascopy and Oanda MQL scripts have an external parameter that lets you specify the GMT offset you would like for the resulting data, both HST and FXT.
Gain Capital is the company behind forex.com. From what I hear, they’re a decent broker, but not one I would recommend. They’re the kind of “pushy” broker, I remember opening a demo account a few years ago and then getting several emails along the lines of “hi, are you going to open a live account already?” during the course of the next few months. What’s actually scary is that the emails were not automated.
Anyway, they also offer some free tick data. If you’re feeling a bit masochistic and want to play with it, I recommend using a download manager to fetch it. Fair warning: the quality is pretty bad – not only is the data missing large chunks of time, but it’s also sporting misaligned periods (e.g. you can sometimes find data from the previous week in the file for the current week).
Still, before finding the awesome Dukascopy data, I used this for testing so I perfected some scripts for it, available here.
Inside you will find:
Since these are totally obsolete to me, I’m not going to provide more details and you’re going to have to figure out how they work. Shouldn’t be too hard, though.
If you’re one of the lucky people who can get the Oanda tick data (it’s only available to people who have an account there funded with over 1k USD), get it in CSV format and use the Oanda2FXT MQL script. It works just like the Dukascopy2FXT script described above.
If you want your backtest to be even more accurate, as of 21.04.2010 you also have the option to use the real spread from the tick data. All you have to do is:
1. Make sure you’re using the latest Dukascopy MQL script or the latest Oanda MQL script.
2. When running the script, set UseRealSpread to true.
3. When loading the terminal, use the variable spread loader (which is different from the other loaders).
Note that as of now, this only works on Metatrader 4 build 225. I don’t think I’ll be making one for 226 anytime soon, so if there’s anyone who fancies asm and thinks they can handle porting it to 226, here’s what I changed:
00401323 DA0D 36134000 FIMUL DWORD PTR DS:[401336]
00401329 DB17 FIST DWORD PTR DS:[EDI]
0040132B E9 26020000 JMP terminal.00401556
00401336 A0860100 //100000
0040133A ACC52737 //0.00001
00401556 DA27 FISUB DWORD PTR DS:[EDI]
00401558 D815 3A134000 FCOM DWORD PTR DS:[40133A]
0040155E EB 12 JMP SHORT terminal.00401572
00401572 DFE0 FSTSW AX
00401574 F6C4 01 TEST AH,1
00401577 E9 E5020000 JMP terminal.00401861
00401861 DC42 1C FADD QWORD PTR DS:[EDX+1C]
00401864 74 06 JE SHORT terminal.0040186C
00401866 DC83 20030000 FADD QWORD PTR DS:[EBX+320]
0040186C C3 RETN
00541209 E8 1501ECFF CALL terminal.00401323
0054120E 90 NOP
A kind soul nicknamed xTrader1 has modified the process php script and made it export data that can be used in Ninjatrader. Quoting from his comment that is also available below if you’re into digging:
I tweaked your PHP script “process_dukascopy_data.php” in such a way, that it creates an original CSV file, but in addition 2 files Bid and Ask prices in ready to import NinjaTrader format.
He’s also been decent enough to send me the script and give me permission to host it here. Just as a disclaimer, I haven’t actually tested it so if it kills your dog or eats your babies I can’t be held responsible. Without further ado, I give link you the ninjatrader parse script. For some reason that I can’t explain, I got quite a kick out of naming the archive “dukascopy ninja script”.
For easier reference, here you go:
Dukascopy data download / parse scripts
Dukascopy MQL process scripts
MT4 build 225 FXT loader
MT4 build 225 FXT multiloader
MT4 build 225 FXT multiloader with variable spread
MT4 build 226 FXT multiloader and script
Gain Capital data tools
Oanda MQL Process script
August 11, 2010 - 10:22 PM
Hey birt.
I’ve managed to get quite a few 99% backtests under my belt now due to your instruction.
However recently, I haven’t (everything is coming back 90%). I thought I noticed this happened after having MT4 open for a while so I set each script created file (i.e. all my generated .hst’s, .fxt’s, etc.) to ‘Read Only’.
As well, I kept copies of the script generated files, and after every successful backtest I routinely delete the HSTs and FXTs that even I copied into the correct directories, and then re-paste in my backup ones for that pair.
Here’s what my setup is:
I have shortcut folders to every correct folder each file is supposed to got to (i.e. .hst’s, .fxt’s, etc.). So that makes sure I’m placing my files into the correct directories.
I also shut down the platform and ONLY use the launcher to reopen it.
At this point I don’t know what I may be doing incorrectly to now be getting 90% quality.
Please advise.
August 12, 2010 - 5:36 AM
Just re-read through your instructions above, and I may be erring in my testing pairs in timeframes that their FXT was not created for.
I may have mistakenly thought that one set of generated FXT and HST files for a pair covered ALL timeframes for that pair.
Still running a backtest now to see if things are working at least as the original instructions says they should (I’ve generated FXTs and HSTs for a specific pair and timeframe, and am running the backtest only on that same exact pair and timeframe).
also fyi: using the correct loader; and avidly sticking with MT4 version 4.00 build 225 (I’ve even gone as far as to delete the “LiveUpdate.exe” file)
August 12, 2010 - 8:32 AM
As you probably found out with certitude by now, the problem is definitely the timeframe. An FXT generated for a timeframe will not work on a different timeframe.
August 13, 2010 - 5:58 PM
YEP!
Worked like an old charm (i got back to 99% modeling quality) when I just stuck to the formula of generating a specific timeframe on a specific pair, and ONLY backtesting on those two specifics.
Thanks for responding anyways, you’re always there for us.
Best Regards.
August 12, 2010 - 8:44 AM
hi Birt !
Very much appreciated with your valuable info posted here. But could i ask one thing pls?
Is there a way to have dukascopy’s tick data stream in real-time on my mt4 platform?
I checked out your mql script but I think it’s only for backtesting purposes.
any advice will be much appreciated
August 12, 2010 - 9:31 AM
To put it simply, no.
Actually, if Dukascopy offers a data feed interface, it might be possible to write a bridge that allows a MT4 server to use Dukascopy feed data, but you’d need a MT4 server license (which is prohibitively expensive), a Dukascopy feed account and the knowledge to program such a bridge (or perhaps the money to buy an existing one, there might be such a thing since they have a MT4 implementation).
Speaking of which, you might want to try their MT4 demo, perhaps that’s what you need.
August 12, 2010 - 10:56 AM
dukascopy told me the other day they won’t be releasing the mt4 it seems. Only their java platforms and iphone etc.
well – much appreciated and on with my search !
many thanks
August 13, 2010 - 11:44 AM
Hi,
First I want to say THANKS for this real good work. I’m using this backtests for 3 months now and everything is perfect. I use the variable spread loader and it works at the perfection. The only problem is that we are using tick data (and spread) from a broker that does not have an MT4 platform working. So, I’m testing the backtesting results from my EA’s in brokers like (FXCBS, FXOPEN, IAMFX, ATCBROKERS, …) with different results.
SO, what I want to ask you is if it is possible to have a downloading script for any of this brokers data.
Best regards and thank you again
Pedro
August 15, 2010 - 6:05 PM
Well, unfortunately, none of the brokers you mentioned offers tick data like Dukascopy does so it wouldn’t be possible to have such a solution for them.
August 17, 2010 - 7:25 AM
Hi,
Since I will be using the Dukascopy tick data for backtesting. Shouldn’t the number of digits used in my EA is 4? instead of 5 (irregardless of my LIVE/DEMO broker) ?
I am using Alpari for trading. My understanding is Alpari is a 5 digits broker, so I set the SPREAD parameter to 20 ??
Thanks.
August 17, 2010 - 7:52 AM
I’m not entirely sure what the question is.
Alpari is a 5 digit broker, so if you set the spread to 20, your spread will be 2 pips.
As for the EA, if you’re writing it, I suggest you write it to autodetect whether it’s being used on a 4 or a 5 digit broker.
August 18, 2010 - 2:03 PM
Hello.
Do I need to delete the csv file whenever I download again to obtain the recent tick?
August 18, 2010 - 2:30 PM
No, you don’t have to delete it. The processing script will append data to the CSV, so if you processed say, up to August 2010, next time you run the script you can indicate 201008 as a start date (if using the same CSV) and it will “resume” adding data.
However, keep in mind that this might screw up your file if you don’t use whole months.
August 18, 2010 - 2:43 PM
What if I forgotten to change the startDate? Will it retreieve again the previous startDate data?
Do you mean we should download full month data? i.e. Jan-2010 – July 2010.
August 18, 2010 - 3:22 PM
What I mean is that if you do:
php process_dukascopy_data.php EURUSD 200801 200901 eurusd.csv
it will create a file with all 2008 data, up to (but not including) 01 January 2009.
If (without deleting the csv) you proceed with:
php process_dukascopy_data.php EURUSD 200901 201001 eurusd.csv
it will append the 2009 data to the existing csv (up to January 2010).
If however, you use 201009 as end date, seeing that August 2010 is not over yet, your file will be a mess if you try to resume it because it will be up to e.g. 18.08, so if you resume using 201008 as start date you will get duplicated 01-18.08 and if you resume using 201009, you will get missing 18-31.08.
There’s no automatic retrieval of the end date or of the start date or anything like that.
August 19, 2010 - 4:34 AM
I think I must be doing something wrong that I can’t seem to figure out. I followed the instructions to a tee but when I attempt to run the back test using “every tick” in the tester, I get the error, “no data for testing” in the journal page. I’ve checked that the .hst and .fst files are in the appropriate location. I can see the data in the history center and my chart shows the data from the .hst files. Next when I attempt to run the back test using “control points” the tester works and it creates a new .fxt file. I’m using version 225. Any help would be appreciated as this one is driving me crazy! Much thanks,
Dean
August 21, 2010 - 8:32 AM
I’m afraid I can’t pinpoint the source of your problem. If I remember correctly, the “no data for testing” message comes up when your history file doesn’t have data for that timeframe and the timeframes below it.
A few things to check:
- are you running the backtest on the same timeframe as the one you generated the FXT for?
- does a different EA result in the same error?
- does doing it all on a different MT4 terminal result in the same messsage?
August 19, 2010 - 3:43 PM
Hi,
My earlier installation generates the OrderSend Error 131. Seems like the fxt files are wrong. So…I am re-doing everything again.
To convert csv into hst/fxt, I did the followings:
1. install a fresh MT4.
2. start MT4 with a newly created demo account
3. delete demo acct and restart MT4
4. ignore creation of new demo acct.
5. open desired pair in M1
6. run script with createHST=true
7. repeat #5/6 (createHST=false) for all timeframes.
Once completed, copy the hst files into history\AlpariUK-Demo and fxt files into tester\history.
Am I missing something?
August 21, 2010 - 8:18 AM
I never said you should delete the demo account. That’s most likely the cause of your problem. If skipping that step doesn’t fix it, try a different EA, OrderSend Error 131 can also result from improper lot calculation.
August 21, 2010 - 7:22 PM
Hey birt, Things are goin well for me now. Backtesting a lot of ea’s now.
Had a quick question for you in regard to your Dukascopy2FXT script:
Is it possible to run this script simultaneously on a few different charts (that we open in the same MT4 window as the first chart), so we can have the script generating fxt’s and hst’s for more than one pair/timeframe at a time?
I haven’t tried it so I thought I’d ask before wasting any time with the attempt.
Thanks in advance
August 22, 2010 - 10:53 AM
Yes, you can run the script on as many charts as you want within the same MT4 client. However, this won’t result in faster processing, the total processing time being close to equal to the time that would be necessary to process them in sequential order. There is however a benefit if you start the script on multiple charts before going away from the keyboard for an extended time (such as overnight).
If you want faster processing and you have a multiple core CPU (or perhaps more than a CPU), you can take advantage of that by opening as many MT4 instances as the number of cores present (the loader should let you start the same MT4 more than once) and starting the script in each of them (on a single or multiple charts).
August 22, 2010 - 9:17 AM
Hi Birt, I noticed that some downloaded dukaskopy tick files are 0kb size, I also tried manual download of missing data from 0kb files from dukascopy web site but I’m not able to resolve this issue.
There are several days with 0kb sizes, indeed I received warnings when process files: “WARNING: 0 sized …”, I just ignore this or is it possible to obtain all data without 0kb in size ? also I ask you how much this issue could affect backtest results, thanks.
August 22, 2010 - 10:43 AM
If you read the information in these posts you would see that this is due to weekends. There is no data on the weekends but they are still recorded, hence – 0kb.
August 22, 2010 - 10:52 AM
Hey Birt, I have a question –
I programmed a multi-timeframe EA that I would like to backtest as thoroughly as possible. Am I correct in assuming that generating an M1 .FXT file is the closest I can get? There is no point in generating the .FXT file for each time frame, is there?
August 22, 2010 - 10:59 AM
It doesn’t really matter. The indicators take the data from the HST files, not from the FXT files. As long as the HST files are in place, the timeframe of the FXT does not matter at all, assuming that all your indicator calls are done using hardcoded timeframes.
If, however, your EA is supposed to run on M1 with the indicators using M1 bars and on M5 with the indicators using M5 bars and so on, I’m afraid that you will have to generate an FXT for each timeframe.
To sum up:
- if by “multitimeframe” you mean your EA is basing its decisions on indicators that run on hardcoded timeframes, not necessarily the same timeframe as the EA, then the FXT timeframe doesn’t matter.
- if by “multitimeframe” you mean it’s supposed to work on multiple timeframes, with the indicators using the same timeframe as the EA, then you’ll have to generate FXT files for each timeframe you intend to run it on.
August 24, 2010 - 3:09 AM
Hi, may I know what is the timezone used in the tick data? I am using Alpari UK. Thanks.
August 25, 2010 - 12:51 PM
Quoting from comment #66 on page 2 by gigi:
August 25, 2010 - 9:39 AM
Hi Birt any plans or any possibilities for this system in MT5 as well?
August 25, 2010 - 12:55 PM
I have no plans regarding MT5. I lost interest in Forex lately, I didn’t even check out MT5 backtesting.
August 25, 2010 - 1:43 PM
Hi Birt,
This is excellent. Unfortunately I found your blog after I purchased some TickData.
The procedure(s) above covers tick data from Duskacopy, Oanda and GainCapital. Is there a generic approach to converting tick data. I recently purchased data from fxtickdata.com and am now trying to figureout how to import it to MT4
August 26, 2010 - 8:09 AM
Unfortunately, no, there is no generic approach. However, if you know some programming, you might be able to adapt my scripts to your data format.
August 27, 2010 - 6:25 AM
hi,
Since I type php download_dukascopy_data.php
It start download from AUDJPY pair. haha
1. May I know what shall I type in dos to download only EURUSD pair ?
Since we only trading EURUSD pair only and we only need backtest EURUSD pair.
thanks
your answer is appreciated by MJ
August 27, 2010 - 8:13 AM
If you only want the EURUSD data, you need to edit the download_dukascopy_data.php file and remove all other pairs from the $currencies array.
August 27, 2010 - 10:59 AM
Mr. Birt
What a effective you are !! so fast you reply!!
Mr. birt, you really do me a big favor !!
thanks for your kindness.
you save my ages. haha
thanks for your fast reply.
sincerely.
MJ
August 28, 2010 - 1:29 PM
Hi all, anyone know where I can download past economic calendar? Thanks.
August 28, 2010 - 3:30 PM
See http://www.forexfactory.com/showthread.php?t=16364 – there’s also an archive starting from 2006.
August 29, 2010 - 3:41 AM
Thanks Birt.
I was looking for a site to download all calendar-dd-mm-yyyy.csv (like dailyfx) as I have wrote a mql4 script to display for events on the chart.
September 2, 2010 - 10:41 PM
Hello Birt and everybody,
I have noticed that the backtesting speedy for the data before 2009-2010 is much slower than backtesting 2009-2010.
For instance if I run a backtesting at the same time from 200801 and from 200901, the 2009 backtesting is already on August at the same time the 2008 data is still in April.
Anyone realise the same thing? Birt do you now if there is any diference in the data to generate this speedy difference?
Best regards,
emc
September 3, 2010 - 8:24 AM
The difference is the number of ticks. It’s probably also visible in the file sizes.
September 3, 2010 - 5:48 AM
I also wanted to change leverage as Alpari Uk demo account always uses 1:100 though real accounts get 1:500 .
As birt advised, i changed the FXTHEADER.mq4 and recompiled the Dukascopy script and created FXT afresh . I am using 225 multiloader for variable spread also.
May i know where are you setting the leverage? And how can we check what leverage is being used while testing?
Thanks in advance Birt & Xtrader1
September 3, 2010 - 8:29 AM
You only have to change the leverage in the line reading “int i_leverage=100;” in FXTHeader.mqh, then proceed to recompiling Dukascopy2FXT.mq4, after which you regenerate your FXT. If you already did that, there are two ways you can check:
1. Write an EA with just Comment(AccountLeverage()); in either it’s start() or init() function and backtest it with visual mode enabled.
2. Hexedit the FXT file and examine the value at the leverage offset. I forgot the offset, but you can find it among the comments above, on page 2 I believe.
September 3, 2010 - 1:55 PM
Did the first solution and its showing 500.
I hope it does the same while backtesting too as i have an EA which is depending upon the margin % level to trade or shut down.
Thanks
September 3, 2010 - 2:12 PM
is there any way to check whether Variable spread generated FXT with variable spread multiloader for 225 is actually using variable spread or not? or shows on chart? What is to be done to check that, esp when you said you didn’t do extensive testing about variable spread testing. Thanks in advance.
September 3, 2010 - 4:32 PM
Make a new EA and add the following to the start() function:
Comment(“Current spread: ” + DoubleToStr((Ask – Bid) / Point, 0));
Backtest it with visual mode enabled.
September 3, 2010 - 10:51 PM
Sorry to ask now if asked before but when we append complete months to csv file, I’m wonder if that is also possible with hst… and how?
Thanks in advance
Pedro
September 3, 2010 - 10:54 PM
Maybe if I do the script onle for that month and then import with history center… do you agree on this?