I don't know if it's because I have to convert the currency, or if the website isn't up-to-date, if the formula I'm using is wrong, or who knows.
From my understanding, MODE_SWAPLONG/MODE_SWAPSHORT is basically just the swap rate in the form of pips, so the formula I'm using should work, in theory.
Update: I downloaded a free Swap indicator from the market and everything seems to be lining up, other than the free indicator rounds down and my results round up.
Hi guys,
I'm working on an indicator that presents a market overview, showing stuff like symbol, quote, tickvalue, atr, and swap.
My broker is using a 0 swaptype.
I've done some research and the best thing I could find is this formula:
I don't know how to view the swap rate directly from my broker, so I'm relying on this website: http://www.forexchurch.com/forex-broker-details.cfm?brokername=OANDA
My results seem to align with the results from the website about 60% of the time, but there are times when it's not right.
For example, here are some of my results that don't match up with the website:
I don't know if it's because I have to convert the currency, or if the website isn't up-to-date, if the formula I'm using is wrong, or who knows.
From my understanding, MODE_SWAPLONG/MODE_SWAPSHORT is basically just the swap rate in the form of pips, so the formula I'm using should work, in theory.