War IndexIntroduction
Welcome to the War Index! This project aims to provide traders, investors, and analysts with a specialized financial indicator that tracks the performance of key defense and aerospace companies. By aggregating the percentage changes of selected stocks, the War Index offers insights into the defense sector's dynamics and its relationship with the broader market.
What is the War Index?
The War Index is a custom financial indicator designed to approximate the collective performance of major defense and aerospace companies. It aggregates the daily percentage changes of selected stocks within the defense sector to provide a singular metric that reflects the overall health and trends of this industry. Additionally, the index is compared against the S&P 500 (SPX) to contextualize its performance relative to the broader market.
Index Components
The War Index comprises the following 16 stocks, each representing a significant player in the defense and aerospace industries:
Lockheed Martin Corporation ( NYSE:LMT )
Northrop Grumman Corporation ( NYSE:NOC )
Boeing Company ( NYSE:BA )
Raytheon Technologies Corporation ( NYSE:RTX )
General Dynamics Corporation ( NYSE:GD )
BAE Systems plc ( OTC:BAESY )
L3Harris Technologies, Inc. ( NYSE:LHX )
Textron Inc. ( NYSE:TXT )
Huntington Ingalls Industries, Inc. ( NYSE:HII )
Oshkosh Corporation ( NYSE:OSK )
Leidos Holdings, Inc. ( NYSE:LDOS )
Kratos Defense & Security Solutions, Inc. ( NASDAQ:KTOS )
Spirit AeroSystems Holdings, Inc. ( NYSE:SPR )
Parsons Corporation ( NYSE:PSN )
CACI International Inc ( NYSE:CACI )
ViaSat, Inc. ( NASDAQ:VSAT )
Purpose of the War Index
The War Index serves several key purposes:
Sector Performance Tracking : By aggregating the performance of major defense and aerospace companies, the index provides a clear picture of the sector's overall health.
Investment Analysis : Investors can use the index to identify trends, evaluate sector strength, and make informed decisions regarding their portfolios.
Comparative Benchmarking : Comparing the War Index with broader market indices like the S&P 500 helps in understanding how the defense sector performs relative to the general market.
Disclaimer: This War Index is an approximated indicator intended for informational purposes only. It should not be construed as investment advice. Always conduct your own research or consult with a financial advisor before making investment decisions.
Индикаторы и стратегии
Multifactor Buy/Sell Strategy V2 | RSI, MACD, ATR, EMA, Boll.BITGET:1INCHUSDT
This Pine Script code for TradingView is a multifactor Buy/Sell indicator that combines several technical factors to generate trading signals based on trend, volatility, and volume conditions. Here’s a breakdown of the main components and functionality:
Indicator Name
- Multifactor Buy/Sell Strategy V2 — an overlay indicator applied directly on the price chart.
### Input Parameters
The script includes multiple customizable parameters:
- RSI, EMA, MACD parameters — for setting periods and signals of MACD and RSI.
- ATR and Bollinger Bands — used for volatility analysis and level determination.
- Minimum Volatility Threshold — sets a minimum Bollinger Band width threshold for determining high volatility.
Core Indicators
1. RSI — calculated to identify oversold (below 30) and overbought (above 70) conditions.
2. EMA and MACD — calculates exponential moving averages and MACD histogram to determine trend direction.
3. ATR and Bollinger Bands — used to assess current volatility and establish dynamic upper and lower bands.
Volatility and Volume Analysis
- Determines the current ATR level and Bollinger Band width to evaluate high volatility.
- Calculates the volume moving average to track periods of increased volume during high volatility.
Trend Analysis
The script uses the difference between fast and slow EMAs to define strong trends:
- Uptrend — when the fast EMA is above the slow EMA, the price is above the fast EMA, and the trend is strong.
- Downtrend — when the fast EMA is below the slow EMA, the price is below the fast EMA, and the trend is strong.
Momentum Filter
- Based on the price change over the last three bars and compared against the minimum volatility threshold to identify strong momentum.
Buy and Sell Signal Generation
- Buy Signal: Uptrend with RSI oversold, positive MACD histogram, high volatility and volume, strong momentum, and sufficient Bollinger Band width.
- Sell Signal: Downtrend with RSI overbought, negative MACD histogram, high volatility and volume, strong momentum, and sufficient Bollinger Band width.
Visualization
- Buy and sell signals are displayed as green and red triangles on the chart.
- Plots for fast and slow EMAs, upper and lower bands, and Bollinger Bands.
Alerts
The script includes alert conditions for buy and sell signals, allowing notifications to be sent via email or mobile app.
Information Panel
A small table on the chart displays current volatility dataThis Pine Script code for TradingView is a multifactor Buy/Sell indicator that combines several technical factors to generate trading signals based on trend, volatility, and volume conditions. Here’s a breakdown of the main components and functionality:
Indicator Name
- Multifactor Buy/Sell Strategy V2 — an overlay indicator applied directly on the price chart.
Input Parameters
The script includes multiple customizable parameters:
- **RSI, EMA, MACD parameters** — for setting periods and signals of MACD and RSI.
- **ATR and Bollinger Bands** — used for volatility analysis and level determination.
- **Minimum Volatility Threshold** — sets a minimum Bollinger Band width threshold for determining high volatility.
Core Indicators
1. RSI — calculated to identify oversold (below 30) and overbought (above 70) conditions.
2. EMA and MACD — calculates exponential moving averages and MACD histogram to determine trend direction.
3. ATR and Bollinger Bands — used to assess current volatility and establish dynamic upper and lower bands.
Volatility and Volume Analysis
- Determines the current ATR level and Bollinger Band width to evaluate high volatility.
- Calculates the volume moving average to track periods of increased volume during high volatility.
Trend Analysis
The script uses the difference between fast and slow EMAs to define strong trends:
- Uptrend — when the fast EMA is above the slow EMA, the price is above the fast EMA, and the trend is strong.
- Downtrend — when the fast EMA is below the slow EMA, the price is below the fast EMA, and the trend is strong.
Momentum Filter
- Based on the price change over the last three bars and compared against the minimum volatility threshold to identify strong momentum.
Buy and Sell Signal Generation
- Buy Signal: Uptrend with RSI oversold, positive MACD histogram, high volatility and volume, strong momentum, and sufficient Bollinger Band width.
- Sell Signal: Downtrend with RSI overbought, negative MACD histogram, high volatility and volume, strong momentum, and sufficient Bollinger Band width.
Visualization
- Buy and sell signals are displayed as green and red triangles on the chart.
- Plots for fast and slow EMAs, upper and lower bands, and Bollinger Bands.
Alerts
The script includes alert conditions for buy and sell signals, allowing notifications to be sent via email or mobile app.
Information Panel
A small table on the chart displays current volatility
- Volatility Status — indicates high or low volatility.
- Bollinger Band Width — current width as a percentage.
- ATR Ratio — ratio of current ATR to long-term average ATR.
This script is suitable for trading in high-volatility conditions, combining multiple filters and factors to generate precise buy and sell signals.
Percentile Momentum IndicatorInput Parameters:
lengthPercentile: Defines the period used to calculate the percentile values (default: 30).
lengthMomentum: Defines the period for calculating the Rate of Change (ROC) momentum (default: 10).
Core Logic:
Rate of Change (ROC): The script calculates the ROC of the closing price over the specified period (lengthMomentum).
Percentile Calculations: The script calculates two key percentiles:
percentile_upper (80th percentile of the high prices)
percentile_lower (20th percentile of the low prices)
Percentile Average: An average of the upper and lower percentiles is calculated (avg_percentile).
Trade Signals:
Buy Signal: Triggered when the ROC is positive, the close is above the percentile_lower, and the close is above the avg_percentile.
Sell Signal: Triggered when the ROC is negative, the close is below the percentile_upper, and the close is below the avg_percentile.
Trade State Management:
The script uses a binary state: 1 for long (buy) and -1 for short (sell).
The trade state is updated based on buy or sell signals.
Bar Coloring:
Bars are colored dynamically based on the trade state:
Green for long (buy signal).
Red for short (sell signal).
The same color is applied to the percentile and average percentile lines for visual consistency.
BarRange StrategyHello,
This is a long-only, volatility-based strategy that analyzes the range of the previous bar (high - low).
If the most recent bar’s range exceeds a threshold based on the last X bars, a trade is initiated.
You can customize the lookback period, threshold value, and exit type.
For exits, you can choose to exit after X bars or when the close price exceeds the previous bar’s high.
The strategy is designed for instruments with a long-term upward-sloping curves, such as ES1! or NQ1!. It may not perform well on other instruments.
Commissions are set to $2.50 per side ($5.00 per round trip).
Recommended timeframes are 1h and higher. With adjustments to the lookback period and threshold, it could potentially achieve similar results on lower timeframes as well.
Exposure Oscillator (Cumulative 0 to ±100%)
Exposure Oscillator (Cumulative 0 to ±100%)
This Pine Script indicator plots an "Exposure Oscillator" on the chart, which tracks the cumulative market exposure from a range of technical buy and sell signals. The exposure is measured on a scale from -100% (maximum short exposure) to +100% (maximum long exposure), helping traders assess the strength of their position in the market. It provides an intuitive visual cue to aid decision-making for trend-following strategies.
Buy Signals (Increase Exposure Score by +10%)
Buy Signal 1 (Cross Above 21 EMA):
This signal is triggered when the price crosses above the 21-period Exponential Moving Average (EMA), where the current bar closes above the EMA21, and the previous bar closed below the EMA21. This indicates a potential upward price movement as the market shifts into a bullish trend.
buySignal1 = ta.crossover(close, ema21)
Buy Signal 2 (Trending Above 21 EMA):
This signal is triggered when the price closes above the 21-period EMA for each of the last 5 bars, indicating a sustained bullish trend. It confirms that the price is consistently above the EMA21 for a significant period.
buySignal2 = ta.barssince(close <= ema21) > 5
Buy Signal 3 (Living Above 21 EMA):
This signal is triggered when the price has closed above the 21-period EMA for each of the last 15 bars, demonstrating a strong, prolonged uptrend.
buySignal3 = ta.barssince(close <= ema21) > 15
Buy Signal 4 (Cross Above 50 SMA):
This signal is triggered when the price crosses above the 50-period Simple Moving Average (SMA), where the current bar closes above the 50 SMA, and the previous bar closed below it. It indicates a shift toward bullish momentum.
buySignal4 = ta.crossover(close, sma50)
Buy Signal 5 (Cross Above 200 SMA):
This signal is triggered when the price crosses above the 200-period Simple Moving Average (SMA), where the current bar closes above the 200 SMA, and the previous bar closed below it. This suggests a long-term bullish trend.
buySignal5 = ta.crossover(close, sma200)
Buy Signal 6 (Low Above 50 SMA):
This signal is true when the lowest price of the current bar is above the 50-period SMA, indicating strong bullish pressure as the price maintains itself above the moving average.
buySignal6 = low > sma50
Buy Signal 7 (Accumulation Day):
An accumulation day occurs when the closing price is in the upper half of the daily range (greater than 50%) and the volume is larger than the previous bar's volume, suggesting buying pressure and accumulation.
buySignal7 = (close - low) / (high - low) > 0.5 and volume > volume
Buy Signal 8 (Higher High):
This signal occurs when the current bar’s high exceeds the highest high of the previous 14 bars, indicating a breakout or strong upward momentum.
buySignal8 = high > ta.highest(high, 14)
Buy Signal 9 (Key Reversal Bar):
This signal is generated when the stock opens below the low of the previous bar but rallies to close above the previous bar’s high, signaling a potential reversal from bearish to bullish.
buySignal9 = open < low and close > high
Buy Signal 10 (Distribution Day Fall Off):
This signal is triggered when a distribution day (a day with high volume and a close near the low of the range) "falls off" the rolling 25-bar period, indicating the end of a bearish trend or selling pressure.
buySignal10 = ta.barssince(close < sma50 and close < sma50) > 25
Sell Signals (Decrease Exposure Score by -10%)
Sell Signal 1 (Cross Below 21 EMA):
This signal is triggered when the price crosses below the 21-period Exponential Moving Average (EMA), where the current bar closes below the EMA21, and the previous bar closed above it. It suggests that the market may be shifting from a bullish trend to a bearish trend.
sellSignal1 = ta.crossunder(close, ema21)
Sell Signal 2 (Trending Below 21 EMA):
This signal is triggered when the price closes below the 21-period EMA for each of the last 5 bars, indicating a sustained bearish trend.
sellSignal2 = ta.barssince(close >= ema21) > 5
Sell Signal 3 (Living Below 21 EMA):
This signal is triggered when the price has closed below the 21-period EMA for each of the last 15 bars, suggesting a strong downtrend.
sellSignal3 = ta.barssince(close >= ema21) > 15
Sell Signal 4 (Cross Below 50 SMA):
This signal is triggered when the price crosses below the 50-period Simple Moving Average (SMA), where the current bar closes below the 50 SMA, and the previous bar closed above it. It indicates the start of a bearish trend.
sellSignal4 = ta.crossunder(close, sma50)
Sell Signal 5 (Cross Below 200 SMA):
This signal is triggered when the price crosses below the 200-period Simple Moving Average (SMA), where the current bar closes below the 200 SMA, and the previous bar closed above it. It indicates a long-term bearish trend.
sellSignal5 = ta.crossunder(close, sma200)
Sell Signal 6 (High Below 50 SMA):
This signal is true when the highest price of the current bar is below the 50-period SMA, indicating weak bullishness or a potential bearish reversal.
sellSignal6 = high < sma50
Sell Signal 7 (Distribution Day):
A distribution day is identified when the closing range of a bar is less than 50% and the volume is larger than the previous bar's volume, suggesting that selling pressure is increasing.
sellSignal7 = (close - low) / (high - low) < 0.5 and volume > volume
Sell Signal 8 (Lower Low):
This signal occurs when the current bar's low is less than the lowest low of the previous 14 bars, indicating a breakdown or strong downward momentum.
sellSignal8 = low < ta.lowest(low, 14)
Sell Signal 9 (Downside Reversal Bar):
A downside reversal bar occurs when the stock opens above the previous bar's high but falls to close below the previous bar’s low, signaling a reversal from bullish to bearish.
sellSignal9 = open > high and close < low
Sell Signal 10 (Distribution Cluster):
This signal is triggered when a distribution day occurs three times in the rolling 7-bar period, indicating significant selling pressure.
sellSignal10 = ta.valuewhen((close < low) and volume > volume , 1, 7) >= 3
Theme Mode:
Users can select the theme mode (Auto, Dark, or Light) to match the chart's background or to manually choose a light or dark theme for the oscillator's appearance.
Exposure Score Calculation: The script calculates a cumulative exposure score based on a series of buy and sell signals.
Buy signals increase the exposure score, while sell signals decrease it. Each signal impacts the score by ±10%.
Signal Conditions: The buy and sell signals are derived from multiple conditions, including crossovers with moving averages (EMA21, SMA50, SMA200), trend behavior, and price/volume analysis.
Oscillator Visualization: The exposure score is visualized as a line on the chart, changing color based on whether the exposure is positive (long position) or negative (short position). It is limited to the range of -100% to +100%.
Position Type: The indicator also indicates the position type based on the exposure score, labeling it as "Long," "Short," or "Neutral."
Horizontal Lines: Reference lines at 0%, 100%, and -100% visually mark neutral, increasing long, and increasing short exposure levels.
Exposure Table: A table displays the current exposure level (in percentage) and position type ("Long," "Short," or "Neutral"), updated dynamically based on the oscillator’s value.
Inputs:
Theme Mode: Choose "Auto" to use the default chart theme, or manually select "Dark" or "Light."
Usage:
This oscillator is designed to help traders track market sentiment, gauge exposure levels, and manage risk. It can be used for long-term trend-following strategies or short-term trades based on moving average crossovers and volume analysis.
The oscillator operates in conjunction with the chart’s price action and provides a visual representation of the market’s current trend strength and exposure.
Important Considerations:
Risk Management: While the exposure score provides valuable insight, it should be combined with other risk management tools and analysis for optimal trading decisions.
Signal Sensitivity: The accuracy and effectiveness of the signals depend on market conditions and may require adjustments based on the user’s trading strategy or timeframe.
Disclaimer:
This script is for educational purposes only. Trading involves significant risk, and users should carefully evaluate all market conditions and apply appropriate risk management strategies before using this tool in live trading environments.
Old Price OscillatorThe Old Price Oscillator (OPO) is a momentum indicator widely used by traders and analysts to gauge the direction and strength of price trends. It works by calculating the difference between two moving averages—a shorter-term moving average and a longer-term moving average—of a security’s price. This difference is plotted as an oscillating line, helping traders visualize the momentum and determine when price reversals or continuations might occur. Typically, when the oscillator value is positive, the price is trending upwards, suggesting potential buy signals; conversely, when the oscillator turns negative, it indicates downward momentum, which could signal a potential sell.
The OPO is similar to other oscillators, like the Moving Average Convergence Divergence (MACD), in that it uses moving averages to smooth out price fluctuations and clarify trends. Traders often customize the length of the short- and long-term moving averages to better suit specific assets or market conditions. Generally, this indicator is especially useful in markets that exhibit clear trends. However, it may generate false signals during sideways or highly volatile periods, so many traders combine the OPO with other technical indicators or filters to improve accuracy.
Z Value AlertZ Value Alert analyzes daily price movements by evaluating fluctuations relative to historical volatility. It calculates the daily percentage change in the closing price, the average of this change over 252 days, and the standard deviation. Using these values, a Z-Score is calculated, indicating how much the current price change deviates from the historical range of fluctuations.
The user can set a threshold in standard deviations (Z-Score). When the absolute Z-Score exceeds this threshold, a significant movement is detected, indicating increased volatility. The Z-Score is visualized as a histogram, and an alert can be triggered when a significant movement occurs.
The number of trading days used to calculate historical volatility is adjustable, allowing the Sigma Move Alert to be tailored to various trading strategies and analysis periods.
Additionally, a dropdown option for the calculation method is available in the input menu, allowing the user to select between:
Normal: Calculates the percentage change in closing prices without using the logarithm.
Logarithmic: Uses the natural logarithm of daily returns. This method is particularly suitable for longer timeframes and scientific analyses, as logarithmic returns are additive.
These comprehensive features allow for precise customization of the Sigma Move Alert to individual needs and specific market conditions.
lib_momentumLibrary "lib_momentum"
This library calculates the momentum, derived from a sample range of prior candles. Depending on set MomentumType it either deduces the momentum from the price, volume, or a product of both. If price/product are selected, you can choose from SampleType if only candle body, full range from high to low or a combination of both (body counts full, wicks half for each direction) should be used. Optional: You can choose to normalize the results, dividing each value by its average (normalization_ma_length, normalization_ma). This will allow comparison between different instruments. For the normalization Moving Average you can choose any currently supported in my lib_no_delay.
get_momentum(momentum_type, sample_type, sample_length, normalization_ma_length, normalization_ma)
Parameters:
momentum_type (series MomentumType) : select one of MomentumType. to sample the price, volume or a product of both
sample_type (series SampleType) : select one of SampleType. to sample the body, total range from high to low or a combination of both (body count full, wicks half for each direction)
sample_length (simple int) : how many candles should be sampled (including the current)
normalization_ma_length (simple int) : if you want to normalize results (momentum / momentum average) this sets the period for the average. (default = 0 => no normalization)
normalization_ma (simple MovingAverage enum from robbatt/lib_no_delay/9) : is the type of moving average to normalize / compare with
Returns: returns the current momentum where the total line is not just (up - down) but also sampled over the sample_length and can therefore be used as trend indicator. If up/down fail to reach total's level it's a sign of decreasing momentum, if up/down exceed total the trend it's a sign of increasing momentum.
CAO BA NHAN//@version=5
indicator("Potential Buy/Sell Limit Zones", overlay=true)
// Tham số đầu vào
volume_threshold = input.float(1.5, title="Volume Spike Threshold", step=0.1)
support_resistance_length = input.int(20, title="Support/Resistance Lookback Length")
// Tính toán SMA của volume và kiểm tra volume spike
volume_sma = ta.sma(volume, support_resistance_length)
volume_spike = volume > volume_sma * volume_threshold
// Xác định hỗ trợ và kháng cự
support = ta.lowest(close, support_resistance_length)
resistance = ta.highest(close, support_resistance_length)
// Hiển thị các vùng giới hạn có khả năng
plot(volume_spike ? support : na, title="Potential Buy Limit Zone", color=color.green, linewidth=2, style=plot.style_stepline)
plot(volume_spike ? resistance : na, title="Potential Sell Limit Zone", color=color.red, linewidth=2, style=plot.style_stepline)
// Đánh dấu trên biểu đồ khi có volume spike tại các vùng hỗ trợ/kháng cự
bgcolor(volume_spike and close == support ? color.new(color.green, 80) : na, title="Buy Zone")
bgcolor(volume_spike and close == resistance ? color.new(color.red, 80) : na, title="Sell Zone")
Multi-Timeframe Moving Averages by Skyito"Hope everyone likes this and finds it useful! This multi-timeframe moving average indicator provides a comprehensive view of moving averages from various timeframes directly on one chart. It’s designed to help traders analyze market trends and levels more effectively without constantly switching between charts.
Script Explanation: This indicator supports a range of moving average types, including SMA, EMA, HMA, WMA, VWMA, RMA, SSMA, and DEMA, allowing for flexibility in analysis. Each moving average is fully customizable by length and type for each timeframe, giving you control over how trends are represented.
The indicator includes timeframes such as 15 minutes, 1 hour, 4 hours, 6 hours, 8 hours, 12 hours, 1 day, 3 days, 5 days, 1 week, 3 weeks, and 1 month. Each moving average is displayed as a line with a small dashed extension, showing a label that contains the moving average’s timeframe, type, and current price level. The dark blue labels are slightly enlarged to enhance readability on the chart, making it easier to track important levels at a glance.
Use Case: This tool is ideal for traders looking to stay aware of trend levels across multiple timeframes on one chart. Adjusting the moving averages’ lengths and types enables customization for any strategy, while the label information provides an immediate understanding of the timeframe and trend context.
Enjoy the streamlined view and the added insights from multi-timeframe analysis!"
Previous Daily Candle The Previous Daily Candle indicator is a powerful tool designed to enhance your intraday trading by providing clear visual cues of the previous day's price action. By outlining the high, low, open, and close of the previous daily candle and adding a middle dividing line, this indicator offers valuable context to inform your trading decisions.
🎯 Purpose
Visual Clarity: Highlight the key levels from the previous day's price movement directly on your intraday charts.
Trend Confirmation: Quickly identify bullish or bearish sentiment based on the previous day's candle structure.
Support and Resistance: Use the outlined high and low as potential support and resistance levels for your trading strategies.
Customizable Visualization: Tailor the appearance of the outlines and middle line to fit your trading style and chart aesthetics.
🛠️ Features
Outlined Candle Structure:
High and Low Lines: Clearly mark the previous day's high and low with customizable colors and line widths.
Open and Close Representation: Visualize the previous day's open and close through the outlined structure.
Middle Dividing Line:
Average Price Level: A horizontal line divides the candle in half, representing the average of the open and close prices.
Customizable Appearance: Adjust the color and thickness to distinguish it from the high and low outlines.
Bullish and Bearish Differentiation:
Color-Coded Outlines: Automatically change the outline color based on whether the previous day's candle was bullish (green by default) or bearish (red by default).
Enhanced Visual Feedback: Quickly assess market sentiment with intuitive color cues.
Customization Options:
Outline Colors: Choose distinct colors for bullish and bearish candle outlines to match your chart's color scheme.
Middle Line Color: Select a color that stands out or blends seamlessly with your existing chart elements.
Line Width Adjustment: Modify the thickness of all lines to ensure visibility without cluttering the chart.
Transparent Candle Body:
Non-Intrusive Display: The indicator only draws the outlines and middle line, keeping the candle body transparent to maintain the visibility of your primary chart data.
⚙️ How It Works
Data Retrieval: The indicator fetches the previous day's open, high, low, and close prices using TradingView's request.security function.
Candle Analysis: Determines whether the previous day's candle was bullish or bearish by comparing the close and open prices.
Dynamic Drawing: Upon the start of a new day, the indicator deletes the previous outlines and redraws them based on the latest data.
Time Synchronization: Accurately aligns the outlines with the corresponding time periods on your intraday chart.
📈 How to Use
Add to Chart:
Open TradingView and navigate to the Pine Editor.
Paste the provided Pine Script code into the editor.
Click on Add to Chart to apply the indicator.
Customize Settings:
Access the indicator's settings by clicking the gear icon next to its name on the chart.
Adjust the Bullish Outline Color, Bearish Outline Color, Middle Line Color, and Outline Width to your preference.
Interpret the Lines:
Bullish Candle: If the previous day's close is higher than its open, the outlines will display in the bullish color (default green).
Bearish Candle: If the previous day's close is lower than its open, the outlines will display in the bearish color (default red).
Middle Line: Represents the midpoint between the open and close, providing a quick reference for potential support or resistance.
Integrate with Your Strategy:
Use the high and low outlines as potential entry or exit points.
Combine with other indicators for confirmation to strengthen your trading signals.
Frosty the Trendman: A Gift to Brighten Your Christmas TradesFrosty the Trendman: A Gift to Brighten Your Christmas Trades 🎁
This festive indicator we bring to you as a Christmas gift in the form of a snowman ☃️, to light up your chart with joy and the Christmas spirit. 🎄✨
Frosty is not just a festive snowman, he's also a market expert! 📈
And he’s useful as a trading indicator. 🤑
Key Features:
• Frosty changes color based on the trend! ❄️🎨
When the trend is bullish 💹, that is, when the price is above the 200-period simple moving average (SMA 200), Frosty turns a light green 🌱, reflecting a positive, growing atmosphere. This color activates when the price is above the SMA 200, indicating a bullish trend. 📈
• When the trend is bearish 📉, that is, when the price is below the SMA 200, Frosty changes to a light red 🔴, reflecting a negative market trend and a more pessimistic sentiment. 😔
See it here!
• Interactive elements 🤖: With buttons, eyes 👀, and a nose (in the shape of a triangle), Frosty even has a dollar sign 💵 on his hat because we all like a little Christmas cheer in our trades! 💰
• Christmas cheer 🎅🏼: The snowman not only represents festive fun, but also includes a label that says "Merry Christmas" 🎄 to remind you to enjoy the Christmas spirit in your trading. 🎉
• Perfect for the holiday season! 🎁
Although Frosty is a snowman, the purpose of this indicator is to bring warmth and joy 🌟 to your trading experience. Whether for fun or simply to add some Christmas magic to your charts, Frosty is here to guide your holiday trades with a festive touch! 🎅🎄✨
Enjoy the holiday spirit while trading with Frosty! ❄️
Español
Frosty the Trendman: Un regalo para alegrar tus trades navideños 🎁
Este indicador festivo que traemos para ti como un regalo navideño en forma de un muñeco de nieve ☃️, para iluminar tu gráfico con alegría y el espíritu navideño. 🎄✨
Frosty no solo es un muñeco de nieve festivo, ¡también es un experto en el mercado! 📈 Y tiene utilidad como indicador de trading. 🤑
Características clave:
• ¡Frosty cambia de color según la tendencia! ❄️🎨
Cuando la tendencia es alcista 💹, es decir, cuando el precio se encuentra por encima de la media móvil simple de 200 periodos (SMA 200), Frosty adquiere un color verde claro 🌱, que refleja un ambiente positivo y de crecimiento.
Este color se activa cuando el precio está por encima del SMA 200, indicando que la tendencia es alcista. 📈
• Cuando la tendencia es bajista 📉, es decir, cuando el precio se encuentra por debajo del SMA 200, Frosty cambia a un color rojo claro 🔴, lo que refleja una tendencia negativa en el mercado y un sentimiento más pesimista. 😔
• Elementos interactivos 🤖: Con botones, ojos 👀 y una nariz (en forma de triángulo), ¡Frosty incluso lleva un signo de dólar 💵 en su sombrero, porque a todos nos gusta un poco de alegría navideña en nuestras operaciones! 💰
• Ánimo navideño 🎅🏼: El muñeco de nieve no solo representa diversión festiva, sino que también incluye una etiqueta que dice "Merry Christmas" 🎄 para recordarte disfrutar del espíritu navideño en tu trading. 🎉
• ¡Perfecto para la temporada navideña! 🎁: Aunque Frosty sea un muñeco de nieve, el propósito de este indicador es traer calor y alegría 🌟 a tu experiencia de trading. Ya sea para divertirte o simplemente añadir un poco de magia navideña a tus gráficos,
¡Frosty está aquí para guiar tus operaciones navideñas con un toque festivo! 🎅🎄✨
Dollar Cost Averaging (YavuzAkbay)The Dollar Cost Averaging (DCA) indicator is designed to support long-term investors following a Dollar Cost Averaging strategy. The core aim of this tool is to provide insights into overbought and oversold levels, assisting investors in managing buy and sell decisions with a clear visual cue system. Specifically developed for use in trending or fluctuating markets, this indicator leverages support and resistance levels to give structure to investors' buying strategies. Here’s a detailed breakdown of the indicator’s key features and intended usage:
Key Features and Color Coding
Overbought/Oversold Detection:
The indicator shades candles from light green to dark green when an asset becomes increasingly overbought. Dark green signals indicate a peak, where the asset is overbought, suggesting a potential opportunity to take partial profits.
Conversely, candles turn from light red to dark red when the market is oversold. Dark red signifies a heavily oversold condition, marking an ideal buying window for initiating or adding to a position. This color scheme provides a quick visual reference for investors to manage entries and exits effectively.
Support and Resistance Levels:
To address the risk of assets falling further after an overbought signal, the DCA indicator dynamically calculates support and resistance levels. These levels guide investors on key price areas to watch for potential price reversals, allowing them to make more informed buying or selling decisions.
Support levels help investors assess whether they should divide their capital across multiple buy orders, starting at the current oversold zone and extending to anticipated support zones for maximum flexibility.
Usage Methodology
This indicator is intended for Dollar Cost Averaging, a method where investors gradually add to their position rather than entering all at once. Here’s how it complements the DCA approach:
Buy at Oversold Levels: When the indicator shows a dark red candle, it signals that the asset is oversold, marking an optimal entry point. The presence of support levels can help investors determine if they should fully invest their intended amount or stagger buys at potential lower levels.
Sell at Overbought Levels: When the indicator transitions to dark green, it suggests that the asset is overbought. This is an ideal time to consider selling a portion of holdings to realize gains. The resistance levels, marked by the indicator, offer guidance on where the price may encounter selling pressure, aiding investors in planning partial exits.
Customizable Settings
The DCA indicator offers several user-adjustable parameters:
Pivot Frequency and Source: Define the pivot point frequency and the source (candle wick or body) for more tailored support/resistance detection.
Maximum Pivot Points: Set the maximum number of pivot points to be used in support/resistance calculations, providing flexibility in adapting to different market structures.
Channel Width and Line Width: Adjust the width of the channel for support/resistance levels and the thickness of the lines for easier visual tracking.
Color Intensities for Overbought/Oversold Levels: Customize the shading intensity for each overbought and oversold level to align with your trading preferences.
BTCUSD Price Overextension from Configurable SMAsBTCUSD Price Overextension Indicator with Configurable SMAs
This indicator helps identify potential correction points for BTCUSD by detecting overextended conditions based on customizable short-term and long-term SMAs, average price deviation, and divergence.
Key Features:
Customizable SMAs: Set your own lengths for short-term (default 20) and long-term (default 50) SMAs, allowing you to tailor the indicator to different market conditions.
Overextension Detection: Detects when the average price over a set period (default 10 bars) is overextended above the short-term SMA by a configurable adjustment factor.
Divergence Threshold: Highlights when the short-term and long-term SMAs diverge beyond a specified threshold, signaling potential trend continuation.
Conditional Highlight: Displays a red background only when all conditions are met, and the current candle closes at or above the previous candle. A label "Overextended" appears only on the first bar of each overextended sequence for clear identification.
How to Use:
Identify Correction Signals: Look for red background highlights, which indicate a potential overextension based on the configured SMA and divergence thresholds.
Adjust Parameters: Use the adjustment factor, divergence threshold, and SMA lengths to fine-tune the indicator for different market environments or trading strategies.
This tool is ideal for BTCUSD traders looking to spot potential pullback areas or continuation zones by analyzing trend strength and overextension relative to key moving averages.
Customizable Multi-Timeframe Doji with Ray and Editable LabelScript Overview
Script Name: Customizable Multi-Timeframe Doji Candle Levels with Ray and Editable Label
Purpose: This script helps traders identify significant price levels based on high timeframe Doji candles, allowing them to visualize key areas of support, resistance, entry, and exit. By plotting real-time Doji levels from higher timeframes directly on the current chart, traders can easily spot areas where market indecision or potential trend reversals have previously occurred, making these levels highly relevant for future price action.
How the Script Works
This script detects Doji candles on a selected higher timeframe (e.g., daily, weekly, monthly) and plots a ray at the Doji’s closing level on the current chart. The Doji candle formation, characterized by an open and close that are very close or equal, is often an indicator of market indecision. By identifying these Doji levels from high timeframes, the script provides traders with insight into where strong support and resistance zones may form.
The script continuously monitors and updates the Doji level based on the selected timeframe, ensuring that only the latest detected Doji candle is displayed on the chart, helping traders avoid clutter and focus on the most recent data.
Core Components and Calculations
1 Doji Detection Logic:
-The script calculates the Doji candle formation based on a small body percentage (defined by the C_DojiBodyPercent parameter) and relative symmetry in upper and lower shadows (defined by C_ShadowPercent and C_ShadowEqualsPercent).
-A Doji is considered valid when the open and close prices are nearly equal, and the shadows are symmetric within the defined parameters, indicating indecision.
2 Multi-Timeframe Data Retrieval:
-Using the request.security() function, the script fetches open, high, low, and close prices from the specified higher timeframe. It applies Doji detection logic to this higher timeframe data.
-barmerge.lookahead_on and barmerge.gaps_on ensure real-time updates, so the Doji level is immediately reflected on the chart when detected.
3 Ray and Label Plotting:
-When a Doji candle is detected on the selected timeframe, the script plots a ray at the Doji's close price, extending forward on the chart.
-Customizable options for the ray, including color, width, and style (solid, dotted, or dashed), help traders visually differentiate the Doji levels from other chart elements.
-An editable label can be positioned alongside the ray to denote the Doji level, with customizable text, color, background, and size to provide additional context.
4 Automatic Line and Label Management:
-The script dynamically deletes any previous ray and label when a new Doji is detected. This approach minimizes chart clutter and ensures that only the most recent Doji level from the higher timeframe is displayed.
Customization Options
1 Timeframe Selection:
Users can choose any timeframe (e.g., hourly, daily, weekly, monthly) to display Doji levels based on their specific trading strategy.
2 Ray and Label Appearance:
Ray: Customize color, width, and line style (solid, dotted, dashed) for better visibility and integration with the chart’s theme.
Label: Customize the label text, background color, text color, text size, and position (above, below, left, or right of the ray) for a personalized view.
How to Use This Script
1 Select the Target Timeframe for Doji Detection: Choose a high timeframe (such as daily or weekly) to view Doji-based support/resistance levels.
2 Set Custom Ray and Label Parameters : Adjust the visual aspects of the ray and label to align with your chart setup and make the Doji level stand out.
3 Interpretation of Doji Levels: Use the plotted Doji levels as potential support or resistance zones. Since Doji candles reflect market indecision, they often precede significant price reversals or strong continuation moves. By analyzing these levels, traders can:
- Identify key support/resistance zones based on historical market indecision.
- Set entry and exit levels around these zones to capitalize on potential reversals or
continuations.
-Spot confluence areas where the Doji level aligns with other indicators or technical patterns.
Recommended Chart Setup
For optimal clarity, use this script on a clean chart, free from overlapping indicators. This script is designed to work independently, so avoid layering multiple support/resistance scripts unless essential to avoid clutter. A clean chart helps ensure that Doji levels are readily visible, enabling a clear focus on significant levels relevant to your trading strategy.
Optimus trader Optimus Trader
Indicator Description:
The Optimus Trader indicator is designed for technical traders looking for entry and exit points in financial markets. It combines signals based on volume, moving averages, VWAP (Volume Weighted Average Price), as well as the recognition of candlestick patterns such as Pin Bar and Inside Bars. This indicator helps identify opportune moments to buy or sell based on trends, volumes, and recent liquidity zones.
Parameters and Features:
1. Simple Moving Average (MA) and VWAP:
- Optimus Trader uses a 50-period simple moving average to determine the underlying trend. It also includes VWAP for precise price analysis based on traded volumes.
- These two indicators help identify whether the market is in an uptrend or downtrend, enhancing the reliability of buy and sell signals.
2. Volume :
- To avoid false signals, a volume threshold is set using a 20-period moving average, adjusted to 1.2 times the average volume. This filters signals by considering only high-volume periods, indicating heightened market interest.
3. Candlestick Pattern Recognition:
- Pin Bar: This sought-after candlestick pattern is detected for both bullish and bearish setups. A bullish or bearish *Pin Bar* often signals a possible reversal or continuation.
- *Inside Bar*: This price compression pattern is also detected, indicating a zone of indecision before a potential movement.
4. Trend:
- An uptrend is confirmed when the price is above the MA and VWAP, while a downtrend is identified when the price is below both indicators.
5. Liquidity Zones:
- Optimus Trader includes an approximate liquidity zone detection feature. By identifying recent support and resistance levels, the indicator detects if the price is near these zones. This feature strengthens the relevance of buy or sell signals.
6. Buy and Sell Signals:
- Buy: A buy signal is generated when the indicator detects a bullish *Pin Bar* or *Inside Bar* in an uptrend with high volume, and the price is close to a liquidity zone.
- Sell: A sell signal is generated when a bearish *Pin Bar* or *Inside Bar* is detected in a downtrend with high volume, and the price is near a liquidity zone.
Signal Display:
The signals are visible directly on the chart:
- A "BUY" label in green is displayed below the bar for buy signals.
- A "SELL" label in red is displayed above the bar for sell signals.
Summary:
This indicator is intended for traders seeking precise entry and exit points by integrating trend analysis, volume, and candlestick patterns. With liquidity zones, *Optimus Trader* helps minimize false signals, providing clear and accurate alerts.
---
This description can be directly added to TradingView to help users quickly understand the features and logic of this indicator.
Fractal Trend Detector [Skyrexio]Introduction
Fractal Trend Detector leverages the combination of Williams fractals and Alligator Indicator to help traders to understand with the high probability what is the current trend: bullish or bearish. It visualizes the potential uptrend with the coloring bars in green, downtrend - in red color. Indicator also contains two additional visualizations, the strong uptrend and downtrend as the green and red zones and the white line - trend invalidation level (more information in "Methodology and it's justification" paragraph)
Features
Optional strong up and downtrends visualization: with the specified parameter in settings user can add/hide the green and red zones of the strong up and downtrends.
Optional trend invalidation level visualization: with the specified parameter in settings user can add/hide the white line which shows the current trend invalidation price.
Alerts: user can set up the alert and have notifications when uptrend/downtrend has been started, strong uptrend/downtrend started.
Methodology and it's justification
In this script we apply the concept of trend given by Bill Williams in his book "Trading Chaos". This approach leverages the Alligator and Fractals in conjunction. Let's briefly explain these two components.
The Williams Alligator, created by Bill Williams, is a technical analysis tool used to identify trends and potential market reversals. It consists of three moving averages, called the jaw, teeth, and lips, which represent different time periods:
Jaw (Blue Line): The slowest line, showing a 13-period smoothed moving average shifted 8 bars forward.
Teeth (Red Line): The medium-speed line, an 8-period smoothed moving average shifted 5 bars forward.
Lips (Green Line): The fastest line, a 5-period smoothed moving average shifted 3 bars forward.
When the lines are spread apart and aligned, the "alligator" is "awake," indicating a strong trend. When the lines intertwine, the "alligator" is "sleeping," signaling a non-trending or range-bound market. This indicator helps traders identify when to enter or avoid trades.
Williams Fractals, introduced by Bill Williams, are a technical analysis tool used to identify potential reversal points on a price chart. A fractal is a series of at least five consecutive bars where the middle bar has the highest high (for a up fractal) or the lowest low (for a down fractal), compared to the two bars on either side.
Key Points:
Up fractal: Formed when the middle bar shows a higher high than the two preceding and two following bars, signaling a potential turning point downward.
Down fractal: Formed when the middle bar has a lower low than the two surrounding bars, indicating a potential upward reversal.
Fractals are often used with other indicators to confirm trend direction or reversal, helping traders make more informed trading decisions.
How we can use its combination? Let's explain the uptrend example. The up fractal breakout to the upside can be interpret as bullish sign, there is a high probability that uptrend has just been started. It can be explained as following: the up fractal created is the potential change in market's behavior. A lot of traders made a decision to sell and it created the pullback with the fractal at the top. But if price is able to reach the fractal's top and break it, this is a high probability sign that market "changed his opinion" and bullish trend has been started. The moment of breaking is the potential changing to the uptrend. Here is another one important point, this breakout shall happen above the Alligator's teeth line. If not, this crossover doesn't count and the downtrend potentially remaining. The inverted logic is true for the down fractals and downtrend.
According to this methodology we received the high probability up and downtrend changes, but we can even add it. If current trend established by the indicator as the uptrend and alligator's lines have the following order: lips is higher than teeth, teeth is higher than jaw, script count it as a strong uptrend and start print the green zone - zone between lips and jaw. It can be used as a high probability support of the current bull market. The inverted logic can be used for bearish trend and red zones: if lips is lower than teeth and teeth is lower than jaw it's interpreted by the indicator as a strong down trend.
Indicator also has the trend invalidation line (white line). If current bar is green and market condition is interpreted by the script as an uptrend you will see the invalidation line below current price. This is the price level which shall be crossed by the price to change up trend to down trend according to algorithm. This level is recalculated on every candle. The inverted logic is valid for downtrend.
How to use indicator
Apply it to desired chart and time frame. It works on every time frame.
Setup the settings with enabling/disabling visualization of strong up/downtrend zones and trend invalidation line. "Show Strong Bullish/Bearish Trends" and "Show Trend Invalidation Price" checkboxes in the settings. By default they are turned on.
Analyze the price action. Indicator colored candle in green if it's more likely that current state is uptrend, in red if downtrend has the high probability to be now. Green zones between two lines showing if current uptrend is likely to be strong. This zone can be used as a high probability support on the uptrend. The red zone show high probability of strong downtrend and can be used as a resistance. White line is showing the level where uptrend or downtrend is going be invalidated according to indicator's algorithm. If current bar is green invalidation line will be below the current price, if red - above the current price.
Set up the alerts if it's needed. Indicator has four custom alerts called "Uptrend has been started" when current bar closed as green and the previous was not green, "Downtrend has been started" when current bar closed red and the previous was not red, "Uptrend became strong" if script started printing the green zone "Downtrend became strong" if script started printing the red zone.
Disclaimer:
Educational and informational tool reflecting Skyrex commitment to informed trading. Past performance does not guarantee future results. Test indicators before live implementation.
Bollinger Bands + RSI StrategyThe Bollinger Bands + RSI strategy combines volatility and momentum indicators to spot trading opportunities in intraday settings. Here’s a concise summary:
Components:
Bollinger Bands: Measures market volatility. The lower band signals potential buying opportunities when the price is considered oversold.
Relative Strength Index (RSI): Evaluates momentum to identify overbought or oversold conditions. An RSI below 30 indicates oversold, suggesting a buy, and above 70 indicates overbought, suggesting a sell.
Strategy Execution:
Buy Signal : Triggered when the price falls below the lower Bollinger Band while the RSI is also below 30.
Sell Signal : Activated when the price exceeds the upper Bollinger Band with an RSI above 70.
Exit Strategy : Exiting a buy position is considered when the RSI crosses back above 50, capturing potential rebounds.
Advantages:
Combines price levels with momentum for more reliable signals.
Clearly defined entry and exit points help minimize emotional trading.
Considerations:
Can produce false signals in very volatile or strongly trending markets.
Best used in markets without a strong prevailing trend.
This strategy aids traders in making decisions based on technical indicators, enhancing their ability to profit from short-term price movements.
Position Size Calculator by Dr. Rahul Ware.Position Size Calculator
The Position Size Calculator script helps traders determine the optimal position size for their trades based on their account balance, risk percentage, and stop loss parameters. It calculates the number of shares to buy and the total position size in INR (Indian Rupees), providing a clear and concise way to manage risk effectively.
Key Features:
Account Balance Input: Specify your account balance in INR to tailor the position size calculations to your specific trading capital.
Risk Percentage Input: Define the percentage of your account balance you are willing to risk on each trade, ensuring you stay within your risk tolerance.
Stop Loss Options: Choose between using a fixed stop loss price or a stop loss percentage to calculate the risk amount per share.
Dynamic Stop Loss Line: The script plots a red dotted line representing the stop loss price on the chart, updating dynamically for the last bar.
Comprehensive Table Display: View key metrics, including account balance, risk percentage, amount at risk, current price, stop loss price, stop loss percentage, position size in INR, and the number of shares to buy, all in a neatly formatted table.
This tool is designed to enhance your trading strategy by providing precise position sizing, helping you manage risk effectively and make informed trading decisions. Use this script to optimize your trade sizes and improve your overall trading performance.
Liquidity Channels [TFO]This indicator was built to visually demonstrate the significance of major, untouched pivots. With traders commonly placing orders at or near significant pivots, these areas are commonly referred to as Resting Liquidity. If we attribute some factor of growth over time, we can quickly visualize that certain pivots originated much further away than others, if their channels appear larger.
A pivot in this case is validated by the Liquidity Strength parameter. If set to 50 for example, then a pivot high is validated if its high is greater than the high of the 50 bars to the left and right of itself. This also implies a delay in finding pivots, as the drawings won't actually appear until validation, which would occur 50 bars after the original high has formed in this case. This is typical of indicators using swing highs and lows, as one must wait some period of time to validate the pivots in question.
The Channel Growth parameter dictates how much the Liquidity Channels will expand over time. The following chart is an example, where the left-hand side is using a Channel Growth of 1, and the right-hand side is using a Channel Growth of 10.
When price reaches these levels, they become invalidated and will stop extending to the right. The other condition for invalidation is the Delete After (Bars) parameter which, when enabled, declares that untouched levels will be deleted if the distance from their origin exceeds this many bars.
This indicator also offers an option to Hide Expanding Channels for those who just want the actual levels on their chart, without the extra visuals, which would look something like the below chart.
Moving Average Pullback Signals [UAlgo]The "Moving Average Pullback Signals " indicator is designed to identify potential trend continuation or reversal points based on moving average (MA) pullback patterns. This tool combines multiple types of moving averages, customized trend validation parameters, and candlestick wick patterns to provide reliable buy and sell signals. By leveraging several advanced MA methods (such as TEMA, DEMA, ZLSMA, and McGinley-D), this script can adapt to different market conditions, providing traders with flexibility and more precise trend-based entries and exits. The addition of a gradient color-coded moving average line and wick validation logic enables traders to visualize market sentiment and trend strength dynamically.
🔶 Key Features
Multiple Moving Average (MA) Calculation Methods: This indicator offers various MA calculation types, including SMA, EMA, DEMA, TEMA, ZLSMA, and McGinley-D, allowing traders to select the MA that best fits their strategy.
Trend Validation and Pattern Recognition: The indicator includes a customizable trend validation length, ensuring that the trend is consistent before buy/sell signals are generated. The "Trend Pattern Mode" setting provides flexibility between "No Trend in Progress," "Trend Continuation," and "Both," tailoring signals to the trader’s preferred style.
Wick Validation Logic: To enhance the accuracy of entries, this indicator identifies specific wick patterns for bullish or bearish pullbacks, which signal potential trend continuation or reversal. Wick length and validation factor are adjustable to suit various market conditions and timeframes.
Gradient Color-coded MA Line: This feature provides a quick visual cue for trend strength, with color changes reflecting relative highs and lows of the MA, enhancing market sentiment interpretation.
Alerts for Buy and Sell Signals: Alerts are triggered when either a bullish or bearish pullback is detected, allowing traders to receive instant notifications without continuously monitoring the chart.
Visual Labels for Reversal Points: The indicator plots labels ("R") at potential reversal points, with color-coded labels for bullish (green) and bearish (red) pullbacks, highlighting pullback opportunities that align with the trend or reversal potential.
🔶 Disclaimer
Use with Caution: This indicator is provided for educational and informational purposes only and should not be considered as financial advice. Users should exercise caution and perform their own analysis before making trading decisions based on the indicator's signals.
Not Financial Advice: The information provided by this indicator does not constitute financial advice, and the creator (UAlgo) shall not be held responsible for any trading losses incurred as a result of using this indicator.
Backtesting Recommended: Traders are encouraged to backtest the indicator thoroughly on historical data before using it in live trading to assess its performance and suitability for their trading strategies.
Risk Management: Trading involves inherent risks, and users should implement proper risk management strategies, including but not limited to stop-loss orders and position sizing, to mitigate potential losses.
No Guarantees: The accuracy and reliability of the indicator's signals cannot be guaranteed, as they are based on historical price data and past performance may not be indicative of future results.
Smooth Price Oscillator [BigBeluga]The Smooth Price Oscillator by BigBeluga leverages John Ehlers' SuperSmoother filter to produce a clear and smooth oscillator for identifying market trends and mean reversion points. By filtering price data over two distinct periods, this indicator effectively removes noise, allowing traders to focus on significant signals without the clutter of market fluctuations.
🔵 KEY FEATURES & USAGE
● SuperSmoother-Based Oscillator:
This oscillator uses Ehlers' SuperSmoother filter, applied to two different periods, to create a smooth output that highlights price momentum and reduces market noise. The dual-period application enables a comparison of long-term and short-term price movements, making it suitable for both trend-following and reversion strategies.
// @function SuperSmoother filter based on Ehlers Filter
// @param price (float) The price series to be smoothed
// @param period (int) The smoothing period
// @returns Smoothed price
method smoother_F(float price, int period) =>
float step = 2.0 * math.pi / period
float a1 = math.exp(-math.sqrt(2) * math.pi / period)
float b1 = 2 * a1 * math.cos(math.sqrt(2) * step / period)
float c2 = b1
float c3 = -a1 * a1
float c1 = 1 - c2 - c3
float smoothed = 0.0
smoothed := bar_index >= 4
? c1 * (price + price ) / 2 + c2 * smoothed + c3 * smoothed
: price
smoothed
● Mean Reversion Signals:
The indicator identifies two types of mean reversion signals:
Simple Mean Reversion Signals: Triggered when the oscillator moves between thresholds of 1 and Overbought or between thresholds -1 and Ovesold, providing additional reversion opportunities. These signals are useful for capturing shorter-term corrections in trending markets.
Strong Mean Reversion Signals: Triggered when the oscillator above the overbought (upper band) or below oversold (lower band) thresholds, indicating a strong reversal point. These signals are marked with a "+" symbol on the chart for clear visibility.
Both types of signals are plotted on the oscillator and the main chart, helping traders to quickly identify potential trade entries or exits.
● Dynamic Bands and Thresholds:
The oscillator includes overbought and oversold bands based on a dynamically calculated standard deviation and EMA. These bands provide visual boundaries for identifying extreme price conditions, helping traders anticipate potential reversals at these levels.
● Real-Time Labels:
Labels are displayed at key thresholds and bands to indicate the oscillator’s status: "Overbought," "Oversold," and "Neutral". Mean reversion signals are also displayed on the main chart, providing an at-a-glance summary of current indicator conditions.
● Customizable Threshold Levels:
Traders can adjust the primary threshold and smoothing length according to their trading style. A higher threshold can reduce signal frequency, while a lower setting will provide more sensitivity to market reversals.
The Smooth Price Oscillator by BigBeluga is a refined, noise-filtered indicator designed to highlight mean reversion points with enhanced clarity. By providing both strong and simple reversion signals, as well as dynamic overbought/oversold bands, this tool allows traders to spot potential reversals and trend continuations with ease. Its dual representation on the oscillator and the main price chart offers flexibility and precision for any trading strategy focused on capturing cyclical market movements.
Systematic Investment Tracker by Ceyhun Gonul### English Description
**Systematic Investment Tracker with Enhanced Features**
This script, titled **Systematic Investment Tracker with Enhanced Features**, is a TradingView tool designed to support systematic investments across different market conditions. It provides traders with two customizable investment strategies — **Continuous Buying** and **Declining Buying** — and includes advanced dynamic investment adjustment features for each.
#### Detailed Explanation of Script Features and Originality
1. **Two Investment Strategies**:
- **Continuous Buying**: This strategy performs purchases consistently at each interval, as set by the user, regardless of market price changes. It follows the principle of dollar-cost averaging, allowing users to build an investment position over time.
- **Declining Buying**: Unlike Continuous Buying, this strategy triggers purchases only when the asset's price has declined from the previous interval's closing price. This approach helps users capitalize on lower price points, potentially improving average costs during downward trends.
2. **Dynamic Investment Adjustment**:
- For both strategies, the script includes a **Dynamic Investment Adjustment** feature. If enabled, this feature increases the purchasing amount by 50% if the current price has fallen by a specific user-defined percentage relative to the previous price. This allows users to accumulate a larger position when the asset is declining, which may benefit long-term cost-averaging strategies.
3. **Customizable Time Frames**:
- Users can specify a **start and end date** for investment, allowing them to restrict or backtest strategies within a specific timeframe. This feature is valuable for evaluating strategy performance over specific market cycles or historical periods.
4. **Graphical Indicators and Labels**:
- The script provides graphical labels on the chart that display purchase points. These indicators help users visualize their investment entries based on the strategy selected.
- A summary **performance label** is also displayed, providing real-time updates on the total amount spent, accumulated quantity, average cost, portfolio value, and profit percentage for each strategy.
5. **Language Support**:
- The script includes English and Turkish language options. Users can toggle between these languages, allowing the summary label text and descriptions to be displayed in their preferred language.
6. **Performance Comparison Table**:
- An optional **Performance Comparison Table** is available, offering a side-by-side analysis of net profit, total investment, and profit percentage for both strategies. This comparison table helps users assess which strategy has yielded better returns, providing clarity on each approach's effectiveness under the chosen parameters.
#### How the Script Works and Its Uniqueness
This closed-source script brings together two established investment strategies in a single, dynamic tool. By integrating continuous and declining purchase strategies with advanced settings for dynamic investment adjustment, the script offers a powerful, flexible tool for both passive and active investors. The design of this script provides unique benefits:
- Enables automated, systematic investment tracking, allowing users to build positions gradually.
- Empowers users to leverage declines through dynamic adjustments to optimize average cost over time.
- Presents an easy-to-read performance label and table, enabling an efficient and transparent performance comparison for informed decision-making.
---
### Türkçe Açıklama
**Gelişmiş Özellikli Sistematik Yatırım Takipçisi**
**Gelişmiş Özellikli Sistematik Yatırım Takipçisi** adlı bu TradingView scripti, çeşitli piyasa koşullarında sistematik yatırım stratejilerini desteklemek üzere tasarlanmış bir araçtır. Script, kullanıcıya iki özelleştirilebilir yatırım stratejisi — **Sürekli Alım** ve **Düşen Alım** — ve her strateji için gelişmiş dinamik yatırım ayarlama seçenekleri sunar.
#### Script Özelliklerinin Detaylı Açıklaması ve Özgünlük
1. **İki Yatırım Stratejisi**:
- **Sürekli Alım**: Bu strateji, fiyat değişimlerine bakılmaksızın kullanıcının belirlediği her aralıkta sabit bir miktar yatırım yapar. Bu yaklaşım, uzun vadede pozisyonu kademeli olarak oluşturmak isteyenler için idealdir.
- **Düşen Alım**: Sürekli Alım’ın aksine, bu strateji yalnızca fiyat bir önceki aralığın kapanış fiyatına göre düştüğünde alım yapar. Bu yöntem, yatırımcıların daha düşük fiyatlardan alım yaparak ortalama maliyeti potansiyel olarak iyileştirmelerine yardımcı olur.
2. **Dinamik Yatırım Ayarlaması**:
- Her iki strateji için de **Dinamik Yatırım Ayarlaması** özelliği bulunmaktadır. Bu özellik aktif edildiğinde, mevcut fiyatın bir önceki fiyata göre kullanıcı tarafından belirlenen bir yüzde oranında düşmesi durumunda alım miktarını %50 artırır. Bu durum, uzun vadede maliyet ortalaması stratejilerine katkıda bulunur.
3. **Özelleştirilebilir Tarih Aralığı**:
- Kullanıcılar, yatırımı belirli bir tarih aralığında sınırlandırmak veya test etmek için bir **başlangıç ve bitiş tarihi** belirleyebilir. Bu özellik, strateji performansını geçmiş piyasa döngüleri veya belirli dönemlerde değerlendirmek için kullanışlıdır.
4. **Grafiksel İşaretleyiciler ve Etiketler**:
- Script, grafik üzerinde alım noktalarını gösteren işaretleyiciler sağlar. Bu görsel göstergeler, kullanıcıların seçilen stratejiye göre yatırım girişlerini görselleştirmesine yardımcı olur.
- Ayrıca, her strateji için harcanan toplam tutar, biriken miktar, ortalama maliyet, portföy değeri ve kâr yüzdesi gibi bilgileri gerçek zamanlı olarak gösteren bir **performans etiketi** sunar.
5. **Dil Desteği**:
- Script, İngilizce ve Türkçe dillerini desteklemektedir. Kullanıcılar, performans etiketi metninin ve açıklamalarının tercih ettikleri dilde görüntülenmesi için dil seçimini yapabilir.
6. **Performans Karşılaştırma Tablosu**:
- İsteğe bağlı olarak kullanılabilen bir **Performans Karşılaştırma Tablosu**, her iki strateji için net kâr, toplam yatırım ve kâr yüzdesi gibi bilgileri yan yana analiz eder. Bu tablo, kullanıcıların hangi stratejinin daha yüksek getiri sağladığını değerlendirmesine yardımcı olur.
#### Scriptin Çalışma Prensibi ve Özgünlüğü
Bu script, iki yatırım stratejisini gelişmiş bir araçta birleştirir. Sürekli ve düşen fiyatlara dayalı alım stratejilerini dinamik yatırım ayarlama özelliğiyle entegre ederek yatırımcılar için güçlü ve esnek bir çözüm sunar. Script’in tasarımı aşağıdaki benzersiz faydaları sağlamaktadır:
- Otomatik, sistematik yatırım takibi yaparak kullanıcıların pozisyonlarını kademeli olarak oluşturmalarına olanak tanır.
- Dinamik ayarlama ile düşüşlerden yararlanarak zaman içinde ortalama maliyeti optimize etme olanağı sağlar.
- Her iki stratejinin performansını basit ve anlaşılır bir şekilde karşılaştıran etiket ve tablo ile verimli bir performans değerlendirmesi sunar.