-
Notifications
You must be signed in to change notification settings - Fork 2k
Srsi wrong values #694
Comments
Someone else noticed this issue? |
This issue come from the lib/srsi.js file. In this file, there is theses lines:
So it seems to be right. But sometime, s.period.rsi is lower than lowestRSI ... And it gives negatives values! And sometime s.period.rsi is higher than highestRSI... And it gives values higher than 100. So now the question is: |
Thank you for your analysis! However, I think that this is not the real issue because the lowest RSI is computed among a set of values, including the actual RSI value. It means that, in a worst case scenario s.period.rsi - lowestRSI is equal to zero. My suspects however are focused on this part of the code:
I would appreciate your feedback on his purpose inside the code, in particular RSI.push(period.rsi) |
That is the problem, in this code, current RSI is not push. I added
just after the lines you wrote, and now I have reals values. However, these value are not the same that tradingview.com SRSI indicator... If you want some explaination about the code you wrote:
this line will separate all periods between the current period-1 and the current period-k-1, and each period will be accessible via "period". It's like a "for" in some ways. and then,
is used to push each rsi of each period inside RSI array. |
This should now be fixed by #1196 |
Srsi indicator gives, to me, wrong results, with oscillations greater than the maximum srsi range (typically 0-100% or 0-1). If this issue is confirmed the validity of both macd-srsi and cci-srsi strategies is compromised. I think that is needed a fix on the srsi.js file inside lib folder. Unfortunately I'm not an expert in javascript language and I can give support only on the technical analysis part.
Further information on srsi: https://www.tradingview.com/wiki/Stochastic_RSI_(STOCH_RSI)
The cyan column gives the value of srsi
Thank you for the support
The text was updated successfully, but these errors were encountered: