I thought I knew about how to apply swap points as it's presented here : http://www.eforex-asia.com/swap_rates.html Now with this new MODE_SWAPTYPE, i'm not so sure... thought it was only one kind
of representation for data retrieved with MODE_SWAPLONG and MODE_SWAPSHORT. I'd
appreciate to see some formulas and examples for each of them so I could use them
properly...
- Testing Visualization - Algorithmic Trading, Trading Robots
- Working with Projects - Projects and MQL5 Storage
- Quotes - MetaTrader 5 for Android
See https://docs.mql4.com/constants/marketinfo
MODE_SWAPTYPE | 26 | Swap calculation method. 0 - in points; 1 - in the symbol base currency; 2 - by interest. |
Now, perhaps I didn't made myself understood... I read the documentation. I just
didn't understood. The problem is distinction between 0 and 1 (in our EAs). I guess
both methods return swap points. Normally, if base currency is USD, there should
be no difference between results. I guess that in the case base currency would
be EUR, the results would be already divided to EURUSD rate (for the 1 case)...
Probably when the value is 2 the interest is gained in the currency bought in a
trade and converted at paytime in account currency. But these are just my guesses.
.. And there shouldn't be place to guess when you're programming an EA and must
know exactly what a function returns...
Calculation method is applied on the server (or tester) side. Calculated swaps are presented in deposit currency
Ok Stringo, so the server should do the magic and me getting results in "deposit
currency". For example InterbankFX MarketInfo("EURUSDm",MODE_SWAPTYPE)
returns 2 so these should be interest rates. We have, when applying MarketInfo
with MODE_SWAPLONG and MODE_SWAPSHORT. EURUSD -0.8650 0.72 USDJPY 1.30 -1.46 USDCHF
0.99 -1.15 EURCHF 0.55 -0.63 and the list goes on... What they have on website
at http://www.interbankfx.com/swap_rates.php is very very different... I just wanted a formula to convert results from what
I get out of MarketInfo into what they displayed (or around there, cause swap points
are marginally affected by forex rates fluctuations)
Use OrderSwap() function to get really calculated swaps.
Ask question about swap calculations your broker.
Just as side topic, on FXDD , MarketInfo("EURUSD",MODE_SWAPTYPE) returns 3...and that's not one of the standard
values
It is non-standard value. They calculate swaps by their own way
Well, as providers of the platform you should have forbid them to do anything that
could damage the MetaTrader's reputation...

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register