Jalambi Paul modelKey Components
Inputs:
Window Length (window): The number of periods for calculating the rolling statistics. Default is set to 50.
Risk Percentage (risk_percentage): The percentage of capital risked per trade. Default is 1.0%.
Stop Loss and Take Profit Levels:
Stop Loss: Default is 2% of the entry price.
Take Profit: Default is 4% of the entry price.
Logarithmic Returns:
Calculates the logarithmic return of the price series using:
log_return
=
log
(
close
close
)
log_return=log(
close
close
)
This helps in normalizing price changes.
Rolling Statistics:
Mean (rolling_mean): Calculated over the rolling window using the Simple Moving Average (SMA).
Standard Deviation (rolling_std): Measured over the rolling window to understand volatility.
Shiryaev-Zhou Index (SZI):
The SZI is a standardized z-score:
SZI
=
log_return
−
rolling_mean
rolling_std
SZI=
rolling_std
log_return−rolling_mean
This metric is used to detect overbought or oversold conditions.
Signal Generation:
Buy Signal (long_signal): Triggered when SZI is below a fixed threshold (-2.0).
Sell Signal (short_signal): Triggered when SZI is above a fixed threshold (2.0).
Visuals on the Chart:
Buy signals are plotted below the price bars with green upward-pointing labels.
Sell signals are plotted above the price bars with red downward-pointing labels.
Trade Execution:
Entry Conditions:
Long positions are opened when long_signal is true.
Short positions are opened when short_signal is true.
Exit Conditions:
Stop Loss and Take Profit levels are calculated based on the entry price and the respective percentage inputs.
Positions are closed automatically when these levels are hit.
Visualization:
Plots the stop-loss (red line) and take-profit (green line) levels on the chart for easier tracking.
Moyennes mobiles
EMA Strategy with Price & EMA5 & EMA8 < EMA50 ConditionEMAile al-sat testi gerçekleştirildi.
Stratejiler güncellenmeye devam edecek. vakit olursa tabi
XRP/USD Scalping Strategy with Alerts
The strategy in your script is designed for scalping XRP/USD, utilizing a combination of Exponential Moving Averages (EMAs), Relative Strength Index (RSI), Volume analysis, and N-Bar detection to identify potential buy and sell signals. It aims to make quick, small profits by taking advantage of short-term price movements. Here's a detailed breakdown:
Key Components of the Strategy:
Exponential Moving Averages (EMAs):
Short EMA (8-period) and Long EMA (21-period) are used to identify the trend.
A buy signal is generated when the Short EMA crosses above the Long EMA (bullish crossover).
A sell signal is generated when the Short EMA crosses below the Long EMA (bearish crossunder).
Relative Strength Index (RSI):
The RSI (with a 14-period) is used to assess whether the market is in an overbought or oversold condition.
For a long position, the strategy checks if the RSI is above 50 to ensure that the market is not in an oversold condition.
For a short position, the strategy checks if the RSI is below 50, which signals a weaker or bearish market.
Volume Analysis:
The strategy checks if the current volume is greater than the average volume over a defined period (20 bars in this case).
Higher volume indicates stronger market participation and gives more confidence in the signals.
N-Bar Detection:
The strategy uses a custom function to detect the price action of the last n bars.
Bullish N-bars: If the lowest low of the last n_bars is higher than the lowest low of the previous 2*n_bars (indicating a bullish reversal pattern).
Bearish N-bars: If the highest high of the last n_bars is lower than the highest high of the previous 2*n_bars (indicating a bearish reversal pattern).
Buy (Long) Condition:
EMA Crossover: The Short EMA crosses above the Long EMA, indicating a potential upward trend.
RSI > 50: The market is not in an oversold state (indicating that the market is bullish).
Volume > Average Volume: The current volume is higher than the average volume, signaling increased market activity.
Bullish N-bars: The price action of the last n_bars shows a bullish reversal, providing additional confirmation for a buy.
Sell (Short) Condition:
EMA Crossunder: The Short EMA crosses below the Long EMA, indicating a potential downward trend.
RSI < 50: The market is not in an overbought state (indicating that the market is bearish).
Volume > Average Volume: The current volume is higher than the average volume, signaling increased market activity.
Bearish N-bars: The price action of the last n_bars shows a bearish reversal, providing additional confirmation for a sell.
Take Profit and Stop Loss:
The strategy includes a take profit and stop loss mechanism to limit the risk and secure profits.
Take Profit: Set at 1.5% of the entry price.
Stop Loss: Set at 0.7% of the entry price.
Alerts:
The strategy has alerts for both buy and sell signals.
When the buy or sell conditions are met, it triggers an alert, sending notifications (pop-up, email, etc.) to the user.
Summary of the Strategy:
Trend Following with EMA: The strategy relies on the crossover of short and long EMAs to determine the trend direction.
Momentum Analysis with RSI: The RSI confirms that the market is not overbought or oversold, ensuring that the trade is made in favorable conditions.
Volume Confirmation: Only signals with increased market participation (higher volume than the average) are considered valid.
Reversal Patterns with N-bars: The N-bar detection adds a layer of confirmation for potential reversals, improving the accuracy of entry signals.
Risk Management: The take profit and stop loss levels are designed to capture small, profitable moves while protecting from large losses.
This scalping strategy aims for quick, small profits with controlled risk, making it suitable for highly liquid markets like XRP/USD. The use of EMAs, RSI, volume analysis, and N-bar patterns increases the reliability of the signals and helps minimize false entries.
RMA 15 and RMA 10 Cross Strategy (Exit on Next Signal)
The RMA Cross Strategy involves using two Rolling Moving Averages (RMA), typically one with a short period (e.g., 10) and another with a longer period (e.g., 15). The strategy generates trading signals based on the crossover of these RMAs:
Signals:
Buy Signal: When the RMA with a shorter period (RMA 10) crosses above the RMA with a longer period (RMA 15), indicating an upward trend.
Sell Signal: When the RMA with a shorter period (RMA 10) crosses below the RMA with a longer period (RMA 15), indicating a downward trend.
mentor+json+v1.0This script implements a straightforward trend-following strategy based on moving averages (EMAs) and RSI confirmation. It is designed to help traders identify potential trend-based entry and exit points while managing risk with a customizable stop loss.
Key Features:
EMA Crossover: Buy signals occur when the short EMA crosses above the long EMA, and RSI is above a specified level. Sell signals are generated when the short EMA crosses below the long EMA, and RSI is below the specified level.
Stop Loss: A percentage-based stop loss is applied to all trades, ensuring effective risk management. The stop loss level is displayed as a dashed line on the chart.
Customization: Users can adjust the EMA lengths, RSI confirmation level, and stop loss percentage to match their trading strategy.
How to Use:
Add the script to your chart and adjust the inputs in the settings panel:
Short EMA Length: Determines the sensitivity of the short moving average.
Long EMA Length: Controls the trend-following component.
RSI Confirmation Level: Ensures trades are aligned with momentum.
Stop Loss (%): Defines the percentage level at which the stop loss is set.
Observe the buy and sell signals marked on the chart.
Use the stop loss line as a visual guide to manage risk for your trades.
Notes:
This script is intended for educational purposes and backtesting. Use it responsibly and in combination with other analysis techniques.
Always perform thorough backtesting and analysis before applying it to live trading.
Happy trading! 🚀
Adaptive VWAP Bands with Garman Klass VolatilityThis strategy utilizes the volume weighted average price, adjusted by volatility. Standard deviation bands are applied to the MA, if price closes above 1STD this indicates a bullish trend and the strategy goes long. If a close below 1STD the long is closed.
The standard deviation bands are adjusted by volatility using the Garman-Klass volatility formula: portfolioslab.com
The assumption is the more volatile an asset the less price is being accepted in a certain price range and thus the threshold to go long or close a long increases. In the inverse, the less volatile an asset is the more it's being accepted, then the threshold for a bullish breakout is lowered.
Buy The Deep Final Version V3 -grid version"Buy The Deep Final Version V3" Indicator Description"
The "Buy The Deep Final Version V3" is an advanced trading strategy designed to help traders automate and optimize their entry, position sizing, and exit points in volatile markets. Below is a detailed explanation of its features, inputs, and functionality.
---
Key Features
1. Dynamic Position Sizing :
- Calculates position size dynamically based on the trader's initial capital, current profit, and leverage settings.
- Provides options for reinvesting profits or maintaining fixed position sizes.
2. Volatility-Based Entry :
- Identifies "buy-the-dip" opportunities based on a calculated volatility percentage (`val`).
3. Automated Take Profit and Stop Loss :
- Automatically sets take profit (`tp`) and stop loss (`tp22`) levels using predefined percentages, ensuring effective risk management.
4. SMA-Based Conditions :
- Utilizes a Simple Moving Average (SMA) as a baseline to determine whether to enter long positions.
5. Support for Additional Buy Levels :
- Allows dollar-cost averaging with multiple additional buy levels (`so1`, `so2`, etc.).
6. Leverage and Commission Customization :
- Users can set desired leverage and trading fees, which are incorporated into the calculations for precise execution.
7. Performance Tracking :
- Displays key metrics, including:
- Total profit and percentage
- Monthly and annual profit percentages
- Maximum drawdown (MDD)
- Win rate
- Includes a performance table and data window for real-time insights.
8. Time-Limited Testing :
- Allows users to test the strategy over specific time periods for refinement and validation.
---
"How It Works"
- Entry Conditions : The strategy identifies opportunities when the price crosses above the SMA or meets specific volatility thresholds.
- Position Sizing : Leverage and capital allocation are used to calculate optimal position sizes dynamically.
- Exit Points : Automated take profit or stop-loss orders minimize manual intervention.
---
Input Descriptions
This strategy provides various customizable input parameters to suit different trading needs. Each input is described below:
1. Initial Settings
- Profit Reinvest (`reinvest`) :
- Options: `True` or `False`
- Determines whether profits are reinvested to increase the size of subsequent trades.
- Long Buy % (`longper`) :
- Default: `6`
- Sets the percentage of initial capital to allocate for the first long position.
- Leverage (`lev`) :
- Default: `3`
- Sets the leverage multiplier for trades. For example, `3` means a 3x leverage is used.
- Fee % (`commission_value`) :
- Default: `0.044`
- Input the trading fee as a percentage. This value is factored into profit calculations.
- Decimal Places (`num`) :
- Default: `2`
- Determines how many decimal places are considered in calculations.
- Table Font Size (`texts`) :
- Default: `Normal`
- Sets the font size for the performance table. Options include `Tiny`, `Small`, `Normal`, and `Large`.
---
2. Volatility and Additional Buy Settings
- Volatility % (`val`) :
- Default: `-1.5`
- Sets the volatility percentage used to determine entry points.
- Additional Buy % (`so`) :
- Default: `-3`
- Defines the percentage drop at which additional buy orders are executed.
- Take Profit % (`tp`) :
- Default: `0.5`
- Specifies the percentage increase at which take profit orders are executed.
- Candle Count (`sl`) :
- Default: `1`
- Sets the number of candles to hold a position before closing it.
- Take Profit Stop-Loss % (`tp22`) :
- Default: `0.1`
- Sets the stop-loss threshold as a percentage below the average entry price.
- SMA Length (`len`) :
- Default: `48`
- Determines the period for calculating the Simple Moving Average (SMA).
---
3. Position Multipliers
- Position Multiplier Longline 4 (`long2_qty`) :
- Default: `1`
- Sets the size of the first additional buy position.
- Position Multiplier Longline 5 (`long3_qty`) :
- Default: `2`
- Sets the size of the second additional buy position.
- Position Multiplier Longline 4 (`long4_qty`) :
- Default: `4`
- Sets the size of the third additional buy position.
- Position Multiplier Longline 5 (`long5_qty`) :
- Default: `8`
- Sets the size of the fourth additional buy position.
---
Three Moving Averages Strategythis is three moving averages strategy is good for day time frame best for swing trading , probability vary for 60 to 80 to increase the probability add other indictors . you can rsi or macd.
Bitcoin Exponential Profit Strategy### Strategy Description:
The **Bitcoin Trading Strategy** is an **Exponential Moving Average (EMA) crossover strategy** designed to identify bullish trends for Bitcoin.
1. **Indicators**:
- **Fast EMA (default 9 periods)**: Represents the short-term trend.
- **Slow EMA (default 21 periods)**: Represents the longer-term trend.
2. **Entry Condition**:
- A **bullish crossover** occurs when the Fast EMA crosses above the Slow EMA.
- The strategy enters a **long position** with a user-defined order size (default 0.01 BTC).
3. **Exit Conditions**:
- **Take Profit**: Closes the position when the profit target is reached (default $100).
- **Stop Loss**: Closes the position when the price drops below the stop loss level (default $50).
- **Bearish Crossunder**: Closes the position when the Fast EMA crosses below the Slow EMA.
4. **Visual Signals**:
- **BUY signals**: Displayed when a bullish crossover occurs.
- **SELL signals**: Displayed when a bearish crossunder occurs.
This strategy is optimized for trend-following behavior, ensuring positions are aligned with upward-moving trends while managing risk through clear stop-loss and take-profit levels.
Swing High/Low Pivots Strategy [LV]The Swing High/Low Pivots Strategy was developed as a counter-momentum trading tool.
The strategy is suitable for any market and the default values used in the input settings menu are set for Bitcoin (best on 15min). These values, expressed in minimum ticks (or pips if symbol is Forex) make this tool perfectly adaptable to every symbol and/or timeframe.
Check tooltips in the settings menu for more details about every user input.
STRTEGY ENTRY & EXIT MECHANISMS:
Trades Entry based on the detection of swing highs and lows for short and long entries respectively, validated by:
- Limit orders placed after each new pivot level confirmation
- Moving averages trend filter (if enabled)
- No active trade currently open
Trades Exit when the price reaches take-profit or stop-loss level as defined in the settings menu. A double entry/second take-profit level can be enabled for partial exits, with dynamic stop-loss adjustment for the remaining position.
Enhanced Trade Precision:
By limiting entries to confirmed swing high (HH, LH) or swing low (HL, LL) pivot points, the strategy ensures that trades occur at levels of significant price reversals. This precision reduces the likelihood of entering trades in the midst of a trend or during uncertain price action.
Risk Management Optimization:
The strategy incorporates clearly defined stop-loss (SL) and take-profit (TP) levels derived from the pivot points. This structured approach minimizes potential losses while locking in profits, which is critical for consistent performance in volatile markets.
Trend Filtering for Better Entry:
The use of a configurable moving average filter adds a layer of trend validation. This prevents entering trades against the dominant market trend, increasing the probability of success for each trade.
Avoidance of Noise:
The lookback period (length parameter) confirms pivots only after a set number of bars, effectively filtering out market noise and ensuring that entries are based on reliable, well-defined price movements.
Adaptability Across Markets:
The strategy is versatile and can be applied across different markets (Forex, stocks, crypto) due to its dynamic use of ticks and pips converters. It adapts seamlessly to varying price scales and asset types.
Dual Quantity Entries:
The original and optionnal double-entry mechanism allows traders to capture both short-term and extended profits by scaling out of positions. This adaptive approach caters to varying risk appetites and market conditions.
Clear Visualization:
The plotted pivot points, entry limits, SL, and TP levels provide visual clarity, making it easy for traders to track the strategy's behavior and make informed decisions.
Automated Execution with Alerts:
Integrated alerts for both entries and exits ensure timely actions without the need for constant market monitoring, enhancing efficiency. Configurable alert messages are suitable for API use.
Any feedback, comments, or suggestions for improvement are always welcome.
Hope you enjoy!
IU EMA Channel StrategyIU EMA Channel Strategy
Overview:
The IU EMA Channel Strategy is a simple yet effective trend-following strategy that uses two Exponential Moving Averages (EMAs) based on the high and low prices. It provides clear entry and exit signals by identifying price crossovers relative to the EMAs while incorporating a built-in Risk-to-Reward Ratio (RTR) for effective risk management.
Inputs ( Settings ):
- RTR (Risk-to-Reward Ratio): Define the ratio for risk-to-reward (default = 2).
- EMA Length: Adjust the length of the EMA channels (default = 100).
How the Strategy Works
1. EMA Channels:
- High-based EMA: EMA calculated on the high price.
- Low-based EMA: EMA calculated on the low price.
The area between these two EMAs creates a "channel" that visually highlights potential support and resistance zones.
2. Entry Rules:
- Long Entry: When the price closes above the high-based EMA (crossover).
- Short Entry: When the price closes below the low-based EMA (crossunder).
These entries ensure trades are taken in the direction of momentum.
3. Stop Loss (SL) and Take Profit (TP):
- Stop Loss:
- For long positions, the SL is set at the previous bar's low.
- For short positions, the SL is set at the previous bar's high.
- Take Profit:
- TP is automatically calculated using the Risk-to-Reward Ratio (RTR) you define.
- Example: If RTR = 2, the TP will be 2x the risk distance.
4. Exit Rules:
- Positions are closed at either the stop loss or the take profit level.
- The strategy manages exits automatically to enforce disciplined risk management.
Visual Features
1. EMA Channels:
- The high and low EMAs are dynamically color-coded:
- Green: Price is above the EMA (bullish condition).
- Red: Price is below the EMA (bearish condition).
- The area between the EMAs is shaded for better visual clarity.
2. Stop Loss and Take Profit Zones:
- SL and TP levels are plotted for both long and short positions.
- Zones are filled with:
- Red: Stop Loss area.
- Green: Take Profit area.
Be sure to manage your risk and position size properly.
DAILY Supertrend + EMA Crossover with RSI FilterThis strategy is a technical trading approach that combines multiple indicators—Supertrend, Exponential Moving Averages (EMAs), and the Relative Strength Index (RSI)—to identify and manage trades.
Core Components:
1. Exponential Moving Averages (EMAs):
Two EMAs, one with a shorter period (fast) and one with a longer period (slow), are calculated. The idea is to spot when the faster EMA crosses above or below the slower EMA. A fast EMA crossing above the slow EMA often suggests upward momentum, while crossing below suggests downward momentum.
2. Supertrend Indicator:
The Supertrend uses Average True Range (ATR) to establish dynamic support and resistance lines. These lines shift above or below price depending on the prevailing trend. When price is above the Supertrend line, the trend is considered bullish; when below, it’s considered bearish. This helps ensure that the strategy trades only in the direction of the overall trend rather than against it.
3. RSI Filter:
The RSI measures momentum. It helps avoid buying into markets that are already overbought or selling into markets that are oversold. For example, when going long (buying), the strategy only proceeds if the RSI is not too high, and when going short (selling), it only proceeds if the RSI is not too low. This filter is meant to improve the quality of the trades by reducing the chance of entering right before a reversal.
4. Time Filters:
The strategy only triggers entries during user-specified date and time ranges. This is useful if one wants to limit trading activity to certain trading sessions or periods with higher market liquidity.
5. Risk Management via ATR-based Stops and Targets:
Both stop loss and take profit levels are set as multiples of the ATR. ATR measures volatility, so when volatility is higher, both stops and profit targets adjust to give the trade more breathing room. Conversely, when volatility is low, stops and targets tighten. This dynamic approach helps maintain consistent risk management regardless of market conditions.
Overall Logic Flow:
- First, the market conditions are analyzed through EMAs, Supertrend, and RSI.
- When a buy (long) condition is met—meaning the fast EMA crosses above the slow EMA, the trend is bullish according to Supertrend, and RSI is below the specified “overbought” threshold—the strategy initiates or adds to a long position.
- Similarly, when a sell (short) condition is met—meaning the fast EMA crosses below the slow EMA, the trend is bearish, and RSI is above the specified “oversold” threshold—it initiates or adds to a short position.
- Each position is protected by an automatically calculated stop loss and a take profit level based on ATR multiples.
Intended Result:
By blending trend detection, momentum filtering, and volatility-adjusted risk management, the strategy aims to capture moves in the primary trend direction while avoiding entries at excessively stretched prices. Allowing multiple entries can potentially amplify gains in strong trends but also increases exposure, which traders should consider in their risk management approach.
In essence, this strategy tries to ride established trends as indicated by the Supertrend and EMAs, filter out poor-quality entries using RSI, and dynamically manage trade risk through ATR-based stops and targets.
3 EMA + RSI with Trail Stop [Free990] (LOW TF)This trading strategy combines three Exponential Moving Averages (EMAs) to identify trend direction, uses RSI to signal exit conditions, and applies both a fixed percentage stop-loss and a trailing stop for risk management. It aims to capture momentum when the faster EMAs cross the slower EMA, then uses RSI thresholds, time-based exits, and stops to close trades.
Short Explanation of the Logic
Trend Detection: When the 10 EMA crosses above the 20 EMA and both are above the 100 EMA (and the current price bar closes higher), it triggers a long entry signal. The reverse happens for a short (the 10 EMA crosses below the 20 EMA and both are below the 100 EMA).
RSI Exit: RSI crossing above a set threshold closes long trades; crossing below another threshold closes short trades.
Time-Based Exit: If a trade is in profit after a set number of bars, the strategy closes it.
Stop-Loss & Trailing Stop: A fixed stop-loss based on a percentage from the entry price guards against large drawdowns. A trailing stop dynamically tightens as the trade moves in favor, locking in potential gains.
Detailed Explanation of the Strategy Logic
Exponential Moving Average (EMA) Setup
Short EMA (out_a, length=10)
Medium EMA (out_b, length=20)
Long EMA (out_c, length=100)
The code calculates three separate EMAs to gauge short-term, medium-term, and longer-term trend behavior. By comparing their relative positions, the strategy infers whether the market is bullish (EMAs stacked positively) or bearish (EMAs stacked negatively).
Entry Conditions
Long Entry (entryLong): Occurs when:
The short EMA (10) crosses above the medium EMA (20).
Both EMAs (short and medium) are above the long EMA (100).
The current bar closes higher than it opened (close > open).
This suggests that momentum is shifting to the upside (short-term EMAs crossing up and price action turning bullish). If there’s an existing short position, it’s closed first before opening a new long.
Short Entry (entryShort): Occurs when:
The short EMA (10) crosses below the medium EMA (20).
Both EMAs (short and medium) are below the long EMA (100).
The current bar closes lower than it opened (close < open).
This indicates a potential shift to the downside. If there’s an existing long position, that gets closed first before opening a new short.
Exit Signals
RSI-Based Exits:
For long trades: When RSI exceeds a specified threshold (e.g., 70 by default), it triggers a long exit. RSI > short_rsi generally means overbought conditions, so the strategy exits to lock in profits or avoid a pullback.
For short trades: When RSI dips below a specified threshold (e.g., 30 by default), it triggers a short exit. RSI < long_rsi indicates oversold conditions, so the strategy closes the short to avoid a bounce.
Time-Based Exit:
If the trade has been open for xBars bars (configurable, e.g., 24 bars) and the trade is in profit (current price above entry for a long, or current price below entry for a short), the strategy closes the position. This helps lock in gains if the move takes too long or momentum stalls.
Stop-Loss Management
Fixed Stop-Loss (% Based): Each trade has a fixed stop-loss calculated as a percentage from the average entry price.
For long positions, the stop-loss is set below the entry price by a user-defined percentage (fixStopLossPerc).
For short positions, the stop-loss is set above the entry price by the same percentage.
This mechanism prevents catastrophic losses if the market moves strongly against the position.
Trailing Stop:
The strategy also sets a trail stop using trail_points (the distance in price points) and trail_offset (how quickly the stop “catches up” to price).
As the market moves in favor of the trade, the trailing stop gradually tightens, allowing profits to run while still capping potential drawdowns if the price reverses.
Order Execution Flow
When the conditions for a new position (long or short) are triggered, the strategy first checks if there’s an opposite position open. If there is, it closes that position before opening the new one (prevents going “both long and short” simultaneously).
RSI-based and time-based exits are checked on each bar. If triggered, the position is closed.
If the position remains open, the fixed stop-loss and trailing stop remain in effect until the position is exited.
Why This Combination Works
Multiple EMA Cross: Combining 10, 20, and 100 EMAs balances short-term momentum detection with a longer-term trend filter. This reduces false signals that can occur if you only look at a single crossover without considering the broader trend.
RSI Exits: RSI provides a momentum oscillator view—helpful for detecting overbought/oversold conditions, acting as an extra confirmation to exit.
Time-Based Exit: Prevents “lingering trades.” If the position is in profit but failing to advance further, it takes profit rather than risking a trend reversal.
Fixed & Trailing Stop-Loss: The fixed stop-loss is your safety net to cap worst-case losses. The trailing stop allows the strategy to lock in gains by following the trade as it moves favorably, thus maximizing profit potential while keeping risk in check.
Overall, this approach tries to capture momentum from EMA crossovers, protect profits with trailing stops, and limit risk through both a fixed percentage stop-loss and exit signals from RSI/time-based logic.
DemaRSI StrategyThis is a repost to a old script that cant be updated anymore, the request was made on Feb, 27, 2016.
Here's a engaging description for the tradingview script:
**DemaRSI Strategy: A Proven Trading System**
Join thousands of traders who have already experienced the power of this highly effective strategy. The DemaRSI system combines two powerful indicators - DEMA (Double Exponential Moving Average) and RSI (Relative Strength Index) - to generate profitable trades with minimal risk.
**Key Features:**
* **Trend-Following**: Our algorithm identifies strong trends using a combination of DEMA and RSI, allowing you to ride the waves of market momentum.
* **Risk Management**: The system includes built-in stop-loss and take-profit levels, ensuring that your gains are protected and losses are minimized.
* **Session-Based Trading**: Trade during specific sessions only (e.g., London or New York) for even more targeted results.
* **Customizable Settings**: Adjust the length of moving averages, RSI periods, and other parameters to suit your trading style.
**What You'll Get:**
* A comprehensive strategy that can be used with any broker or platform
* Easy-to-use interface with customizable settings
* Real-time performance metrics and backtesting capabilities
**Start Trading Like a Pro Today!**
This script is designed for intermediate to advanced traders who want to take their trading game to the next level. With its robust risk management features, this strategy can help you achieve consistent profits in various market conditions.
**Disclaimer:** This script is not intended as investment advice and should be used at your own discretion. Trading carries inherent risks, and losses are possible.
~Llama3
MicuRobert EMA Cross StrategyThis is a repost of a old strategy that cant be updated anymore, it was a request for a user made in Oct, 6, 2015
Here's a possible engaging description for the tradingview script:
**MicuRobert EMA Cross V2: A Powerful Trading Strategy**
Join the ranks of successful traders with this advanced strategy, designed to help you profit from market trends. The MicuRobert EMA Cross V2 combines two essential indicators - Exponential Moving Average (EMA) and Divergence EMA (DEMA) - to generate buy and sell signals.
**Key Features:**
* **Trading Session Filter**: Only trade during your preferred session, ensuring you're in sync with market conditions.
* **Trailing Stop**: Automatically adjust stop-loss levels to lock in profits or limit losses.
* **Customizable Trade Size**: Set the size of each trade based on your risk tolerance and trading goals.
**How it Works:**
The script uses two EMAs (5-period and 34-period) to identify trends. When the shorter EMA crosses above the longer one, a buy signal is generated. Conversely, when the shorter EMA falls below the longer one, a sell signal is triggered. The strategy also incorporates divergence analysis between price action and the EMAs.
**Visual Aids:**
* **EMA Plots**: Visualize the two EMAs on your chart to gauge market momentum.
* **Buy/Sell Signals**: See when buy or sell signals are generated, along with their corresponding entry prices.
* **Trailing Stop Lines**: Monitor stop-loss levels as they adjust based on price action.
**Get Started:**
Download this script and start trading like a pro! With its robust features and customizable settings, the MicuRobert EMA Cross V2 is an excellent addition to any trader's arsenal.
~Llama3
Precision Trading Strategy: Golden EdgeThe PTS: Golden Edge strategy is designed for scalping Gold (XAU/USD) on lower timeframes, such as the 1-minute chart. It captures high-probability trade setups by aligning with strong trends and momentum, while filtering out low-quality trades during consolidation or low-volatility periods.
The strategy uses a combination of technical indicators to identify optimal entry points:
1. Exponential Moving Averages (EMAs): A fast EMA (3-period) and a slow EMA (33-period) are used to detect short-term trend reversals via crossover signals.
2. Hull Moving Average (HMA): A 66-period HMA acts as a higher-timeframe trend filter to ensure trades align with the overall market direction.
3. Relative Strength Index (RSI): A 12-period RSI identifies momentum. The strategy requires RSI > 55 for long trades and RSI < 45 for short trades, ensuring entries are backed by strong buying or selling pressure.
4. Average True Range (ATR): A 14-period ATR ensures trades occur only during volatile conditions, avoiding choppy or low-movement markets.
By combining these tools, the PTS: Golden Edge strategy creates a precise framework for scalping and offers a systematic approach to capitalize on Gold’s price movements efficiently.
TTM Grid StrategyThis strategy uses a TTM (based on EMAs of highs and lows) to determine the market's trend direction.
It then deploys a grid trading system around a dynamically updated base price, with the grid's direction and levels adjusting based on the trend.
Trades are executed as the price crosses the predefined grid levels, with the strategy risking a set percentage of equity per trade.
Core Strategy Logic:
TTM State Calculation (ttmState() function):
* Calculates two EMAs based on the `ttmPeriod`: one for the lows (`lowMA`) and one for the highs (`highMA`).
* Defines two threshold levels: `lowThird` (1/3 from the bottom) and `highThird` (2/3 from the bottom) of the range between `highMA` and `lowMA`.
* Returns the current TTM state as an integer:
+ `1` if the close price is above `highThird` (indicating an uptrend).
+ `0` if the close price is below `lowThird` (indicating a downtrend).
+ `-1` if the close price is between `lowThird` and `highThird` (indicating a neutral state).
VIDYA Auto-Trading(Reversal Logic)
Purpose and Unique Features
This script leverages the Variable Index Dynamic Average (VIDYA) to implement a dynamic trend-following auto-trading strategy. By adapting to price volatility, it optimizes entry points and strengthens risk management. Key differentiators of this strategy include:
VIDYA Characteristics:
Quickly responds to price momentum changes through dynamic calculations.
Incorporates volatility adjustments for enhanced trend detection accuracy.
ATR Band Utilization:
Measures market volatility to set stop-loss levels and guide risk management.
Supports more calculated trade entries in volatile markets.
Visual Trend Representation:
Displays "green zones" for uptrends and "red zones" for downtrends.
Enables intuitive understanding of trend continuation and reversal.
Usage Instructions
Entry Conditions
Long Entry:
Enter when the price crosses above the upper band.
Close any previous short positions and initiate a new long position.
Short Entry:
Enter when the price crosses below the lower band.
Close any previous long positions and initiate a new short position.
Exit Conditions
Take Profit and Stop Loss:
Reverse Position Strategy or Position Reversal Strategy
Account Size: ¥100,0000
Commissions and Slippage: Assumed commission of 94 pips per trade and slippage of 1 pip.
Risk per Trade: 10% of account equity (adjustable based on risk tolerance).
Script Parameters
VIDYA Length: The period for calculating the trend (e.g., 14).
Momentum Period: The lookback period for calculating the Chande Momentum Oscillator (CMO).
ATR Band Distance: Adjustment coefficient for the band width (e.g., 1.5).
Price Source: Choose from close, open, high, or low prices for VIDYA calculation.
Trend Display Colors: Customize the colors for uptrend and downtrend zones.
Visualization Options: Toggle the display of trend lines, bands, and other elements on or off.
Strategy Features and Enhancements
Dynamic Momentum Adaptation:
Utilizes VIDYA's sensitivity to momentum changes for rapid trend detection.
Volatility-Aware Risk Management:
Employs ATR to dynamically adjust risk levels, ensuring resilience in volatile markets.
Enhanced Visual Indicators:
Clearly plots trend zones and entry points on the chart.
Simplifies analysis with intuitive visual cues.
Credits
This script is inspired by the innovative work of BigBeluga, whose indicators laid the foundation for this enhanced trend-following strategy. By leveraging BigBeluga’s insights, this script integrates VIDYA, ATR Bands, and other technical elements to create a more dynamic and intuitive trading tool.
We extend our gratitude to BigBeluga and the broader trading community for their invaluable contributions, which have enabled this advanced implementation.
Disclaimer:
This script is provided for educational purposes, and past performance does not guarantee future results. Always practice proper risk management in live trading scenarios.
By leveraging VIDYA, this strategy provides a precise and intuitive approach to trend-following. It is particularly effective in capturing market reversals and adapting to sudden price changes in volatile environments.
DNSE VN301!, SMA & EMA Cross StrategyDiscover the tailored Pinescript to trade VN30F1M Future Contracts intraday, the strategy focuses on SMA & EMA crosses to identify potential entry/exit points. The script closes all positions by 14:25 to avoid holding any contracts overnight.
HNX:VN301!
www.tradingview.com
Setting & Backtest result:
1-minute chart, initial capital of VND 100 million, entering 4 contracts per time, backtest result from Jan-2024 to Nov-2024 yielded a return over 40%, executed over 1,000 trades (average of 4 trades/day), winning trades rate ~ 30% with a profit factor of 1.10.
The default setting of the script:
A decent optimization is reached when SMA and EMA periods are set to 60 and 15 respectively while the Long/Short stop-loss level is set to 20 ticks (2 points) from the entry price.
Entry & Exit conditions:
Long signals are generated when ema(15) crosses over sma(60) while Short signals happen when ema(15) crosses under sma(60). Long orders are closed when ema(15) crosses under sma(60) while Short orders are closed when ema(15) crosses over sma(60).
Exit conditions happen when (whichever came first):
Another Long/Short signal is generated
The Stop-loss level is reached
The Cut-off time is reached (14:25 every day)
*Disclaimers:
Futures Contracts Trading are subjected to a high degree of risk and price movements can fluctuate significantly. This script functions as a reference source and should be used after users have clearly understood how futures trading works, accessed their risk tolerance level, and are knowledgeable of the functioning logic behind the script.
Users are solely responsible for their investment decisions, and DNSE is not responsible for any potential losses from applying such a strategy to real-life trading activities. Past performance is not indicative/guarantee of future results, kindly reach out to us should you have specific questions about this script.
---------------------------------------------------------------------------------------
Khám phá Pinescript được thiết kế riêng để giao dịch Hợp đồng tương lai VN30F1M trong ngày, chiến lược tập trung vào các đường SMA & EMA cắt nhau để xác định các điểm vào/ra tiềm năng. Chiến lược sẽ đóng tất cả các vị thế trước 14:25 để tránh giữ bất kỳ hợp đồng nào qua đêm.
Thiết lập & Kết quả backtest:
Chart 1 phút, vốn ban đầu là 100 triệu đồng, vào 4 hợp đồng mỗi lần, kết quả backtest từ tháng 1/2024 tới tháng 11/2024 mang lại lợi nhuận trên 40%, thực hiện hơn 1.000 giao dịch (trung bình 4 giao dịch/ngày), tỷ lệ giao dịch thắng ~ 30% với hệ số lợi nhuận là 1,10.
Thiết lập mặc định của chiến lược:
Đạt được một mức tối ưu ổn khi SMA và EMA periods được đặt lần lượt là 60 và 15 trong khi mức cắt lỗ được đặt thành 20 tick (2 điểm) từ giá vào.
Điều kiện Mở và Đóng vị thế:
Tín hiệu Long được tạo ra khi ema(15) cắt trên sma(60) trong khi tín hiệu Short xảy ra khi ema(15) cắt dưới sma(60). Lệnh Long được đóng khi ema(15) cắt dưới sma(60) trong khi lệnh Short được đóng khi ema(15) cắt lên sma(60).
Điều kiện đóng vị thể xảy ra khi (tùy điều kiện nào đến trước):
Một tín hiệu Long/Short khác được tạo ra
Giá chạm mức cắt lỗ
Lệnh chưa đóng nhưng tới giờ cut-off (14:25 hàng ngày)
*Tuyên bố miễn trừ trách nhiệm:
Giao dịch hợp đồng tương lai có mức rủi ro cao và giá có thể dao động đáng kể. Chiến lược này hoạt động như một nguồn tham khảo và nên được sử dụng sau khi người dùng đã hiểu rõ cách thức giao dịch hợp đồng tương lai, đã đánh giá mức độ chấp nhận rủi ro của bản thân và hiểu rõ về logic vận hành của chiến lược này.
Người dùng hoàn toàn chịu trách nhiệm về các quyết định đầu tư của mình và DNSE không chịu trách nhiệm về bất kỳ khoản lỗ tiềm ẩn nào khi áp dụng chiến lược này vào các hoạt động giao dịch thực tế. Hiệu suất trong quá khứ không chỉ ra/cam kết kết quả trong tương lai, vui lòng liên hệ với chúng tôi nếu bạn có thắc mắc cụ thể về chiến lược giao dịch này.
Bollinger Breakout Strategy with Direction Control [4H crypto]Bollinger Breakout Strategy with Direction Control - User Guide
This strategy leverages Bollinger Bands, RSI, and directional filters to identify potential breakout trading opportunities. It is designed for traders looking to capitalize on significant price movements while maintaining control over trade direction (long, short, or both). Here’s how to use this strategy effectively:
How the Strategy Works
Indicators Used:
Bollinger Bands:
A volatility-based indicator with an upper and lower band around a simple moving average (SMA). The bands expand or contract based on market volatility.
RSI (Relative Strength Index):
Measures momentum to determine overbought or oversold conditions. In this strategy, RSI is used to confirm breakout strength.
Trade Direction Control:
You can select whether to trade:
Long only: Buy positions.
Short only: Sell positions.
Both: Trade in both directions depending on conditions.
Breakout Conditions:
Long Trade:
The price closes above the upper Bollinger Band.
RSI is above the midline (50), confirming upward momentum.
The "Trade Direction" setting allows either "Long" or "Both."
Short Trade:
The price closes below the lower Bollinger Band.
RSI is below the midline (50), confirming downward momentum.
The "Trade Direction" setting allows either "Short" or "Both."
Risk Management:
Stop-Loss:
Long trades: Set at 2% below the entry price.
Short trades: Set at 2% above the entry price.
Take-Profit:
Calculated using a Risk/Reward Ratio (default is 2:1).
Adjust this in the strategy settings.
Inputs and Customization
Key Parameters:
Bollinger Bands Length: Default is 20. Adjust based on the desired sensitivity.
Multiplier: Default is 2.0. Higher values widen the bands; lower values narrow them.
RSI Length: Default is 14, which is standard for RSI.
Risk/Reward Ratio: Default is 2.0. Increase for more aggressive profit targets, decrease for conservative exits.
Trade Direction:
Options: "Long," "Short," or "Both."
Example: Set to "Long" in a bullish market to focus only on buy trades.
How to Use This Strategy
Adding the Strategy:
Paste the script into TradingView’s Pine Editor and add it to your chart.
Setting Parameters:
Adjust the Bollinger Band settings, RSI, and Risk/Reward Ratio to fit the asset and timeframe you're trading.
Analyzing Signals:
Green line (Upper Band): Signals breakout potential for long trades.
Red line (Lower Band): Signals breakout potential for short trades.
Blue line (Basis): Central Bollinger Band (SMA), helpful for understanding price trends.
Testing the Strategy:
Use the Strategy Tester in TradingView to backtest performance on your chosen asset and timeframe.
Optimizing for Assets:
Forex pairs, cryptocurrencies (like BTC), or stocks with high volatility are ideal for this strategy.
Works best on higher timeframes like 4H or Daily.
Best Practices
Combine with Volume: Confirm breakouts with increased volume for higher reliability.
Avoid Sideways Markets: Use additional trend filters (like ADX) to avoid trades in low-volatility conditions.
Optimize Parameters: Regularly adjust the Bollinger Bands multiplier and RSI settings to match the asset's behavior.
By utilizing this strategy, you can effectively trade breakouts while maintaining flexibility in trade direction. Adjust the parameters to match your trading style and market conditions for optimal results!
Supertrend and MACD strategyThe Supertrend and MACD Strategy is a comprehensive trading approach designed to capitalize on market trends by using a combination of the Supertrend indicator, the Exponential Moving Average (EMA), and the Moving Average Convergence Divergence (MACD). This strategy aims to identify optimal entry and exit points for both long and short trades, while incorporating strict risk management rules.
Indicators Used:
Supertrend: This indicator is used to identify the overall trend direction. It provides clear signals for trend reversals, helping traders to enter trades in the direction of the prevailing trend.
200-period EMA: This long-term moving average is used to determine the primary trend direction. The strategy only takes long trades when the price is above the 200 EMA and short trades when the price is below it.
MACD: The MACD is used to gauge the momentum and confirm the signals provided by the Supertrend and EMA. It consists of the MACD line, the signal line, and the histogram.
Entry Conditions:
Long Entry:
The Supertrend indicator shows an uptrend (direction > 0).
The MACD line is above the signal line (macd > signal).
The price is above the 200-period EMA (close > ema200).
Short Entry:
The Supertrend indicator shows a downtrend (direction < 0).
The MACD line is below the signal line (macd < signal).
The price is below the 200-period EMA (close < ema200).
Exit Conditions:
Long Exit:
Exit the long position when the MACD line crosses below the signal line (ta.crossunder(macd, signal)).
Set a stop loss (SL) below the lowest low of the last 10 periods (lowestLow - 1).
Short Exit:
Exit the short position when the MACD line crosses above the signal line (ta.crossover(macd, signal)).
Set a stop loss (SL) above the highest high of the last 10 periods (highestHigh + 1).
Risk Management:
The strategy ensures that no new positions are opened if there is already an open trade, preventing overexposure in the market.
Alerts:
Alerts are set to notify traders when the MACD crosses the signal line, providing timely updates for potential exit points.
Triple CCI Strategy MFI Confirmed [Skyrexio]Overview
Triple CCI Strategy MFI Confirmed leverages 3 different periods Commodity Channel Index (CCI) indicator in conjunction Money Flow Index (MFI) and Exponential Moving Average (EMA) to obtain the high probability setups. Fast period CCI is used for having the high probability to enter in the direction of short term trend, middle and slow period CCI are used for confirmation, if market now likely in the mid and long-term uptrend. MFI is used to confirm trade with the money inflow/outflow with the high probability. EMA is used as an additional trend filter. Moreover, strategy uses exponential moving average (EMA) to trail the price when it reaches the specific level. More information in "Methodology" and "Justification of Methodology" paragraphs. The strategy opens only long trades.
Unique Features
Dynamic stop-loss system: Instead of fixed stop-loss level strategy utilizes average true range (ATR) multiplied by user given number subtracted from the position entry price as a dynamic stop loss level.
Configurable Trading Periods: Users can tailor the strategy to specific market windows, adapting to different market conditions.
Four layers trade filtering system: Strategy utilizes two different period CCI indicators, MFI and EMA indicators to confirm the signals produced by fast period CCI.
Trailing take profit level: After reaching the trailing profit activation level scrip activate the trailing of long trade using EMA. More information in methodology.
Methodology
The strategy opens long trade when the following price met the conditions:
Fast period CCI shall crossover the zero-line.
Slow and Middle period CCI shall be above zero-lines.
Price shall close above the EMA. Crossover is not obligatory
MFI shall be above 50
When long trade is executed, strategy set the stop-loss level at the price ATR multiplied by user-given value below the entry price. This level is recalculated on every next candle close, adjusting to the current market volatility.
At the same time strategy set up the trailing stop validation level. When the price crosses the level equals entry price plus ATR multiplied by user-given value script starts to trail the price with EMA. If price closes below EMA long trade is closed. When the trailing starts, script prints the label “Trailing Activated”.
Strategy settings
In the inputs window user can setup the following strategy settings:
ATR Stop Loss (by default = 1.75)
ATR Trailing Profit Activation Level (by default = 2.25)
CCI Fast Length (by default = 14, used for calculation short term period CCI)
CCI Middle Length (by default = 25, used for calculation short term period CCI)
CCI Slow Length (by default = 50, used for calculation long term period CCI)
MFI Length (by default = 14, used for calculation MFI
EMA Length (by default = 50, period of EMA, used for trend filtering EMA calculation)
Trailing EMA Length (by default = 20)
User can choose the optimal parameters during backtesting on certain price chart.
Justification of Methodology
Before understanding why this particular combination of indicator has been chosen let's briefly explain what is CCI, MFI and EMA.
The Commodity Channel Index (CCI) is a momentum-based technical indicator that measures the deviation of a security's price from its average price over a specific period. It helps traders identify overbought or oversold conditions and potential trend reversals.
The CCI formula is:
CCI = (Typical Price − SMA) / (0.015 × Mean Deviation)
Typical Price (TP): This is calculated as the average of the high, low, and closing prices for the period.
Simple Moving Average (SMA): This is the average of the Typical Prices over a specific number of periods.
Mean Deviation: This is the average of the absolute differences between the Typical Price and the SMA.
The result is a value that typically fluctuates between +100 and -100, though it is not bounded and can go higher or lower depending on the price movement.
The Money Flow Index (MFI) is a technical indicator that measures the strength of money flowing into and out of a security. It combines price and volume data to assess buying and selling pressure and is often used to identify overbought or oversold conditions. The formula for MFI involves several steps:
1. Calculate the Typical Price (TP):
TP = (high + low + close) / 3
2. Calculate the Raw Money Flow (RMF):
Raw Money Flow = TP × Volume
3. Determine Positive and Negative Money Flow:
If the current TP is greater than the previous TP, it's Positive Money Flow.
If the current TP is less than the previous TP, it's Negative Money Flow.
4. Calculate the Money Flow Ratio (MFR):
Money Flow Ratio = Sum of Positive Money Flow (over n periods) / Sum of Negative Money Flow (over n periods)
5. Calculate the Money Flow Index (MFI):
MFI = 100 − (100 / (1 + Money Flow Ratio))
MFI above 80 can be considered as overbought, below 20 - oversold.
The Exponential Moving Average (EMA) is a type of moving average that places greater weight and significance on the most recent data points. It is widely used in technical analysis to smooth price data and identify trends more quickly than the Simple Moving Average (SMA).
Formula:
1. Calculate the multiplier
Multiplier = 2 / (n + 1) , Where n is the number of periods.
2. EMA Calculation
EMA = (Current Price) × Multiplier + (Previous EMA) × (1 − Multiplier)
This strategy leverages Fast period CCI, which shall break the zero line to the upside to say that probability of short term trend change to the upside increased. This zero line crossover shall be confirmed by the Middle and Slow periods CCI Indicators. At the moment of breakout these two CCIs shall be above 0, indicating that there is a high probability that price is in middle and long term uptrend. This approach increases chances to have a long trade setup in the direction of mid-term and long-term trends when the short-term trend starts to reverse to the upside.
Additionally strategy uses MFI to have a greater probability that fast CCI breakout is confirmed by this indicator. We consider the values of MFI above 50 as a higher probability that trend change from downtrend to the uptrend is real. Script opens long trades only if MFI is above 50. As you already know from the MFI description, it incorporates volume in its calculation, therefore we have another one confirmation factor.
Finally, strategy uses EMA an additional trend filter. It allows to open long trades only if price close above EMA (by default 50 period). It increases the probability of taking long trades only in the direction of the trend.
ATR is used to adjust the strategy risk management to the current market volatility. If volatility is low, we don’t need the large stop loss to understand the there is a high probability that we made a mistake opening the trade. User can setup the settings ATR Stop Loss and ATR Trailing Profit Activation Level to realize his own risk to reward preferences, but the unique feature of a strategy is that after reaching trailing profit activation level strategy is trying to follow the trend until it is likely to be finished instead of using fixed risk management settings. It allows sometimes to be involved in the large movements. It’s also important to make a note, that script uses another one EMA (by default = 20 period) as a trailing profit level.
Backtest Results
Operating window: Date range of backtests is 2022.04.01 - 2024.11.25. It is chosen to let the strategy to close all opened positions.
Commission and Slippage: Includes a standard Binance commission of 0.1% and accounts for possible slippage over 5 ticks.
Initial capital: 10000 USDT
Percent of capital used in every trade: 50%
Maximum Single Position Loss: -4.13%
Maximum Single Profit: +19.66%
Net Profit: +5421.21 USDT (+54.21%)
Total Trades: 108 (44.44% win rate)
Profit Factor: 2.006
Maximum Accumulated Loss: 777.40 USDT (-7.77%)
Average Profit per Trade: 50.20 USDT (+0.85%)
Average Trade Duration: 44 hours
These results are obtained with realistic parameters representing trading conditions observed at major exchanges such as Binance and with realistic trading portfolio usage parameters.
How to Use
Add the script to favorites for easy access.
Apply to the desired timeframe and chart (optimal performance observed on 2h BTC/USDT).
Configure settings using the dropdown choice list in the built-in menu.
Set up alerts to automate strategy positions through web hook with the text: {{strategy.order.alert_message}}
Disclaimer:
Educational and informational tool reflecting Skyrex commitment to informed trading. Past performance does not guarantee future results. Test strategies in a simulated environment before live implementation
SMA Buy/Sell Strategy with Significant Slope and Dynamic TP/SLDescription:
This strategy uses a simple moving average (SMA) to detect trading opportunities based on the slope and proximity of price action. It ensures trades are only executed during significant trends, reducing false signals caused by sideways movements. The strategy incorporates dynamic risk management with an initial ambitious Take Profit (TP) and a Trailing Stop Loss (SL) to protect profits.
Key Features:
Trend Detection with SMA:
Two SMAs are calculated: one on High values and one on Low values.
Signals are generated when the price crosses these SMAs, ensuring:
Buy: Price closes above the SMA on High, with a significant upward slope.
Sell: Price closes below the SMA on Low, with a significant downward slope.
Slope Significance Check:
The slope of the SMA is calculated over a configurable period.
Only trends with a slope variation exceeding a user-defined percentage threshold are considered significant.
Dynamic Risk Management:
Ambitious Initial TP: Positions target a high percentage gain upon entry.
Trailing SL: Automatically adjusts as the price moves in favor of the trade, locking in profits.
Automatic Position Management:
Opposing signals close existing positions to avoid conflicting trades.
Configurable position size for risk control.
Parameters:
SMA Period: Number of candles for calculating the SMA.
Initial Take Profit (%): Percentage gain for the initial TP.
Trailing Stop Loss (%): Percentage for trailing SL based on the current price.
Slope Threshold (%): Minimum percentage change in SMA slope to confirm trend significance.
How It Works:
Buy Signal:
The price closes above the SMA on High values.
The slope of the SMA (on High) is positive and exceeds the slope threshold.
Sell Signal:
The price closes below the SMA on Low values.
The slope of the SMA (on Low) is negative and exceeds the slope threshold.
Exits:
A position closes at the Take Profit level, Trailing Stop Loss, or when an opposing signal is generated.
Use Case:
This strategy is ideal for trending markets where price action respects moving averages. It can be used on any timeframe or asset but is particularly effective in markets with clear directional movements.
Recommended Settings:
Timeframe: Works well on higher timeframes (e.g., 1H, 4H, Daily).
Slope Threshold (%): Default is 5%, adjust based on market volatility.
Initial TP and Trailing SL: Tailor to your risk/reward preferences.
By utilizing this strategy, traders can capitalize on significant market trends while dynamically managing risk. Test it on historical data to optimize the parameters for your preferred market!