Type/to search

Wave Trend and VWMA Based Trend Following Quant Strategy

Common strategy
Created: 2024-01-26 17:35:29
Last modified: 3 years ago
1
Follow
1802
Followers

img

Overview

This strategy combines the Wave Trend oscillator and VWMA indicator to implement a trend following quant trading strategy. It can identify market trends and make buy or sell decisions based on signals from the Wave Trend oscillator. Meanwhile, trade size is determined by signals from the VWMA indicator.

Strategy Logic

The strategy is mainly based on the following two indicators:

  1. Wave Trend Oscillator: This is an oscillator ported to TradingView by LazyBear, which identifies "waves" in price fluctuations and generates buy/sell signals. The specific calculation is: first calculate the average price ap, then calculate the EMA of ap (called esa), then calculate the EMA of the absolute value of the difference between ap and esa (called d), finally calculate the consistency index ci=(ap-esa)/(0.015*d), the EMA of ci is the Wave Trend (wt1), and the 4-period SMA of wt1 is wt2. When wt1 crosses above wt2, it is a buy signal, and when wt1 crosses below wt2, it is a sell signal.

  2. VWMA Indicator: This is a volume weighted moving average line. Based on whether the price is inside or outside the VWMA Bands (Upper and lower bands of VWMA), it generates +1 (bullish), 0 (neutral) or -1 (bearish) signals.

The Wave Trend signals determine when to buy and sell. While the bullish/bearish signals from VWMA indicator determine the specific trade size for each trade.

Advantages

  • Combines signals from two indicators to improve decision accuracy
  • VWMA considers volume flow to judge market strength
  • Customizable trading sessions to avoid volatility from news
  • Trade size adjusted based on VWMA signals to reduce risks

Risks

  • Potential false signals from Wave Trend
  • Inaccurate volume data may affect VWMA
  • Requires long historical data for indicator calculation
  • No stop loss in place

Optimization

  • Test different parameter combinations to find optimum
  • Add stop loss strategies
  • Consider combining with other indicators for signal filtering
  • Test different settings for trading sessions
  • Dynamically adjust trade size calculation

Conclusion

This strategy integrates trend judgment and volume capabilities for an advanced trend following approach. It has some edges but also risks to note. Further improvements in parameters and rules may enhance its stability and profitability.

Source
Pine
/*backtest
start: 2023-12-26 00:00:00
end: 2024-01-25 00:00:00
period: 1h
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

// This source code is subject to the terms of the Mozilla Public License 2.0 at
// https://mozilla.org/MPL/2.0/
//
// Created by jadamcraig
Strategy parameters
Strategy parameters
Base Quantity
Limit Signals to Trading Sessions?
Session 1: Start Hour
Session 1: Start Minute
Session 1: Stop Hour
Session 1: Stop Minute
Session 2: Start Hour
Session 2: Start Minute
Session 2: Stop Hour
Session 2: Stop Minute
Close All at End of Session 1
Close All at End of Session 2
VWMA: Use Volume (uncheck if equity does not have volume)
VWMA: Length
Wave Trend: Channel Length
Wave Trend: Average Length
Wave Trend: Over Bought Level 1
Wave Trend: Over Bought Level 2
Wave Trend: Over Sold Level 1
Wave Trend: Over Sold Level 2
Comment
All comments (0)
No data
No data
  • 1
Forums
PINE Language
Get the app
iPhone Download
© 2015 - ∞ INVENTOR PTE LTD (SG)