• Home
  • Forums
  • News
  • Calendar
  • Coins
  • Market
  • Login
  • Join
  • 10:20am
Menu
  • Forums
  • News
  • Calendar
  • Coins
  • Market
  • Login
  • Join
  • 10:20am
Sister Sites
  • Metals Mine
  • Energy EXCH
  • Forex Factory

Options

Bookmark Thread

First Page First Unread Last Page Last Post

Print Thread

Similar Threads

MQL4 - FileWrite not working in strategy tester 4 replies

Strategy Tester - multi-timeframe moving averages not working 3 replies

MT4 Strategy Tester Spread - pips or points? 1 reply

2009.03.11 15:41:15Tester memory handler: tester stopped because not enough memory 19 replies

iADX not working in Strategy Tester 5 replies

  • Platform Tech
  • /
  • Reply to Thread
  • Subscribe
  • 7
Attachments: BTCUSD spread in mt4 strategy tester not working
Exit Attachments
Tags: BTCUSD spread in mt4 strategy tester not working
Cancel

BTCUSD spread in mt4 strategy tester not working

  • Post #1
  • Quote
  • First Post: Apr 18, 2023 3:53pm Apr 18, 2023 3:53pm
  •  llJustll
  • | Joined Sep 2018 | Status: Member | 14 Posts
Hello,

So I am trying to test a strategy for BTC in my mt4. I have downloaded all the tick date to get a 99%modeling quality. And the EA is working as intended.

The only problem is that the spread is not being taken into account. I will explain with images.

Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: < 1 KB

The spread for BTCUSD is 17$ or 1700 points in my broker.

Even If I put 1700 points in the spread option in the strategy tester, or I choose current ( which should be 1700 )- The EA trades as if there is no or minimal spread as you can see from the image of the trades.
Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: < 1 KB
Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: 1 KB

Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: 19 KB


The result is showing the trading happens with like no spread.

So any solutions or suggestions to to fix this problem? - It only happens on BTC- all other forex currencies are good

Thanks .
  • Post #2
  • Quote
  • Apr 18, 2023 10:02pm Apr 18, 2023 10:02pm
  •  pah
  • | Joined Apr 2011 | Status: Basket Case | 249 Posts
Hi,

Have you had a look in the tester journal at the start of a test run. This should show the spread it's working with. If you find this is zero even when you have specified a larger spread it would suggest there is some internal limit to the spread value in the tester. This would require a fix to MT4.

Also, have you checked the spec for the instrument in the symbol properties? It could be that it's not been set up correctly by your broker (probably OK on live but maybe not on demo servers I've found).

Attached script will print out chosen symbol props to the experts tab.

Regards Paul.
Attached File(s)
File Type: mq4 specs.mq4   < 1 KB | 35 downloads
 
 
  • Post #3
  • Quote
  • Apr 18, 2023 10:27pm Apr 18, 2023 10:27pm
  •  llJustll
  • | Joined Sep 2018 | Status: Member | 14 Posts
Quoting pah
Disliked
Hi, Have you had a look in the tester journal at the start of a test run. This should show the spread it's working with. If you find this is zero even when you have specified a larger spread it would suggest there is some internal limit to the spread value in the tester. This would require a fix to MT4. Also, have you checked the spec for the instrument in the symbol properties? It could be that it's not been set up correctly by your broker (probably OK on live but maybe not on demo servers I've found). Attached script will print out chosen symbol...
Ignored
Thanks for the answer Pah.

But I can't seem to find the spread info on the journal. (mode 18 is the spread- but nothing gets printed- Am I missing something?)

Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: 6 KB


Symbol properties looks fine as well.
 
 
  • Post #4
  • Quote
  • Apr 18, 2023 10:40pm Apr 18, 2023 10:40pm
  •  pah
  • | Joined Apr 2011 | Status: Basket Case | 249 Posts
Sorry if I wasn't clear. The attachment is a script which you store in the scripts folder and drop onto any chart. It will print out selected values for all symbols in your market watch window to the experts tab of the terminal.

In testing, with your EA loaded up, at the start of the run you should see something like this:



Attached Image (click to enlarge)
Click to Enlarge

Name: screenshot.png
Size: 7 KB


Regards, Paul.
 
 
  • Post #5
  • Quote
  • Last Post: Apr 18, 2023 11:13pm Apr 18, 2023 11:13pm
  •  pah
  • | Joined Apr 2011 | Status: Basket Case | 249 Posts
Just for info. I ran an EA on Bitcoin which seems to work with the correct values displayed.

I notice on your tester screenshot that trades are opened and immediately closed at s/l or t/p. This suggests that your maybe specifying the take profit or stop loss incorrectly for bitcoin.

Sorry but don't have much experience with bitcoin generally, you'll have to look at that side of it for yourself. e.g I don't get much sense out of the EA I tried until my TP or SL are specified with large numbers like 50000.00 for TP. Possibly your EA is not handling pip/point values correctly...

Good luck.
 
 
  • Platform Tech
  • /
  • BTCUSD spread in mt4 strategy tester not working
  • Reply to Thread
0 traders viewing now
Top of Page
  • Facebook
  • Twitter
About CC
  • Mission
  • Products
  • User Guide
  • Blog
  • Contact
CC Products
  • Forums
  • Calendar
  • News
  • Coins
  • Market
CC Website
  • Homepage
  • Search
  • Members
  • Report a Bug
Follow CC
  • Facebook
  • Twitter

CC Sister Sites:

  • Metals Mine
  • Energy EXCH
  • Forex Factory

Crypto Craft® is a brand of Fair Economy, Inc.

Terms of Service / ©2023