OPEN-SOURCE SCRIPT
SMA 20/50/200 Strategy with TP/SL

Here is a TradingView Pine Script indicator for the 20/50/200 SMA strategy. It generates Buy/Sell Signals and calculates Take Profit and Stop Loss prices for each signal.
Features:
Triggers only on the cross over/cross under bar (not continuous).
Buy: 20 SMA crosses above 50 SMA and is above 200 SMA.
Sell: 20 SMA crosses below 50 SMA and is below 200 SMA.
Plots take profit and stop loss.
Alerts repeat every cross over/cross under occurrence.
Features:
Triggers only on the cross over/cross under bar (not continuous).
Buy: 20 SMA crosses above 50 SMA and is above 200 SMA.
Sell: 20 SMA crosses below 50 SMA and is below 200 SMA.
Plots take profit and stop loss.
Alerts repeat every cross over/cross under occurrence.
オープンソーススクリプト
TradingViewの精神に則り、この作者はスクリプトのソースコードを公開しているので、その内容を理解し検証することができます。作者に感謝です!無料でお使いいただけますが、このコードを投稿に再利用する際にはハウスルールに従うものとします。
免責事項
これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。
オープンソーススクリプト
TradingViewの精神に則り、この作者はスクリプトのソースコードを公開しているので、その内容を理解し検証することができます。作者に感謝です!無料でお使いいただけますが、このコードを投稿に再利用する際にはハウスルールに従うものとします。
免責事項
これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。