Indicators and strategies
Highlight 3 PM Candle//@version=5
indicator("Highlight 3 PM Candle", overlay=true)
// Function to determine if the current candle is the 3 PM candle
is3pm(candleTime) =>
hour(candleTime) == 15 and minute(candleTime) == 0
// Check if the current candle is the 3 PM candle
highlight = is3pm(time)
// Highlight the 3 PM candle with a background color
bgcolor(highlight ? color.new(color.red, 80) : na)
Pivot Points StrategyTrade Entry Logic
Long Entry: The strategy enters a long position when the price crosses above the primary pivot level (P). This crossover indicates a potential uptrend or bullish momentum.
Short Entry: The strategy enters a short position when the price crosses below the primary pivot level (P). This crossunder suggests bearish momentum or a potential downtrend.
Trade Exit Logic
Long Exit: If a long position is active and the price reaches or exceeds R4, the strategy will exit the long position. R4 serves as an upper target, signaling that the bullish momentum might be losing steam.
Short Exit: If a short position is active and the price reaches or falls below S4, the strategy exits the short position. S4 is used as a target for short positions, indicating that downward momentum may be weakening.
Alerts
The strategy includes alerts for exits:
When a long position exits at R4, an alert is triggered with the message "Exit Long Trade at R4."
When a short position exits at S4, an alert is triggered with the message "Exit Short Trade at S4."
Strategy Rationale
This strategy is based on the concept that certain price levels act as psychological boundaries where price may reverse, pause, or breakout significantly. By using Camarilla pivots, the strategy aims to capture moves within strong support and resistance boundaries, providing guidance on entry and exit points.
Probabilistic Trend Oscillator** MACD PLOTS ARE NOT PART OF THE INDICATOR IT IS FOR COMPARSION**
The "Probabilistic Trend Oscillator" is a technical indicator designed to measure trend strength and direction by analyzing price behavior relative to a moving average over both long-term and short-term periods. This indicator incorporates several innovative features, including probabilistic trend detection, enhanced strength scaling, and percentile-based thresholds for identifying potential trend reversals.
Key Components
Inputs:
The indicator allows users to customize several key parameters:
EMA Length defines the period for the Exponential Moving Average (EMA), which serves as a baseline to classify trend direction.
Long and Short Term Lengths provide customizable periods for analyzing trend strength over different timeframes.
Signal Line Length is used to smooth the trend strength data, helping users spot more reliable trend signals.
Extreme Value Lookback Length controls how far back to look when calculating percentile thresholds, which are used to identify overbought and oversold zones.
Trend Classification:
The indicator categorizes price behavior into four conditions:
Green: Price closes above the open and is also above the EMA, suggesting a strong upward trend.
Red: Price closes below the open but is above the EMA, indicating weaker upward pressure.
Green1: Price closes above the open but remains below the EMA, representing weak upward movement.
Red1: Price closes below the open and the EMA, signaling a strong downward trend.
Trend Strength Calculation:
The script calculates long-term and short-term trend values based on the frequency of these trend conditions, normalizing them to create probabilistic scores.
It then measures the difference between the short-term and long-term trend values, creating a metric that reflects the intensity of the current trend. This comparison provides insight into whether the trend is strengthening or weakening.
Enhanced Trend Strength:
To emphasize significant movements, the trend strength metric is scaled by the average absolute price change (distance between close and open prices). This creates an "enhanced trend strength" value that highlights periods with high momentum.
Users can toggle between two variations of trend strength:
Absolute Trend Strength is a straightforward measure of the trend's force.
Relative Trend Strength accounts for deviations between short term and long term values, focusing on how current price action differs from a long term behavior.
Percentile-Based Thresholds:
The indicator calculates percentile thresholds over the specified lookback period to mark extreme values:
The 97th and 3rd percentiles act as overbought and oversold zones, respectively, indicating potential reversal points.
Intermediate levels (75th and 25th percentiles) are added to give additional context for overbought or oversold conditions, creating a probabilistic range.
Visualization:
The selected trend strength value (either absolute or relative) is plotted in orange.
Overbought (green) and oversold (red) percentiles are marked with dashed lines and filled in blue, highlighting potential reversal zones.
The signal line—a smoothed EMA of the trend strength—is plotted in white, helping users to confirm trend changes.
A gray horizontal line at zero acts as a baseline, further clarifying the strength of upward vs. downward trends.
Summary
This indicator provides a flexible, probabilistic approach to trend detection, allowing users to monitor trend strength with customizable thresholds and lookback periods. By combining percentile-based thresholds with enhanced trend strength scaling, it offers insights into market reversals and momentum shifts, making it a valuable tool for both trend-following and counter-trend trading strategies.
C:200-21-9/EMA with CrossoverThis trading strategy is designed to enter a long position based on a combination of technical indicators. The strategy checks for the following conditions:
Price Above 200 EMA: The price must be trading above the 200-period Exponential Moving Average (EMA), indicating an overall bullish trend.
9 EMA Crossing Under 21 EMA: The 9-period EMA crosses under the 21-period EMA, signaling a potential short-term pullback in an uptrend.
MACD Line Crossing Over the Signal Line: The MACD line crosses above the Signal line, indicating a potential shift to bullish momentum.
TEMA Cross & Bollinger Middle AlertThe "TEMA Cross & Bollinger Middle Alert" script for TradingView is designed to track and provide alerts based on the crossover events of two Triple Exponential Moving Averages (TEMA) and the middle band of Bollinger Bands. This script is created using TradingView’s Pine Script (version 5) and includes adjustable parameters for flexibility.
BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)BTC Price Difference (Coinbase vs Binance)
Expanded Keltner Channel with Forecast The entire code aims to display market dynamics on the chart based on two indicators: the Keltner Channel and volume. This allows traders to identify potential reversal points (when the price touches the Keltner bands) and areas where there is increased market activity (changes in volume). With this information, traders can make more informed decisions about opening or closing positions.
The code generates forecasts based on the touches of the bands, and the yellow line acts as an additional volume indicator, suggesting important market changes.
trailing stpTHAICHUYENTOAN I WANT TO BE A MILIONARE\
VISE Premium Trading là phần mềm giao dịch chứng khoán dành cho nhà đầu tư chuyên nghiệp với nhiều tính năng cao cấp. Phần mềm cung cấp dữ liệu phân tích kỹ thuật và tài chính doanh nghiệp song song với việc đặt lệnh, theo dõi tài khoản online. VISE Premium Trading tăng cường tính tương tác thông qua những thống kê giao dịch, biến động giá trực tuyến giúp khách hàng nhanh chóng ra quyết định tối ưu nhất.
Các tính năng cao cấp trên Premium trading
Phân tích kĩ thuật theo thời gian thực
Stormico Screener 40, EMA 80 (Slow Stochastic 8)This screener is a tribute to Alexandre Wolwacz, known as "Stormer," one of the most influential traders in the Brazilian financial market.
Stormer is renowned for his experience and skill in technical analysis, as well as his dedication to teaching trading strategies to traders at all levels. He is particularly known for his focus on strategies with a positive risk-reward ratio and low drawdown, something he conveys to his followers with clarity and practicality.
The screener presented here uses a setup frequently employed by Stormer to capture pullbacks in uptrends, focusing on strategic entries, short stops, and long targets. It utilizes an 8-period Slow Stochastic and an 80-period Exponential Moving Average (EMA) and is suitable for Day Trading, Swing Trading, and Position Trading on weekly charts.
Main Elements of the Setup:
80-Period Exponential Moving Average (EMA): The 80 EMA is used as a trend filter. When the price is above it, we consider an uptrend and look for buying opportunities. When the price is below it, buy trades are avoided, prioritizing trades that follow the upward trend.
Slow Stochastic Oscillator: The 8-period Slow Stochastic is used to capture entry points during pullbacks. In an uptrend, we look for moments when the oscillator reaches oversold levels (below 20), indicating a possible entry at an attractive price while remaining aligned with the main market direction.
Entry and Exit Criteria:
Buy: The entry occurs when the stochastic oscillator is in oversold levels and the price stays above an ascending 80 EMA with a bullish candle or inside bar, or when the stochastic turns upward.
Short Stop: The stop-loss is positioned below a recent support level, limiting risk and minimizing drawdown.
Long Target: Once in operation, the goal is to ride the trend with wider targets to maximize gains. The target suggested by Stormer can be set at twice the risk (2x Risk) or the previous high on the chart.
Positive Risk-Reward Ratio and Low Drawdown
With a short stop and a larger profit target, this setup is ideal for capturing entries with a favorable risk-reward ratio, minimizing drawdown and maximizing profit potential in trades that follow the trend.
This screener applies this setup across 40 assets, identifying the best opportunities according to the "Stormer" method. It displays the 8 and 80 EMAs and can be complemented by the Stormico Screener 40, Slow Stochastic (EMA 80).
The setup was also a favorite of his daughter Carol, who contributed greatly to live sessions and classes with Stormer. This screener honors both of them and Alexandre Wolwacz’s methodology, with deep respect for all he has contributed to the market and his students.
Minkiu Bollinger Band Strategy Convert all Indicator specific code to Strategy specific code. Don't use any code that a TradingView Strategy won't support. Especially timeframes and gaps. Define those in code so they are semantically the same as before.
Multiple Moving Average Vol 1.Popular strategy in technical analysis, where traders use moving averages (MAs) to identify trends and potential entry or exit points for trades. Moving averages help smooth out price data over a specified period, making it easier to see price trends by filtering out short-term fluctuations
High Frequency Trend Following - Single Trade ActiveHigh Frequency Trend Following - Single Trade Active Strategy
Overview
This TradingView strategy script is designed for high-frequency trading on shorter timeframes, leveraging exponential moving averages (EMAs) and the Relative Strength Index (RSI) to identify potential trade entries and exits. It ensures only one active trade at a time by closing the current position when an opposing signal is detected. This clean, visually appealing strategy is suited for day traders looking to follow short-term trends with minimal chart clutter.
How It Works
The strategy combines three main indicators:
EMA Cross: The script uses two EMAs (20-period and 50-period) to capture trend direction. A cross of the shorter EMA (20) above the longer EMA (50) indicates a bullish trend, while a cross below signals a bearish trend.
RSI Confirmation: RSI levels are used to confirm entries, filtering out trades in overbought or oversold conditions. For long entries, the RSI must be below 40, indicating a potential reversal from oversold conditions. For short entries, the RSI must be above 60, signaling a potential reversal from overbought conditions.
ATR-Based Exits: This script incorporates the Average True Range (ATR) to dynamically adjust stop loss and take profit levels based on market volatility, although exits in this version are based on opposite signals.
Best Use
This strategy is best suited for fast-moving markets and shorter timeframes, such as 5- or 15-minute charts, where it can capture frequent trend reversals. It can be applied to cryptocurrencies, forex, and other high-volatility assets.
Set Timeframe: This strategy performs best on intraday timeframes (e.g., 5-minute or 15-minute) where trend reversals are frequent.
Pair with High Volatility Assets: Ideal for assets like cryptocurrency pairs or forex where short-term trends and reversals are common.
Variables and Parameters
EMA Periods:
ema_short_length: The length of the short-term EMA (default is 20). This captures the faster-moving trend.
ema_long_length: The length of the long-term EMA (default is 50), representing the slower trend.
RSI Settings:
rsi_length: The period for the RSI (default is 14).
rsi_overbought: RSI level above which the market is considered overbought (default is 60).
rsi_oversold: RSI level below which the market is considered oversold (default is 40).
ATR Settings:
atr_length: Period for calculating ATR (default is 14).
atr_multiplier: Multiplier to adjust stop loss distance relative to ATR (default is 1.1).
take_profit_multiplier: Multiplier to adjust take profit distance relative to ATR (default is 1.5).
Interpretation
Entry Signals:
Long Entry: When the 20 EMA crosses above the 50 EMA (indicating an uptrend) and the RSI is below the rsi_oversold threshold (default 40), the script opens a long position.
Short Entry: When the 20 EMA crosses below the 50 EMA (indicating a downtrend) and the RSI is above the rsi_overbought threshold (default 60), the script opens a short position.
Exit Signals:
The strategy closes a long position when a short entry signal is generated, and vice versa. This ensures only one active trade at a time.
Visuals:
EMA Lines: The 20 EMA is green, and the 50 EMA is red. Crosses between these lines indicate potential trend shifts.
Background Colors: The background color changes faintly to green when a long position is active and to red when a short position is active, providing a clear visual representation of the current trade direction.
Entry and Exit Arrows: Small green arrows indicate long entries and exits from short positions, while red arrows mark short entries and exits from long positions.
Additional Notes
Customizability: Users can adjust the EMA and RSI parameters to suit their specific asset or timeframe. For example, decreasing the EMA lengths (e.g., 10 and 30) can make the strategy more sensitive to short-term trends.
Trading Environment: This strategy is ideal for high-volatility environments, where price reversals are common and where high-frequency trading can capture small but frequent gains.
Disclaimer
This strategy is intended for educational purposes and should be backtested and adjusted according to the specific asset and market conditions. Always use risk management and trade responsibly.
Enhanced 1-Hour Strategy for Maximized ReturnsEnhanced 1-Hour Strategy for Maximized Returns
Overview
This is a trend-following and volatility-based breakout strategy designed for trading on the one-hour timeframe. It combines moving average crossovers, RSI for momentum, and Bollinger Bands as a volatility filter to confirm entries and exits. With a focus on maximizing returns, this strategy is tuned to work with leveraged trading and dynamically allocates position sizes based on available equity.
How the Strategy Works
Trend Detection: The strategy uses two moving averages—a short-term and a long-term—to detect trends.
A crossover of the short moving average above the long moving average indicates a potential upward trend.
Conversely, a crossover of the short moving average below the long moving average suggests a downward trend.
Momentum Confirmation with RSI: To avoid entering trades in low-momentum conditions, the strategy employs the Relative Strength Index (RSI).
A long (buy) trade is considered only when RSI is above a set threshold, indicating upward momentum.
A short (sell) trade is considered only when RSI is below a set threshold, indicating downward momentum.
Volatility Filter with Bollinger Bands: Bollinger Bands act as a filter to ensure the strategy enters trades only during periods of higher volatility.
For a long trade, the price must be above the lower Bollinger Band.
For a short trade, the price must be below the upper Bollinger Band.
ATR-Based Stop-Loss and Take-Profit: The strategy uses the Average True Range (ATR) to set stop-loss and take-profit levels dynamically based on market volatility.
The stop-loss level is set at a certain multiplier of the ATR below (for long trades) or above (for short trades) the entry price.
The take-profit level is set at a larger ATR multiplier, allowing the strategy to capture larger movements.
Position Sizing with Leverage: The position size is calculated as a percentage of equity, leveraging it to maximize returns as the account balance grows.
Key Variables and Adjustable Parameters
Here are the adjustable inputs in the strategy, allowing traders to tailor it to their preferences:
Moving Averages:
Short MA Length (shortMaLength): Length of the short-term moving average (default: 14).
Long MA Length (longMaLength): Length of the long-term moving average (default: 50).
These lengths can be adjusted to make the moving average crossovers more or less sensitive.
RSI Settings:
RSI Length (rsiLength): Length of the RSI calculation (default: 14).
RSI Upper Threshold (rsiUpperThreshold): Minimum RSI value required for long trades (default: 60).
RSI Lower Threshold (rsiLowerThreshold): Maximum RSI value allowed for short trades (default: 40).
Adjusting these thresholds can help control the momentum conditions required for trades.
ATR Multipliers for Stop-Loss and Take-Profit:
ATR Stop-Loss Multiplier (atrMultiplierStopLoss): Multiplier for the ATR to set the stop-loss level (default: 1.5).
ATR Take-Profit Multiplier (atrMultiplierTakeProfit): Multiplier for the ATR to set the take-profit level (default: 3.0).
Tuning these multipliers can help in balancing risk and reward, depending on market volatility.
Bollinger Bands Settings:
Deviation (dev): The standard deviation multiplier for Bollinger Bands (default: 2).
Bollinger Bands provide a volatility filter, and this multiplier affects the width of the bands.
Position Sizing and Leverage:
Leverage (leverage): The leverage applied to the position (default: 10).
Allocation Percent (allocationPercent): The percentage of equity allocated to each trade (default: 0.1 or 10%).
Adjusting these settings can increase or decrease the position size relative to your equity, helping control risk exposure.
Three SMAs with AlertsThis Pine Script version 5 script creates three Simple Moving Averages (SMA) with values of 20, 50, and 200 periods, and plots them on the chart.
The SMAs are color-coded to make them easily distinguishable.
Additionally, the script generates alerts when the price crosses above or below the 20-period SMA.
Auto alerts are triggered to notify the user of these crossover events, and visual markers (plotshape) are added to the chart to indicate where the crossovers occur.
Smoothed Moving Average ModifiedA feature has been added to the standard version of the SMMA: the user can specify an integer value to move the SMMA. A positive value will move the average forward (to the right), while a negative value will move it backward (to the left) relative to current prices.
Jurik / HMA with Ribbon
**Jurik / HMA with Ribbon**
This script combines the Jurik Moving Average (JMA), Exponential Moving Average (EMA), and Hull Moving Average (HMA) to provide a comprehensive trend-following tool with a visual ribbon background. Each of these moving averages is tuned for a unique view of market trends, and the script highlights potential momentum changes based on the alignment of these averages.
### Key Components:
1. **Jurik Moving Average (JMA)**:
- JMA is a smooth, adaptive moving average that filters out noise while remaining responsive to price changes.
- The script allows customization of JMA's `length`, `phase`, and `power` parameters to suit different trading styles.
- When the JMA turns from red to green (or vice versa), it indicates a potential momentum shift based on the current price action relative to the previous bar.
2. **Exponential Moving Average (EMA)** and **Hull Moving Average (HMA)**:
- Both EMA and HMA are popular moving averages in technical analysis.
- EMA responds more quickly to recent price changes, while HMA is known for smoothing out price data while reducing lag.
- The `length` for both EMA and HMA can be customized, with a default value of 15.
3. **Ribbon Background**:
- This script creates a "ribbon" effect in the background, highlighting when the JMA is above or below both the EMA and HMA:
- **Green Ribbon**: Indicates a potential bullish trend when JMA is above both EMA and HMA.
- **Red Ribbon**: Indicates a potential bearish trend when JMA is below both EMA and HMA.
- The ribbon provides a clear visual cue, making it easy to identify trend changes at a glance.
### Inputs:
- **JMA Length, Phase, and Power**: Parameters to fine-tune the behavior of the Jurik Moving Average.
- **EMA/HMA Length**: Shared length parameter for both the EMA and HMA, with a default of 15.
- **Highlight Movements**: Option to enable/disable color changes for the JMA based on movement direction.
### Plotting:
- The script plots the JMA, EMA, and HMA lines on the chart, color-coded for easy identification.
- The JMA line changes color based on movement direction, with green for upward movements and red for downward.
- EMA and HMA lines are shown in blue and purple, respectively, for added clarity.
### How to Use:
This indicator can be useful for identifying trend direction and strength:
- When all three moving averages (JMA, EMA, and HMA) align with the same direction and the ribbon color matches, it signals a strong trend.
- This script is ideal for trend-following strategies, as well as for identifying potential reversals when the JMA crosses below or above the EMA/HMA.
### Note:
As always, this indicator should be used alongside other tools or analysis techniques to confirm signals and manage risk effectively.
---
This description should help users understand the functionality and purpose of the script when they see it on TradingView. Let me know if you'd like any further customization!