Help Center
Bots
CTA-Expert Bots

Double Moving Average—RSI Quantitative Help Documentation

4 days
224290 Read
14

1. What Is the Dual Moving Average?

A moving average is one of the most widely used technical indicators, typically applied to time series data. Its main purpose is to smooth out short-term fluctuations and highlight long-term trends and cycles. Over the years, several types of moving averages have been developed, including: Simple Moving Average (SMA), Exponential Moving Average (EMA), Weighted Moving Average (WMA), and Cumulative Moving Average (CMA). The dual moving average strategy primarily uses the simple moving average.

The dual moving average strategy mainly utilizes the simple moving average. By calculating the moving average for each trading day based on the closing prices of the previous N days, and connecting these calculated points, you get the N-day moving average line. The dual moving average refers to two different moving average lines calculated over different periods, such as the 5-day and 60-day moving averages.

cta\-expert\-bots

2. What Is RSI?

The Relative Strength Index (RSI) analyzes market buying and selling momentum and strength by comparing the average number of closing gains and losses over a certain period. This helps forecast future market trends and reflects the market’s condition within a given timeframe.

3. Dual Moving Average–RSI Strategy Overview

The Dual Moving Average–RSI strategy uses two moving averages of different lengths and the RSI indicator to determine optimal entry and exit points. The entry and exit rules are as follows:

Go long when the short-term moving average crosses above the long-term moving average and the RSI value is greater than or equal to the threshold + 50; close the long position when the short-term moving average crosses below the long-term moving average or the RSI value is less than or equal to 50 – threshold. In the chart below, the RSI threshold is set to 15. Entry and exit points are indicated by the arrows:

Go short when the short-term moving average crosses below the long-term moving average and the RSI value is less than or equal to 50 – threshold; close the short position when the short-term moving average crosses above the long-term moving average or the RSI value is greater than or equal to threshold + 50. In the chart below, the RSI threshold is set to 15. Entry and exit points are indicated by the arrows:

4. Dual Moving Average–RSI Trading Entry (Using Perpetual Contracts as an Example)

(Using the Dual Moving Average–RSI for perpetual contracts as an example) Navigation bar — Trading Bot — CTA — Expert Bot — Dual Moving Average–RSI — Perpetual Contract — Create Bot — Configure Parameters — Click Create 1

Backtesting: Before creating a [Perpetual Contract Dual Moving Average–RSI] strategy, you can run a backtest first.

Backtesting Process: Click the [Backtest] button in the image above, enter your desired parameters on the page that appears below, then click [Backtest Again]. The system will automatically backtrack the data (by default, within one month) and generate a reference backtest record in the [Backtest Records] section. 1

5. Parameter Configuration Guide

Leverage Multiplier: The leverage multiple applied to your investment, mainly used to calculate order size.

Total Investment Amount: The total amount you invest, all of which is used as your margin.

Take Profit Ratio: When the profit/loss ratio between the latest mark price and the average entry price is greater than or equal to the take profit ratio, the position will be closed at market price. This does not affect the normal operation of the strategy.

Stop Loss Ratio: When the profit/loss ratio between the latest mark price and the average entry price is less than or equal to the stop loss ratio, the position will be closed at market price. This does not affect the normal operation of the strategy.

Auto Stop Loss Ratio: When the loss on your total investment reaches this ratio, the strategy will execute a position close and exit.

Fast MA, Slow MA, Period: Standard MA parameters.

RSI Period: The number of candlesticks (K-lines) used to calculate the RSI.

RSI Threshold: The RSI threshold, which must be greater than 0 and less than 50.

Order Quantity: The number of contracts the strategy will execute after a signal is triggered.

Default Order Quantity:

Inverse Contracts:

s = (Margin × Latest Price) / (2 × 0.00075 + (1/Leverage))
size = s / Contract Size

Linear Contracts:

s = (Margin) / (2 × 0.00075 + (1/Leverage)) × Latest Price
size = s / Contract Size
The actual order quantity will be the minimum of the default calculated value and the user-set value.

6. Example Operation

After creating a strategy, users can find their running strategies under [My Bots]. If both the dual moving average and RSI system indicators are met, the strategy’s [Details] page will display relevant positions, orders, and detailed strategy information. If you want to take profit or cut losses in real time, you can choose to close the position or terminate the strategy. You can also clone the strategy or transfer funds as needed.

Gate reserves the final right of interpretation for this product.

Sign up now for your chance to win up to $10,000!
signup-tips