OPEN-SOURCE SCRIPT

5 SMA and 200 SMA Strategy with 1:3 Target and SL

181
Stop Loss (SL) and Target (1:3 Risk/Reward):

Long Position:
The stop loss is set at 1% below the entry price (longSL = strategy.position_avg_price * 0.99).
The take profit target is set at 3% above the entry price (longTarget = strategy.position_avg_price * (1 + 0.03)).
Short Position:
The stop loss is set at 1% above the entry price (shortSL = strategy.position_avg_price * 1.01).
The take profit target is set at 3% below the entry price (shortTarget = strategy.position_avg_price * (1 - 0.03)).
1:3 Risk-to-Reward:

The ratio between the stop loss and target is set to 1:3, meaning for each trade, the take profit is 3 times the distance of the stop loss.
How it works:
When a long or short trade is triggered, the script will place a stop loss 1% away from the entry price.
The take profit target will be placed 3% away from the entry price (in the favorable direction).
Feel free to adjust the stop loss and target percentages as needed.

免責聲明

這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。