prodsaaw 1 posts msg #128930 - Ignore prodsaaw |
6/4/2016 11:00:35 AM
I am looking for a script which counts the number of periods of an up-swing or down-swing.
The count to be from 1 till 9 for the up-swing and -1 till -9 for the down-swing.
The counter starts at 1, when the close is higher than the close of 4 candles earlier (on a day chart the close of the day should be bigger than the close of day -4).
Count 2 should be shown when the close is higher than the close of 4 periods earlier etc etc, till count 9.
After the count till 9, and when the swing is still up, the count starts again at 1 etc.
For the down-swing the close should be lower than the close of 4 periods ago.
Ideally the count (1-9) is shown in the window where the candles are shown.
If this is not possible, than the swing counter could be shown as an indicator, whereby the up-swing is shown as positive bars and the down swing as negative bars.
For your information experience shows that at when the swing reaches period 9, there is a probability of 80% that the up-swing (down-swing) will come to a top.
thanks.
|