OPEN-SOURCE SCRIPT

16. SMC Strategy with SL - low Timeframe

Overview
The "SMC Strategy with SL - low Timeframe" is a comprehensive trading strategy that uses key concepts from Smart Money Theory to identify favorable areas in the market for buying or selling. This strategy takes advantage of price imbalances, support and resistance zones, and swing highs/lows to generate high-probability trade signals.

The key features of this strategy include:

Swing High/Low Analysis: Used to determine the Premium, Equilibrium, and Discount Zones.
Order Block Integration: An added layer of confluence to identify valid buy and sell signals.
Trend Direction Confirmation: Using a Simple Moving Average (SMA) to determine the overall trend.
Entry and Exit Rules: Based on price position relative to key zones and moving average, along with optional stop-loss and take-profit levels.
Detailed Description
Swing High and Swing Low Analysis

The script calculates Swing High and Swing Low based on the most recent price highs and lows over a specified look-back period (swingHighLength and swingLowLength, set to 8 by default).
It then derives the Premium, Equilibrium, and Discount Zones:
Premium Zone: Represents potential resistance, calculated based on recent swing highs.
Discount Zone: Represents potential support, calculated based on recent swing lows.
Equilibrium: The midpoint between Swing High and Swing Low, dividing the price range into Premium (above equilibrium) and Discount (below equilibrium) areas.
Zone Visualization

The strategy plots the Premium Zone (resistance) in red, the Discount Zone (support) in green, and the Equilibrium level in blue on the chart. This helps visually assess the current price relative to these important areas.
Simple Moving Average (SMA)

A 50-period Simple Moving Average (SMA) is added to help identify the trend direction.
Buy signals are valid only if the price is above the SMA, indicating an uptrend.
Sell signals are valid only if the price is below the SMA, indicating a downtrend.
Entry Rules

The script generates buy or sell signals when certain conditions are met:
A buy signal is triggered when:
Price is below the Equilibrium and within the Discount Zone.
Price is above the SMA.
The buy signal is further confirmed by the presence of an Order Block (recent lowest price area).
A sell signal is triggered when:
Price is above the Equilibrium and within the Premium Zone.
Price is below the SMA.
The sell signal is further confirmed by the presence of an Order Block (recent highest price area).
Order Block

The strategy defines Order Blocks as recent highs and lows within a look-back period (orderBlockLength set to 20 by default).
These blocks represent areas where large players (smart money) have historically been active, increasing the probability of the price reacting in these areas again.
Trade Management and Trade Direction

The user can set Trade Direction to either "Long Only," "Short Only," or "Both." This allows the strategy to adapt based on market conditions or trading preferences.
Based on the Trade Direction, the strategy either:
Closes open trades that are against new signals.
Allows only specific directional trades (either long or short).
Stop-loss levels are defined based on a fixed percentage (stop_loss_percent), which helps to manage risk and minimize losses.
Exit Rules

The strategy uses stop-loss levels for risk management.
A stop-loss price is set at a fixed percentage below the entry price for long positions or above the entry price for short positions.
When the price hits the defined stop-loss level, the trade is closed.
Liquidity Zones

The script identifies recent Swing Highs and Lows as potential liquidity zones. These are levels where price could react strongly, as they represent areas of interest for large traders.
The liquidity zones are plotted as crosses on the chart, marking areas where price may encounter significant buying or selling pressure.
Visual Feedback

The script uses visual markers (green for buy signals and red for sell signals) to indicate potential entries on the chart.
It also plots liquidity zones to help traders identify areas where stop hunts and liquidity grabs might occur.
Monthly Performance Dashboard

The script includes a performance tracking feature that displays monthly profit and loss metrics on the chart.
This dashboard allows the trader to see a visual representation of trading performance over time, providing insights into profitability and consistency.
The table shows profit or loss for each month and year, allowing the user to track the overall success of the strategy.
Key Benefits
Smart Money Concepts (SMC): This strategy incorporates SMC principles like order blocks and liquidity zones, which are used by institutional traders to determine potential market moves.
Zone Analysis: The use of Premium, Discount, and Equilibrium zones provides a solid framework for determining where to enter and exit trades based on price discounts or premiums.
Confluence: Signals are not taken in isolation. They are confirmed by factors like trend direction (SMA) and order blocks, providing greater trade accuracy.
Risk Management: By integrating stop-loss functionality, traders can manage their risks effectively.
Visual Performance Metrics: The monthly and yearly performance dashboard gives valuable feedback on how well the strategy has performed historically.
Practical Use
Buy in Discount Zone: Traders would be looking to buy when the price is discounted relative to its recent range and is above the SMA, indicating an overall uptrend.
Sell in Premium Zone: Conversely, traders would be looking to sell when the price is at a premium relative to its recent range and below the SMA, indicating an overall downtrend.
Order Block Confirmation: Ensures that buying or selling is supported by historical price behavior at significant levels, providing confidence that the market is likely to react at these areas.
This strategy is designed to help traders take advantage of price inefficiencies and areas where institutional traders are likely to be active, increasing the odds of successful trades. By leveraging Smart Money concepts and strong technical confluence, it aims to provide high-probability trade setups.
priceactionSMCSupport and Resistance

Скрипт с открытым кодом

В истинном духе TradingView автор этого скрипта опубликовал его с открытым исходным кодом, чтобы трейдеры могли понять, как он работает, и проверить на практике. Вы можете воспользоваться им бесплатно, но повторное использование этого кода в публикации регулируется Правилами поведения. Вы можете добавить этот скрипт в избранное и использовать его на графике.

Хотите использовать этот скрипт на графике?

Отказ от ответственности