Is it possible to programmatically find ALL horizontal channels/floats at a certain time interval or at least formulate the ToR correctly? - page 6
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
1. But the "bar" is "stretched" in time, right? Indeed, its price is "indicative", while we need a specific, four-digit... :)
2. well, you don't need a TF and a "time step", much less 15min....
3. yes, i agree, but i just don't like "and then", i think not "and then", but immediately, simultaneously.
Although you need a code and not a 'codpiece', nevertheless.
1. In order to quickly run through the history and not get distracted by uninteresting intervals, just compare High[iHighest] - Low[iLowest] with the channel width you are interested in, taking into account the "channel wall thickness" (If the price leaves the boundaries of the channel at the distance equal to its width)
2. Due to the fact that you are interested in the number of reversals(two reversals in it), then in the selected intervals it will be necessary to go by bars, and by minutes, and calculate the number of hits inside the walls. Unless, of course, you agree to simplify the task in terms of quantity and "quality" of hits and the requirement to "alternate" hits inside this or that wall...
3. Moreover, having chosen according to the simplest algorithm (from the first point) the channel of interest, the number of touches-knees will be different depending on the choice of the middle of the channel.
There will be a lot of variations:
- (High[iHighest] - Low[iLowest]) / 2
- The point (Close[i]) relative to which the channel was selected (in the future or in the past)
- One of the extrema touching the outer wall of the channel (whatever your imagination is).
And all this you should define, first of all, for yourself.
And perhaps the most important thing.
Having mentioned in your first post "...the existence of flotsam...", you condemned the thread to flooding.
North should help each other. Keep a real channel indicator (from 1min to a week, I think you can add a month by yourself). Ordered it once, but never got around to it. It may come in handy.
Thanks for sure:)
Honestly, I don't understand it much...
What kind of flood? :) no reason, as everything is clearly formalizable... probably
Although I got the general idea of the post from the pictures... Well, nothing bad, and most importantly, nothing significant will happen due to the fact that the sampling will be performed at long (within reasonable limits) time intervals and a large, but I think huge amount of flots with sufficient reliability may show the "nature" of price behavior in the flat, for example in 50 points and taking into account its "neighbours" - a flat in 49-51 points.
Well, the price was one point short of the next turn in the flat 50 points, so it still "turned somewhere in some flat", for example in the flat 49 points.
Would it make sense to come at it from the other side? Don't look for a channel based on two bounces, but look for bounces based on a known channel width.
For example, we have channels with the width of 20 points, 21 points, 22, 23, ... 49, 50 points. Then we will check if these channels are available on the segment of the required time interval.
By the way. As I understand it, a channel has two boundaries, an upper and a lower one. Two rebounds will give one boundary. Should we search for the second one by two bounces as well? Or, by one rebound + width?
Would it make sense to come at it from the other side? Don't look for a channel based on two bounces, but look for bounces based on a known channel width.
For example, we have channels with the width of 20 points, 21 points, 22, 23, ... 49, 50 points. Then we will check if these channels are available on the segment of the required time interval.
By the way. As I understand it, a channel has two boundaries, an upper and a lower one. Two rebounds will give one boundary. Should we search for the second one by two bounces as well? Or, by one rebound + width?
we are not looking for a channel, we are creating one ourselves, we are looking for a flat.
there are already two bounds, so two bounces in the channel = start of a flat
We are not looking for a channel, we create it ourselves; we are looking for a flat.
the boundaries are already two, so two flips in the channel = start of a flat.
In answer to the topic question, is it possible to find ALL horizontal channels programmatically - the answer is YES.
So, you need to set the condition in the program: if price is within the specified range within N bars, then it's a flat, or a horizontal ...
The program gives a graphic representation of such channels...
We are not looking for a channel, we are creating one ourselves, we are looking for a flat.
the boundaries are already two, so two flips in a channel = start of a flat
I came at it from the other side, tried to determine all channels of a given length (from m to n), I think it worked. And after finding the flat, I think its scope will be easier to measure.
Here is the figure. Parameters - channels from 8 to 16 bars.
The yellow dotted line indicates that
a) price was fluctuating within a certain range during a specified period and small random spikes do not influence the readings (this, by the way, was the main task I was trying to solve) and
b) The price was not just hanging out, but largely along a straight line.
the principle of operation is quite complex (and simple at the same time:).
The ratio of the error of the regression straight line to the error of the cubic polynomial is compared, this is a measure of the "straightness" of the movement. Then a correction factor inversely proportional to the slope, since the first step identifies all (not just horizontal) channels.
1. I came at it from the other side and tried to identify all channels of a given length (m to n), it seems to work. I think it's easier to measure the range when I find a flat.
2. Here is the figure. Parameters - channels from 8 to 16 bars.
Appearance of the yellow dotted line means that
a) price during a specified period was dabbling in a certain range, and small random spikes do not influence the readings (this, by the way, was the main task I tried to solve) and
b) price was not just hanging out, but to a large extent along a straight line.
the principle of operation is quite complex (and simple at the same time:).
The ratio of the error of the regression straight line to the error of the cubic polynomial is compared, this is a measure of the "straightness" of the movement. Then a correction factor inversely proportional to the slope, since the first step identifies all (not just horizontal) channels.
1. Yes, I believe that "entries from the other sides" can be successful.
2. Interesting indicator and the yellow dotted line in particular...
Here's a script I can't remember where or when I found it.
Maybe someone could use it!?