OPEN-SOURCE SCRIPT

Quatro SMA Strategy [4h]

Theo wielkieef
Hello, I would like to present to you The "Quatro SMA" strategy

Strategy is based on four simple moving averages of different lengths and monitoring trading volume. The key idea is to identify strong market trends by comparing short-term moving averages with the long-term SMA. The strategy generates buy signals when all short-term SMAs are above the SMA(200) and the volume confirms the strength of the move. Similarly, sell signals are generated when all short-term SMAs are below the SMA(200), and the volume is sufficiently high.

The strategy manages risk by applying a stop loss and three different Take Profit levels (TP1, TP2, TP3), with varying percentages of the position closed at each level.

Each Take Profit level is triggered at a specific percentage gain, with the position being closed gradually depending on the achieved targets. The percentage of the position closed at each TP level is also defined by the user.

Indicators and Parameters:

Simple Moving Averages (SMA):
The script utilizes four simple moving averages with different lengths (4, 16, 32, 200). The first three SMAs (SMA1, SMA2, SMA3) are used to determine the trend direction, while the fourth SMA (with a length of 200) serves as a support/resistance line.

Volume:
The script monitors trading volume and checks if the current volume exceeds 2.5 times the average volume of the last 40 candles. High volume is considered as confirmation of trend strength.

Entry Conditions:
- Long Position: Triggered when SMA1 > SMA2 > SMA3, the closing price is above SMA(200), and the volume condition is met.
- Short Position: Triggered when SMA1 < SMA2 < SMA3, the closing price is below SMA(200), and the volume condition is met.

Exit Conditions:
- Long Position: Closed when SMA1 < SMA2 < SMA3 and the closing price is above SMA(200).
- Short Position: Closed when SMA1 > SMA2 > SMA3 and the closing price is below SMA(200).

to determine the level of stop loss and target point I used a piece of code by RafaelZioni, here is the script from which a piece of code was taken
https://pl.tradingview.com/script/xGk5K4DE-BTC-15-min/


I hope the strategy will be helpful, as always, best regards and safe trades
;)
botBTCbtcbotBTCUSDcryptobotETHethbotETHUSDSimple Moving Average (SMA)
wielkieef

Mã nguồn mở

Theo tinh thần TradingView thực sự, tác giả của tập lệnh này đã xuất bản dưới dạng nguồn mở để các nhà giao dịch có thể hiểu và xác minh. Chúc mừng tác giả! Bạn có thể sử dụng miễn phí. Tuy nhiên, bạn cần sử dụng lại mã này theo Quy tắc nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?

Thông báo miễn trừ trách nhiệm