# indicator crossing - page 2

2955

Sorry to say this but you will have to learn some maths first.

1. You will have to first define the exact range for each indicator in order to normalise their values.
2. You will then have to apply "maths" to normalise the values:
1. For example, if the range of "x" is "a" to "b", then the normalised value (0 to 1) is " y = ( x - a ) / ( b - a )"
2. For example, to normalise the CCI range of -440 to 386 into 0 to 1, you would use the formula "nCCI = ( CCI + 440.0 ) / 826.0".
Please note that your reported CCI range is strange and asymmetrical. You should use a symmetrical or balanced range.
3. For example, to normalise the StochRSI range of -5 to 105 into 0 to 1, you would use the formula "nStochRSI = ( StochRSI + 5 ) / 110.0".
Please note, that the range for StochRSI is 0 to 100 (or 0 to 1 depending on implementation) and not -5 to 105.
3. For a cross, you can't just simple look for "==" as that will most probably NEVER happen. You have to look at the previous values of the indicators and see if the previous is "before" and the current is "after"
1. For example if the previous value is below the other indicator, and the current value is equal or above the other indicator.

On a different note and as a personal opinion, I think you are wasting your time trying to find crosses of the CCI and a StochRSI. There is just no relation between those two indicators to justify such an approach!

56

FMIC:

Sorry to say this but you will have to learn some maths first.

1. You will have to first define the exact range for each indicator in order to normalise their values.
2. You will then have to apply "maths" to normalise the values:
1. For example, if the range of "x" is "a" to "b", then the normalised value (0 to 1) is " y = ( x - a ) / ( b - a )"
2. For example, to normalise the CCI range of -440 to 386 into 0 to 1, you would use the formula "nCCI = ( CCI + 440.0 ) / 826.0".
Please note that your reported CCI range is strange and asymmetrical. You should use a symmetrical or balanced range.
3. For example, to normalise the StochRSI range of -5 to 105 into 0 to 1, youwould use the formula "nStochRSI = ( StochRSI + 5 ) / 110.0".
Please note, that the range for StochRSI is 0 to 100 (or 0 to 1 depending on implementation) and not -5 to 105.
3. For a cross, you can't just simple look for "==" as that will most probably NEVER happen. You have to look at the previous values of the indicators and see if the previous is "before" and the current is "after"
1. For example if the previous value is below the other indicator, and the current value is equal or above the other indicator.

On a different note and as a personal opinion, I think you are wasting your time trying to find crosses of the CCI and a StochRSI. There is just no relation between those two indicators to justify such an approach!

According to my understanding of your reply i have got that first i have to define exact range in FIX MAXIMUM and FIX MINIMUM .

After it i have to normalize the values i get from Indicator using  formulae "y = (x-a)/(b-a)".After normalizing i have to check as u told in 3rd point..

2955

ceaser234:

According to my understanding of your reply i have got that first i have to define exact range in FIX MAXIMUM and FIX MINIMUM.

That is only for the visual presentation of the indicators on the chart. It has nothing to do with your code. The changes to you code is independent of the visual use.
56

FMIC:
That is only for the visual presentation of the indicators on the chart. It has nothing to do with your code. The changes to you code is independent of the visual use.
So can u guide me where i have to define the exact range for  each indi to normalize as u write in the first point.
2955

ceaser234:
So can u guide me where i have to define the exact range for  each indi to normalize as u write in the first point.

Are you not the "author" for the strategy? If you did not create it, where did you find it and what are the "rules" for the ranges as defined by the person who created this "method"?

As I a said before, my personal opinion is that they are not compatible or related in any way to justify looking for crosses between CCI and StochRSI.

56

FMIC:

Are you not the "author" for the strategy? If you did not create it, where did you find it and what are the "rules" for the ranges as defined by the person who created this "method"?

As I a said before, my personal opinion is that they are not compatible or related in any way to justify looking for crosses between CCI and StochRSI.

Sorry for the reply above.My problem is almost solved.

And Thanks for the help!