Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 6. - page 209
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
Good evening Dear artmedia70.
I'm coming back to you with the same problem: I still can't figure out how to get the data I need.
You wrote about the concept of searching for a new bar. As I understand it (concept) consists in comparing the time of bars and if the time is different - here's a new bar. Besides, this function displays the data about times of all following bars.
I tried to apply this approach to my task. The first value I get is exactly what I want but then I get data of each next bar.
I don't understand how I can get data from only one (first) bar. Can you tell me please.
Without your code and without understanding what you want to do, it's hard to tell you what to do.
I don't have a code as such yet: I only have enough intelligence to identify the highs and lows on the required interval.
But I will try to explain what I want to do.
Here is actually an example of what I am trying to achieve:
the purple lines are the highs and lows of the range.
The green is the "reference point" (defined by time).
I need to know the time when the opening price of a candle will go out of the range. The arrow on the picture shows a bar whose open time I need to know and assign its value to a variable.
I don't have a code as such yet: I only have enough intelligence to identify the highs and lows on the required interval.
But I will try to explain what I want to do.
Here is actually an example of what I am trying to achieve:
the purple lines are the highs and lows of the range.
The green is the "reference point" (defined by time).
I need to know the time when the opening price of a candle will go out of the range. The arrow on the picture shows a bar whose open time I need to know and assign its value to a variable.
1. For Expert Advisor or indicator?
2. First candle or zero?
1. For an EA or indicator?
2. First candle or zero?
For an EA.
The candlestick is zero.
For the EA.
A candlestick is zero.
If the opening price of the current candle is higher/lower than the upper/lower limit of the range, and the opening price of the first candle is lower/lower than/equal to the upper/lower limit of the range, then store the opening time of this candle in a variable with datetime type
Something like this:
If the opening price of the current candle is higher/lower than the upper/lower limit of the range and the opening price of the first candle is lower/lower than or equal to the upper/lower limit of the range, then store the opening time of this candle in a variable with datetime type
Something like this:
Made an indicator. The indicator value ExtMapBuffer1[i] is obtained from one of three current conditions.
Question, how to get indicator value with shift (the day before yesterday (2) and yesterday (1) )?
Made an indicator. The indicator value ExtMapBuffer1[i] is obtained from one of three current conditions.
Question, how to get indicator value with shift (the day before yesterday (2) and yesterday (1) )?
Well, it's hard to say. Usually iCustom() helps
Well, it's hard to say. Usually iCustom() helps.
Good afternoon.
My strategy takes into account the spread, the spread is defined by a function:
But because the spread is constant in the strategy tester, I need a random spread emulator. I want to emulate the changes of spread in the tester in the range of 2 to 3 points (4 digits) in 80% of cases and more than 3 points in 20% of cases. Any ideas how to implement this, or links where such an idea has been solved.