Download MetaTrader 5

Watch how to download trading robots for free

Interesting script?
So post a link to it -
let others appraise it

You liked the script? Try it in the MetaTrader 5 terminal

2010.12.15 10:32
Scripts

YURAZ_CreateCSV_HistoryFile_From_MT5_For_MT4 - script for MetaTrader 5

| English Русский 中文 Español Deutsch 日本語 Português

Published by:
Yuriy Zaytsev
Views:
6490
Rating:
votes: 27

When I used the history quotes data from MetaTrader4 client terminal, I have found that some brokers doesn't have the full history.

The quality of the historical bar data is better, so I have decided to export the historical quotes from MetaTrader 5 and import them in MetaTrader 4.

This script will help you to get the full history for MetaTrader 4.

Script for export historical data from MetaTrader 5 to MetaTrader 4

The script creates .CSV file with historical bar data.

The steps:

  • 1 - Install MetaTrader 5 client terminal http://files.metaquo...t5/mt5setup.exe
  • 2 - Enter the Main Menu->Tools->Options->Max bars in chart, and set MaxBars in chart depending on the historical bars needed:

Script for export historical data from MetaTrader 5 to MetaTrader 4


  • 3 - Load this script and place it to MQL5\Scripts folder
    in WINDOWS7/VISTA copy it to the Roaming folder instead of Program Files folder:
    for example c:\Users\<administrator\AppData\Roaming\MetaQuotes\Terminal\D0E8209F77C8CF37AD8BF550E51FF075\MQL5\Scripts\

    </administrator
  • 4 - Compile the script and attach it to the charts for each MetaTrader 4 timeframes: M1 M5 M15 M30 H1 H4 D1 W1

Script for export historical data from MetaTrader 5 to MetaTrader 4


Script for export historical data from MetaTrader 5 to MetaTrader 4


  • 5 - Close MetaTrader 5;
  • 6 - Open MetaTrader 4;
  • 7 - Press F2;
  • 8 - Choose currency pair;
  • 9 - Select timeframe;

Script for export historical data from MetaTrader 5 to MetaTrader 4

Let's consider how to dow it for M15 timeframe.
  • 10 - Select the file, created for M15 timeframe;
  • 11 - Press the "Import" button:

Script for export historical data from MetaTrader 5 to MetaTrader 4

  • 12 - Repeat the step №10 for each pair. Repeat Step №11 for each timeframe of the pair:

Script for export historical data from MetaTrader 5 to MetaTrader 4

LET'S CHECK IT!

Before:

Script for export historical data from MetaTrader 5 to MetaTrader 4

After:

Script for export historical data from MetaTrader 5 to MetaTrader 4


YURAZ

yzh@mail.ru

Translated from Russian by MetaQuotes Software Corp.
Original code: https://www.mql5.com/ru/code/232

Accelerator Oscillator (AC) Accelerator Oscillator (AC)

The Acceleration/Deceleration Indicator (AC) measures acceleration and deceleration of the current driving force.

Average Directional Movement Index (ADX) Average Directional Movement Index (ADX)

The Average Directional Movement Index Indicator (ADX) helps to determine if there is a price trend.

Holt's double exponential smoothing trend Holt's double exponential smoothing trend

Holt's double exponential smoothing - the trend component (mt4 version).

Holt's double exponential smoothing (mt4 version) Holt's double exponential smoothing (mt4 version)

Holt's double exponential smoothing with linear forecasting.