thank u so much for the ea...wonderfull
Ralph,
Cannot load this:
Where do we get this file?
How to call multiple instances ?
Hi Ralph
I was wondering how to call multiple instance of the pipschart indicator from the expert advisor with different pipssteps like 3 and 8 ?
Maybe it's easy but I can't figure it out ?
Thanks in advance
It's relatively easy, although you might need to revise the include file slightly. The library operates directly on the array provided, with the pips level provided, but it does store and use the box+center+stretch setting. So as long as you use a single such setting, the library functions can be applied to different chart arrays, with different pips sizes.
However, you need to revise the PipsChartInit() function defined in the include file. Basically, for two charts, it'd look like:
double chartB[][6]; // The other one
void PipsChartInit()
{
ArrayResize( chartA, max_A_bars );
PipsChartReset( chart, pipsA, count, box, center, stretch );
ArrayResize( chartB, max_B_bars );
PipsChartReset( chart, pipsB, count, box, center, stretch );
...
}[/PHP]
Thereafter the update calls are also replicated, and you might make a convenience function for that as:
[PHP]void UpdateCharts(datetime t,double p)
{
PipsChartUpdate( chartA, pipsA, t, p );
PipsChartUpdate( chartB, pipsB, t, p );
}Those are the only things needed in order to build the chart data, which is what Ferret is using (it makes its own display of the data, which you probably want to avoid if using two charts). The rest is merely to use chartA or chartB as appropriate in the decision logic.
The pips size provided to PipsChartUpdate is the size used for "digesting" the given price point to the given chart, and you could conceivably apply different pips sizes at different times. The pips size given to PipsChartReset is used for the initial processing of the "count" most recent time chart bars, which is just a stream of calls to PipsChartUpdate.
Tick Tools
- Tick tools - key thread with many tick indicators.
- Tick indicators and EAs thread
- PipsChart indicators thread
- Ferret the PipsChart Trader EA: the thread
Forum on trading, automated trading systems and testing trading strategies
How to Start with Metatrader 5
Sergey Golubev, 2017.02.15 06:04
TESTING TRADING STRATEGIES ON REAL TICKS
The article provides the results of testing a simple trading strategy in three modes: "1 minute OHLC" using only Open, High, Low and Close prices of minute bars; detailed modeling in "Every tick" mode, as well as the most accurate "Every tick based on real ticks" mode applying actual historical data.
Forum on trading, automated trading systems and testing trading strategies
Sergey Golubev, 2017.02.17 20:53
If you are backtesting EA on MT5 using 'every tick based on real ticks' so it will be almost same with trading on MT5 platform with some particular broker (because it is based on actual historical data).
Example, read this thread: Why is it better MT5 than MT4?? Does it have fewer limitations ??? - this is the quote from the first post of the thread:
- In MT5 you can backtesting robots with the closest possible conditions to the real market natively (real tick data, real variable spreads, lag, slippage, etc). In MT4 you can't natively. You only can if you pay for a third-party software. If so, you also have to download history data from a few sources (there are many few, almost everyone uses the same source), transform it to MT4 format and open the platform through this third-party software in order to patch MT4 behavior. You take many hours to complete this process, and you have to repeat it every time you want to incorporate new data.
We have all seen hundreds of robots that obtained spectacular results in backtesting, but when operating in real account the results were very bad. This is mainly because they were made with conditions that had nothing to do with real market conditions.
For more information about it - read this summary.
--------------
As i know - some coders/traders are converting their MT4 EAs to MT5 just to backtest them and/or to find the settings with optimization to get the backtesting results that are closest to reality.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
This is a repost, as I did first post it in the indicators section. The EA uses the PipsChartData library, which code-wise belongs to the indicator.