⭐ dynastic Posted April 23, 2012 Report Posted April 23, 2012 (edited) Hello, I am trying to create a basic mq4 indicator that will plot data from CSV file onto graph. My code can plot up to current date, but I do not know how to plot future date in metatrader MQ4. I have future data in CSV file, example CSV is below for GBPUSD, 38 year and 15 year historic data. Could anybody help me with MQ4 code to plot CSV future data into metatrader ? Current MQ4 Code is here: http://pastebin.com/WceEENzH Here is screenshot example: http://i40.tinypic.com/153p635.png Example CSV data ("Composite.GBPUSD") 10/04/2012,42.85,30 11/04/2012,53.44,35.95 12/04/2012,52.09,35.78 13/04/2012,52.71,34.77 14/04/2012,59.85,37.41 15/04/2012,58.39,38.51 16/04/2012,67.53,43.39 17/04/2012,74.93,44.58 18/04/2012,76.81,45.11 19/04/2012,74.75,48.26 20/04/2012,74.08,45.69 21/04/2012,69.15,45.48 22/04/2012,68.19,47.14 23/04/2012,71.84,44.85 24/04/2012,70.41,44.71 25/04/2012,76.37,49.37 26/04/2012,78.39,47.7 27/04/2012,83.45,51.33 28/04/2012,78.81,45.89 29/04/2012,83.94,51.45 30/04/2012,87.72,53.05 1/05/2012,81.61,52.82 2/05/2012,79.76,50.55 3/05/2012,76.36,45.93 4/05/2012,86,56.63 5/05/2012,80.84,55.05 6/05/2012,82.93,52.87 7/05/2012,74.97,37.94 8/05/2012,69.14,31.76 9/05/2012,58.06,31.94 10/05/2012,50.4,24.13 Edited April 24, 2012 by digian
udc Posted April 24, 2012 Report Posted April 24, 2012 (edited) Well, you can draw future price/indicator values either "manually" using objects or you can simply shift it (SetIndexShift). Btw, delete lines 43 and 44 in your code, you are - most probably unintentionally - rewriting what you already set at lines 31 and 37. Edited April 24, 2012 by udc
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now