OPEN-SOURCE SCRIPT

Moving Average Channel (MAC)

The strategy uses two Simple Moving Averages (SMA): an upper MA based on the high price and a lower MA based on the low price. Key features include:

Entry Condition: Enter a long position after five consecutive bars close above the upper MA.
Exit Conditions:
Close the position if five consecutive bars close below the lower MA.
Close the position if the price drops below 25% of the highest price recorded since entry (stop-loss).

Key Features:
Dynamic Entry: Long position is triggered only after consistent strength in price (5 bars above the upper MA).
Dynamic Exit:
Tracks weakness (5 bars below the lower MA) for exit.
Implements a stop-loss based on 25% retracement from the highest price recorded post-entry.
Customizable Parameters: MA lengths and stop-loss percentage are adjustable to fit different trading styles and market conditions.
This script provides a simple yet effective trend-following strategy with built-in risk management.






Bands and ChannelsTrend Analysis

Script open-source

Dans le plus pur esprit TradingView, l'auteur de ce script l'a publié en open-source, afin que les traders puissent le comprendre et le vérifier. Bravo à l'auteur! Vous pouvez l'utiliser gratuitement, mais la réutilisation de ce code dans une publication est régie par nos Règles. Vous pouvez le mettre en favori pour l'utiliser sur un graphique.

Vous voulez utiliser ce script sur un graphique ?

Clause de non-responsabilité