OPEN-SOURCE SCRIPT

Linear trend

By TradingAmmo
Simple way how to use Linear Regression for trading.

What we use:
• Linear Regression
• EMA 200 as a trend filter

Logic:
Firstly we make two different linear regression movings as oscillator. For this we need to subtract slow moving from fast moving, so we get the single moving around zero. This is the green/red line which appears on the chart.
The trade open when LR cross over the threshold. The trade close when LR cross under the threshold below. Crossing over the threshold is the same as faster moving cross over slower moving.
Also we use EMA as a filter. The trades would be only when the price is over than EMA 200.
botlinearlineartrendlinregOscillatorsstrategyTrend AnalysisusdtVolatility
TradingAmmo
Ready-made strategies for auto trading | Binance | OKX | KuCoin |
tradingapp.pro

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer