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
I believe you and Vladimir are having miscommunication problems. I am going to attempt to explain both sides.
As he said, you can't mix styles for a single plot, but you can have different styles for separate plots.
So, yes, just as you do on MT4 you can have 2 separate plots, each one being a histogram but with different display properties. Just make sure that they don't both plot values at the same bar index. When one of the plots has value, the other should be EMPTY_VALUE and vice versa. Also, the the plots will share the same scale, so make sure that the values for each plot are comparable.
Also, please remember that in MT4 each buffer corresponded to a single plot, but in MT5 some plot types can be comprised of multiple buffers, usually (but not always) in the form of one buffer for the data and the other for the colour. So make sure that your display properties are indexed based on the plot index and not the buffer index.
Was this able to help with the miscommunication?
A few more things:
I've attached the empty histogram too
A few more things:
I've attached the empty histogram too
I suggest you supply the full code instead of just snippets. It is rather difficult for us to pinpoint what you may be doing wrong from just pieces of the code. It's easier when we can see the "full picture" as well as actually run it and see the results.
Yes, "Histogram" would be equivalent to the MT4 implementation. "Histogram2" is not for two plots or different styles, but for a single plot where the histograms are NOT zero based.
Supply full code and I will make adjustments so you can see how to do it.
Your code is only for one Histogram plot? Where is your attempt at two histogram plots? Do it as if it were MT4 using standard "Histogram".
You also did not correct the points I explained, such as not mixing the "Data" and the "Calculation" buffers. You were warned that ADX and Awesome Oscillator do not share the same scale so they will not plot correctly together.
Please understand, that I am willing to guide and help you, but not to totally recode it for you. So, please, fix the mentioned points first then resupply your new code.
You also did not correct the points I explained, such as not mixing the "Data" and the "Calculation" buffers. You were warned that ADX and Awesome Oscillator do not share the same scale so they will not plot correctly together.
I think its best If we tackled the issues in isolation as I seem to have failed to grasp something fundamental. Furthermore I had not read your reply #16 at the time of answering. So for the highlighted text I have still not grasped what you mean by mixing the calculation and data buffers, do you mean assign the calculation buffer index value to a scalar before I assign to the Data Buffer index? For the scale, I had tried to address this by assigning the second buffer(Awesome Buffer) to static value "20"(in oncalculate for loop) which should place it somewhere within the scale of the ADX for test purposes, was that sufficient?
I have changed to Histogram as per #16 and the histogram now plots but I cannot see the bars for values of the second buffer(20) for which I have also added a PlotSetInteger for the width property in onInit()
Edit added pic for histogramHere is an example: