Download software Tutorial videos
Subscription & data-feed pricing Class schedule


New account application Trading resources
Margin rates Stock & option commissions

Attention: Discussion forums are read-only for extended maintenance until further notice.
Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

consecutive bars in a row Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
gregc
Posted : Sunday, April 29, 2018 1:59:20 PM
Gold Customer Gold Customer

Joined: 12/30/2004
Posts: 4

How would it a condition be written that checks

X number of consecutive higher high and higher low bars in a row - each bar closes > open

X consecutive Lower high and Lower low bars in a row - each bar closes < open

And same to say Minumum rather than define the exact # of bars

Bruce_L
Posted : Monday, April 30, 2018 11:59:22 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

If you want to count the number of higher bars in a row, you would use something like the following.

TrueInRow(C > O AND H > H1 AND L > L1, 20)

That just returns a numeric value which will run from 0 through 20. If there are 50 bars in a row, it would still return 20.

So let's say you wanted to check for exactly 3 bars in a row (not 2 bars and not 4 bars).

TrueInRow(C > O AND H > H1 AND L > L1, 4) = 3

If you wanted to check for at least 3 bars in a row.

TrueInRow(C > O AND H > H1 AND L > L1, 3) = 3

Just reverse the > signs into < signs to reverse directions.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Users browsing this topic
Guest-1

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.