MACD and RSI Strategy//@version=6
indicator("MACD and RSI Strategy", shorttitle="MACD_RSI", overlay=true)
// Các tham số của MACD
macdFastLength = input.int(12, title="MACD Fast Length")
macdSlowLength = input.int(26, title="MACD Slow Length")
macdSignalSmoothing = input.int(9, title="MACD Signal Length")
// Các tham số của RSI
rsiLength = input.int(14, title="RSI Length")
rsiOverbought = input.int(70, title="RSI Overbought Level")
rsiOversold = input.int(30, title="RSI Oversold Level")
// Tính toán MACD
= ta.macd(close, macdFastLength, macdSlowLength, macdSignalSmoothing)
macdHist = macdLine - signalLine
// Tính toán RSI
rsiValue = ta.rsi(close, rsiLength)
// Điều kiện mua
longCondition = ta.crossover(macdLine, signalLine) and rsiValue < rsiOversold
// Điều kiện bán
shortCondition = ta.crossunder(macdLine, signalLine) and rsiValue > rsiOverbought
// Tín hiệu mua/bán
plotshape(series=longCondition, title="Buy Signal", location=location.belowbar, color=color.green, style=shape.labelup, text="BUY")
plotshape(series=shortCondition, title="Sell Signal", location=location.abovebar, color=color.red, style=shape.labeldown, text="SELL")
// Vẽ các đường MACD và RSI
plot(macdLine, color=color.blue, title="MACD Line")
plot(signalLine, color=color.orange, title="Signal Line")
hline(0, "Zero Line", color=color.gray)
plot(rsiValue, color=color.purple, title="RSI", style=plot.style_line)
hline(rsiOverbought, "RSI Overbought", color=color.red, linestyle=hline.style_dotted)
hline(rsiOversold, "RSI Oversold", color=color.green, linestyle=hline.style_dotted)
Cycles
Giotee-Norm**Gioteen-Norm: A Versatile Normalization Indicator**
This indicator applies a normalization technique to closing prices, providing a standardized view of price action that can be helpful for identifying overbought and oversold conditions.
**Key Features:**
* **Normalization:** Transforms closing prices into a z-score by subtracting a moving average and dividing by the standard deviation. This creates a standardized scale where values above zero represent prices above the average, and values below zero represent prices below the average.
* **Customizable Moving Average:** Choose from four different moving average methods (SMA, EMA, WMA, VWMA) and adjust the period to suit your trading style.
* **Visual Clarity:** The indicator displays the normalized values as a red line, making it easy to identify potential turning points.
* **Optional Moving Average:** You can choose to display a moving average of the normalized values as a green dashed line, which can help to filter out noise and identify trends.
**Applications:**
* **Overbought/Oversold Identification:** Look for extreme values in the normalized data to identify potential overbought and oversold conditions.
* **Divergence Analysis:** Compare the price action with the normalized values to spot potential divergences, which can signal trend reversals.
* **Trading System Integration:** This indicator can be integrated into various trading systems as a building block for generating trading signals.
**This indicator was a popular tool on the MT4 platform, and now it's available on TradingView!**
**Contact:**
If you have any questions or feedback, feel free to reach out to me at admin@fxcorner.net .
YJ Trading Indicator - Advanced Patterns & Signals//@version=5
indicator("YJ Trading Indicator - Advanced Patterns & Signals", overlay=true)
// Moving Averages for trend confirmation
ema50 = ta.ema(close, 50)
ema200 = ta.ema(close, 200)
trendUp = ema50 > ema200
trendDown = ema50 < ema200
// Fibonacci Levels Calculation
pivotHigh = ta.highest(high, 50)
pivotLow = ta.lowest(low, 50)
fibLevels = array.new_float(6, 0.0)
array.set(fibLevels, 0, pivotHigh)
array.set(fibLevels, 1, pivotHigh - (pivotHigh - pivotLow) * 0.236)
array.set(fibLevels, 2, pivotHigh - (pivotHigh - pivotLow) * 0.382)
array.set(fibLevels, 3, pivotHigh - (pivotHigh - pivotLow) * 0.5)
array.set(fibLevels, 4, pivotHigh - (pivotHigh - pivotLow) * 0.618)
array.set(fibLevels, 5, pivotLow)
// Supertrend Indicator
= ta.supertrend(3, 14)
plot(supertrendLine, color=supertrendDirection == 1 ? color.green : color.red, title="Supertrend")
// RSI Divergence Detection
rsi = ta.rsi(close, 14)
bullishDivergence = rsi < 30 and ta.lowest(close, 5) == low
bearishDivergence = rsi > 70 and ta.highest(close, 5) == high
// MACD Crossover Detection
= ta.macd(close, 12, 26, 9)
macdBullishCross = ta.crossover(macdLine, signalLine)
macdBearishCross = ta.crossunder(macdLine, signalLine)
// Candlestick Pattern Detection
bullishEngulfing = close > open and close > high and open < close
bearishEngulfing = close < open and close < low and open > close
morningStar = close < open and (close - open ) < ta.atr(5) and close > open
eveningStar = close > open and (close - open ) < ta.atr(5) and close < open
doji = math.abs(close - open) < (high - low) * 0.1
spinningTop = (close - open) < (high - low) * 0.3 and (high - low) > ta.atr(5)
// Chart Patterns Detection
headAndShoulders = high > high and high > high and low < low and low < low
doubleTop = high == high and high < high
doubleBottom = low == low and low > low
ascendingTriangle = high > high and low > low
descendingTriangle = low < low and high < high
// Alerts & Plotting
plotshape(bullishEngulfing, location=location.belowbar, color=color.green, style=shape.labelup, title="Bullish Engulfing")
plotshape(bearishEngulfing, location=location.abovebar, color=color.red, style=shape.labeldown, title="Bearish Engulfing")
plotshape(morningStar, location=location.belowbar, color=color.blue, style=shape.triangleup, title="Morning Star")
plotshape(eveningStar, location=location.abovebar, color=color.orange, style=shape.triangledown, title="Evening Star")
plotshape(doubleTop, location=location.abovebar, color=color.red, style=shape.cross, title="Double Top")
plotshape(doubleBottom, location=location.belowbar, color=color.green, style=shape.cross, title="Double Bottom")
plotshape(ascendingTriangle, location=location.belowbar, color=color.blue, style=shape.flag, title="Ascending Triangle")
plotshape(descendingTriangle, location=location.abovebar, color=color.purple, style=shape.flag, title="Descending Triangle")
plotshape(macdBullishCross, location=location.belowbar, color=color.green, style=shape.arrowup, title="MACD Bullish Cross")
plotshape(macdBearishCross, location=location.abovebar, color=color.red, style=shape.arrowdown, title="MACD Bearish Cross")
alertcondition(bullishEngulfing, title="Bullish Engulfing Alert", message="Bullish Engulfing detected!")
alertcondition(bearishEngulfing, title="Bearish Engulfing Alert", message="Bearish Engulfing detected!")
alertcondition(macdBullishCross, title="MACD Bullish Crossover", message="MACD Bullish Cross detected!")
alertcondition(macdBearishCross, title="MACD Bearish Crossover", message="MACD Bearish Cross detected!")
RSI Buy & Sell Signalgenerates Buy and Sell signals using the Relative Strength Index (RSI) indicator on TradingView. The indicator allows users to customize the RSI period length, overbought level (default 70), and oversold level (default 30). A Buy signal is triggered when the RSI crosses above the oversold level, indicating a potential price reversal from a bearish trend, marked by a green triangle below the candlestick with the label BUY. Conversely, a Sell signal is generated when the RSI crosses below the overbought level, signaling a potential price reversal from a bullish trend, marked by a red triangle above the candlestick with the label SELL. The script also includes automatic alert notifications through the alertcondition() function, helping traders receive instant updates without constant chart monitoring.
ChoCh & BOS on XAU/USDsmc ICT MMXT
Explicação do código:
Definição de setores: Aqui, estamos dividindo o gráfico em três setores com base no preço de fechamento, low e high de velas passadas. Podemos modificar esses critérios dependendo do que exatamente o "setor" significa para sua estratégia.
Entradas: A estratégia entra no mercado quando o preço está dentro de cada um dos setores definidos. Usamos a função strategy.entry() para abrir a posição. Cada setor só tem uma entrada por vez.
Saídas (opcional): O código também tem algumas condições de fechamento para ilustrar como você pode encerrar uma posição, como quando o preço atinge certos níveis ou quando ele sai de um setor.
Gerenciamento de Risco:
Stop Loss e Take Profit: Você pode adicionar stop loss ou take profit no código, se necessário. Isso é importante para gerenciar riscos e garantir que a estratégia seja eficiente.
PSAR with AO and RSIThis script is a Parabolic SAR-based trading strategy enhanced with Awesome Oscillator (AO) confirmation and sideways market detection using RSI. It generates Buy and Sell signals based on the following conditions:
Hedge timesIndicates Market phases, where its a good idea to hedge stock portfolios against index futures.
Used on ES or NQ, red phases should indicate fully hedged phases which, should preserve capital.
Hedges should be closed on entering green phases the latest
Improved Trading Scriptits indicates the next candel. A highly accurate trend-following indicator for the 1-minute timeframe, designed for real-time execution in the Quotex OTC market.
Buy Signal: Appears below the candle → Next candle is bullish (green).
Sell Signal: Appears above the candle → Next candle is bearish (red).
This non-repainting indicator ensures precise signals for profitable trading.
TASHAEntry Trigger
Parabolic SAR (PSAR): This indicator helps identify potential trend reversals. A sell signal might occur when the PSAR is above the price, indicating a downtrend. When developing your strategy, look for PSAR dots to switch positions relative to the price chart.
Confluence Indicators:
MACD (Moving Average Convergence Divergence): Look for bearish crossovers (when the MACD line crosses below the signal line) to confirm your entry signal from PSAR.
Stochastic Oscillator: A reading above 80 can indicate overbought conditions. Confirmation here would include the %K line crossing below the %D line.
ZLEMA (Zero-Lag Exponential Moving Average): Use this to identify the trend's direction. A downward slope or the price being below the ZLEMA could confirm a bearish bias.
Accumulation Distribution Line (ADL): This technical indicator can confirm the trend's strength. If the ADL is declining while price moves upwards, it can confirm that the upward move may not be sustainable.
Exit Trigger
Parabolic SAR (PSAR): Use the PSAR flip (when it moves below the price) as an exit signal, indicating a potential trend reversal to the upside.
Confirmation Indicators:
RSI (Relative Strength Index): Look for overbought conditions, typically above 70, to confirm an exit signal.
Stochastic Oscillator: A reading above 80, combined with a crossover (where %K crosses below %D), can signal a good opportunity to exit a trade.
VWAP (Volume Weighted Average Price): If the price crosses below the VWAP, it may indicate a shift in sentiment from bullish to bearish.
PPS (Pivots Points Standard): Look for price action around pivot levels. If the price is failing to hold above a key pivot level, it could be a reason to exit.
Turtle Trading Mejorado para BTC 1Hturtle trading adapated to 1h
Canales Donchian:
Entrada: Periodo de 20 para detectar rupturas (largas y cortas).
Salida: Periodo de 10 para cerrar posiciones.
ATR (Average True Range):
Periodo de 14 para medir volatilidad y calcular el tamaño de las posiciones.
Gestión de Riesgo:
Riesgo por operación: 2% del capital.
Máximo de 4 unidades por posición.
Condiciones de Entrada:
Larga: Precio alto supera el máximo de 20 periodos.
Corta: Precio bajo cae por debajo del mínimo de 20 periodos.
Condiciones de Salida:
Larga: Precio bajo cae por debajo del mínimo de 10 periodos.
Corta: Precio alto supera el máximo de 10 periodos.
Añadir Unidades:
Se añaden unidades si el precio se mueve 0.5 ATR a favor, hasta 4 unidades.
Stop Loss:
Dinámico, basado en 2 ATR desde el precio de entrada.
PA Dynamic Cycle ExplorerPA Dynamic Cycle Explorer
Very powerful tool to abserve when price cycle start or end its show us if price remains to much
time on same place so its may trend change if it was bullish move and price start consolidate
so it means may accour price losing demands and getting weaker in this way bearsh side too
try to understand do your own analysis and practice demo thnx !
Weekend Filter Candlestick [odnac]Custom Candlestick Chart with Weekend Visibility Toggle
This indicator customizes the appearance of candlesticks by using a dark gray theme for better visibility.
Additionally, it provides an option to hide weekend candles, allowing traders to focus on weekday price action.
Features:
✅ Dark gray candlestick design for a clean and minimalistic look.
✅ Weekend hiding option – Users can enable or disable weekend candles with a simple toggle.
✅ Helps traders avoid weekend noise and focus on key market movements.
How to Use:
Add the indicator to your chart.
Use the "Hide Weekend Candles" setting to toggle weekend visibility.
When enabled, weekend candles will be hidden for a cleaner chart.
When disabled, all candles, including weekends, will be displayed.
This indicator is useful for traders who prefer to analyze weekday trends without unnecessary weekend fluctuations. 🚀
ATR with Dual EMAI want to determine whether the market is currently in a sideway (range-bound) or trending condition. To achieve this, I use the ATR (Average True Range) as an indicator. However, ATR alone does not clearly define the market condition.
To improve accuracy, I calculate two EMAs (Exponential Moving Averages) of ATR as a reference:
A fast EMA (shorter period)
A slow EMA (longer period)
If the fast EMA is above the slow EMA → The market is in a trend.
If the fast EMA is below the slow EMA → The market is in a sideway (range-bound) phase.
This is my definition of market conditions.
EMA of ATRI want to identify whether the market is currently in a sideway or trending condition. To achieve this, I use the ATR (Average True Range) as an indicator. However, ATR alone does not clearly define the market condition.
To improve accuracy, I calculate an EMA (Exponential Moving Average) of ATR as a reference.
If ATR is above the EMA → The market is in a trend.
If ATR is below the EMA → The market is in a sideway phase.
This is my definition of market conditions.
ATR 3x Multiplier StrategyVolatility and Candle Spikes in Trading
Volatility
Volatility refers to the degree of variation in the price of a financial asset over time. It measures how much the price fluctuates and is often associated with risk and uncertainty in the market. High volatility means larger price swings, while low volatility indicates more stable price movements.
Key aspects of volatility:
Measured using indicators like Average True Range (ATR), Bollinger Bands, and Implied Volatility (IV).
Influenced by factors such as market news, economic events, and liquidity.
Higher volatility increases both risk and potential profit opportunities.
Candle Spikes
A candle spike (or wick) refers to a sudden price movement that forms a long shadow or wick on a candlestick chart. These spikes can indicate strong buying or selling pressure, liquidity hunts, or stop-loss triggers.
Types of candle spikes:
Bullish Spike (Long Lower Wick): Indicates buyers rejected lower prices, pushing the price higher.
Bearish Spike (Long Upper Wick): Suggests sellers rejected higher prices, pushing the price lower.
Stop-Loss Hunt: Market makers may trigger stop-losses by creating artificial spikes before reversing the price.
News-Induced Spikes: Economic data releases or unexpected events can cause sudden price jumps.
Understanding volatility and candle spikes can help traders manage risk, spot entry/exit points, and avoid false breakouts. 🚀📈
SMA & EMA CombinationHere's a TradingView Pine Script that combines both a Simple Moving Average (SMA) and an Exponential Moving Average (EMA) into a single indicator. This script allows you to customize the lengths of both moving averages and displays them on the chart.
Advanced Session Profile Predictor with ArrowsIndicator Description: Advanced Session Profile Predictor with Arrows
Overview
The Advanced Session Profile Predictor with Arrows is a powerful indicator designed to analyze price action across three major trading sessions—Asia, London, and New York—and provide actionable trading insights. Built on session-based profiling and enhanced with Traders Dynamic Index (TDI) and momentum-driven arrows, this indicator helps traders identify potential market profiles and key entry points for long and short positions. It combines visual session highlighting, dynamic profile labels, and momentum signals to offer a comprehensive trading tool.
Key Features
Session Visualization:
Highlights the Asia (00:00-08:00 UTC, yellow), London (08:00-16:00 UTC, red), and New York (13:00-21:00 UTC, blue) sessions with customizable time zones (UTC, Europe/London, America/New_York).
Tracks high, low, open, and close prices for each session, resetting daily.
Profile Prediction:
Analyzes price behavior in the Asia and London sessions to predict one of four market profiles during the London session:
Profile 1: Trend Continuation: Strong trend from Asia continues into London. Long if price breaks asien_high (uptrend) or short if it breaks asien_low (downtrend).
Profile 2: NY Manipulation: Asia trends, London consolidates. Long at asien_high or london_high (uptrend), short at london_low (downtrend), with New York breakout potential.
Profile 3: London+NY Manipulation: London manipulates asien_high, potential reversal in NY. Short at asien_close, long at asien_high.
Profile 4: Consolidation+Continuation: London manipulates asien_low, continuation in NY. Short at asien_low, long at asien_close.
Displays the current profile and entry conditions in three compact labels (Profile, Short, Long) near the latest price.
Dynamic Entry Conditions:
Labels show "IF price hits LONG/SHORT" for levels yet to be reached, updating based on the current price (close).
Indicates "Ingen Long/Short (over/under )" if the price has already passed the target, ensuring relevance across sessions.
Momentum Arrows (TDI Integration):
Incorporates Traders Dynamic Index (TDI) with customizable RSI period (default 21), band length (34), fast MA (2), and slow MA (7).
Adds momentum (12-period) to generate:
Green Up Arrows: When TDI fast MA exceeds the upper band (>68) with rising momentum, signaling bullish strength (above bar).
Red Down Arrows: When TDI fast MA falls below the lower band (<32) with falling momentum, signaling bearish strength (below bar).
Arrows complement session profiles, providing additional confirmation for entries.
High/Low Lines:
Plots session highs and lows (yellow for Asia, red for London, blue for New York) as crosses for easy reference.
How to Use
Setup: Add the indicator to your chart and adjust the time zone and session times if needed (default: UTC). Customize TDI and momentum settings under "Traders Dynamic Index Settings" for your preferred sensitivity.
Trading:
Watch the labels in the top-right corner for the current profile and entry conditions (e.g., "IF price hits 1.2000 LONG (A/L/NY)").
Use green up arrows as bullish confirmation and red down arrows as bearish confirmation alongside profile signals.
Monitor session high/low lines to track key levels visually.
Profiles: Interpret the profile to anticipate market behavior:
Trend Continuation: Ride momentum with breaks of asien_high/asien_low.
NY Manipulation: Prepare for New York breakouts after London consolidation.
London+NY Manipulation: Look for reversals after false breaks.
Consolidation+Continuation: Trade continuation after consolidation ends.
Best Timeframes: Works on intraday timeframes (e.g., 15M, 1H) for session-based trading.
Settings
Time Zone: Choose your preferred session time zone (default: UTC).
Trend Threshold: Adjust sensitivity for trend detection (default: 1.5).
TDI Settings: Fine-tune RSI, bands, and MAs for arrow signals.
Momentum Length: Set momentum period (default: 12).
PriorHourRangeLevels_v0.1PriorHourRangeLevels_v0.1
Created by dc_77 | © 2025 | Mozilla Public License 2.0
Overview
"PriorHourRangeLevels_v0.1" is a versatile Pine Script™ indicator designed to help traders visualize and analyze price levels based on the prior hour’s range. It overlays key levels—High, Low, 75%, 50% (EQ), and 25%—from the previous hour onto the current price chart, alongside the current hour’s opening price. With customizable display options and time zone support, it’s ideal for intraday traders looking to identify support, resistance, and breakout zones.
How It Works
Hourly Reset: The indicator detects the start of each hour based on your chosen time zone (e.g., "America/New_York" by default).
Prior Hour Range: It calculates the High and Low of the previous hour, then derives three additional levels:
75%: 75% of the range above the Low.
EQ (50%): The midpoint of the range.
25%: 25% of the range above the Low.
Current Hour Open: Displays the opening price of the current hour.
Projection: Lines extend forward (default: 24 bars) to project these levels into the future, aiding in real-time analysis.
Alerts: Triggers alerts when the price crosses any of the prior hour’s levels (High, 75%, EQ, 25%, Low).
Key Features
Time Zone Flexibility: Choose from options like UTC, New York, Tokyo, or London to align with your trading session.
Visual Customization:
Toggle visibility for each level (High, Low, 75%, EQ, 25%, Open, and Anchor).
Adjust line styles (Solid, Dashed, Dotted), colors, and widths.
Show or hide labels with adjustable sizes (Tiny, Small, Normal, Large).
Anchor Line: A vertical line marks the start of the prior hour, with optional labeling.
Alert Conditions: Set up notifications for price crossings to catch key moments without watching the chart.
Usage Tips
Use the High and Low as potential breakout levels, while 75%, EQ, and 25% act as intermediate support/resistance zones.
Trend Confirmation: Watch how price interacts with the EQ (50%) level to gauge momentum.
Session Planning: Adjust the time zone to match your market (e.g., "Europe/London" for FTSE trading).
Projection Offset: Extend or shorten the lines (via "Projection Offset") based on your chart timeframe.
Inputs
Time Zone: Select your preferred market time zone.
Anchor Settings: Show/hide the prior hour start line, style, color, width, and label.
Level Settings: Customize visibility, style, color, width, and labels for Open, High, 75%, EQ, 25%, and Low.
Display: Set projection length and label size.
Feedback welcome—happy trading!
Global Liquidity Index (Candles)Global Liquidity Index (GLI) with Price Correlation
THIS INDICATOR ONLY WORKS ON THE 1D CHART, IF YOUR CHART USES ANOTHER TIMEFRAME THEN CHANGE IT TO THE 1 DAY ONE. It tracks global liquidity conditions by aggregating balance sheet data from major central banks worldwide, displayed as candlesticks for easy visualization.
Key Features:
Comprehensive data from 17 central banks including FED, ECB, PBoC, BoJ, and more
Customizable inputs to include/exclude specific central bank data
Special adjustments for FED RRP facility and Treasury General Account
70-day correlation delay which prove how liquidity leads price movements are factored in the indicator.
Price-liquidity correlation metric to quantify the relationship
A 70-day price projection based on current liquidity conditions is showed.
How To Use:
The indicator utilizes global liquidity with a 70-day delayed overlay gathering the historical relationship between liquidity and price.
The projection line provides an estimate of future price movements based on current liquidity conditions, making this tool valuable for medium to long-term investment planning.
This indicator builds upon the original work by "ingeforberg" with enhancements for correlation analysis and price projection capabilities. Data is sourced directly from central bank balance sheets and normalized to USD
Note:
If you like this indicator feel free to be part of x.com the first Bitcoin Wallet able to solve the problems of device hacks and physical attacks, thanks to a cutting-edge time delays over multisig technologic. Own a piece of www.bitvault.sv today:
wefunder.com
Disclaimer: help.wefunder.com
This script is provided for informational and educational purposes only. It is not intended to be, nor should it be construed as, financial, investment, or trading advice. Past performance is not indicative of future results, and the predictions or projections made by this script are purely algorithmic interpretations with no guarantee of accuracy.
Trading and investing involve risk, and you should conduct your own due diligence before making any financial decisions. You are solely responsible for your trading decisions, and neither the author nor TradingView will be liable for any losses incurred.
Always consult with a licensed financial professional before making investment decisions
Long Trend Linelong trend lines How to Use:
Open TradingView and go to the chart you want to add the trendline to.
In the top menu, click on Pine Editor.
Copy and paste the script into the editor.
Click Add to Chart.
This will display a long trend line between your specified points.
Feel free to modify this script for your needs, and let me know if you'd like more advanced features!