OPEN-SOURCE SCRIPT
Autocorrelation with RSI

This indicator uses autocorrelation and RSI to find good entry points for trades. In theory, autocorrelations (correlation of a variable with lagged values) should be a great timing indicator. It goes positive when a trend is confirmed and negative when the trend breaks down so you can use it to follow the trend of play the mean-reversion. But it is not as straightforward as that. If you use autocorrelation to confirm a trend, it would only be helpful if the trend starts slowly (small moves) and then develops into big moves or persistent moves in one direction. If the trend starts with big moves, the autocorrelation will turn positive when most of the move has happened. If you use it for mean-reversion, you need to watch out for noise. You first need to look for evidence that the trend is done using other tools like RSI, momentum indicators, sentiment, fundamental/macro changes, etc, then you can look for entry points using the autocorrelation. Another problem is that you have to decide on a lookback period. RSI uses 14 by default but since few ever change it, then everyone is basically using the same RSI indicators. Since autocorrelation is not a popular indicator, the choice of lookback period matters. You can try to optimize it (fitting past data) but you would likely be overfitting and past performance would be no indicator of future performance.
Note: Autocorrelation is a measure of correlation and therefore has values between -1 and 1, but in this script I change it so that the values are between 0 and 1 to make it fit on the same scale as RSI (for ease of use).
Note: Autocorrelation is a measure of correlation and therefore has values between -1 and 1, but in this script I change it so that the values are between 0 and 1 to make it fit on the same scale as RSI (for ease of use).
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
この情報および投稿は、TradingViewが提供または推奨する金融、投資、トレード、その他のアドバイスや推奨を意図するものではなく、それらを構成するものでもありません。詳細は利用規約をご覧ください。
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
この情報および投稿は、TradingViewが提供または推奨する金融、投資、トレード、その他のアドバイスや推奨を意図するものではなく、それらを構成するものでもありません。詳細は利用規約をご覧ください。