OPEN-SOURCE SCRIPT
30-Week SMA (Fixed)

This indicator plots a true 30-week Simple Moving Average (SMA) on any chart, regardless of the selected timeframe.
It uses weekly candle data (via the request.security() function) to calculate the 30-week average and keeps it fixed — meaning the line remains accurate even when you switch to daily, 4-hour, or other timeframes.
The 30-week SMA is a cornerstone of Stan Weinstein’s Stage Analysis strategy, commonly used to identify major trend phases:
Above a rising SMA → bullish (Stage 2 uptrend)
Below a falling SMA → bearish (Stage 4 downtrend)
Use this indicator to maintain a consistent long-term trend filter on all timeframes
It uses weekly candle data (via the request.security() function) to calculate the 30-week average and keeps it fixed — meaning the line remains accurate even when you switch to daily, 4-hour, or other timeframes.
The 30-week SMA is a cornerstone of Stan Weinstein’s Stage Analysis strategy, commonly used to identify major trend phases:
Above a rising SMA → bullish (Stage 2 uptrend)
Below a falling SMA → bearish (Stage 4 downtrend)
Use this indicator to maintain a consistent long-term trend filter on all timeframes
オープンソーススクリプト
TradingViewの精神に則り、この作者はスクリプトのソースコードを公開しているので、その内容を理解し検証することができます。作者に感謝です!無料でお使いいただけますが、このコードを投稿に再利用する際にはハウスルールに従うものとします。
免責事項
これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。
オープンソーススクリプト
TradingViewの精神に則り、この作者はスクリプトのソースコードを公開しているので、その内容を理解し検証することができます。作者に感謝です!無料でお使いいただけますが、このコードを投稿に再利用する際にはハウスルールに従うものとします。
免責事項
これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。