gridUtilitiesLibrary "gridUtilities"
TODO: add library description here
get_fibonacciGrid_data(length, trend_direction, plot_grid, plot_labels, bars_to_right, include_levels)
: Gets and plots a fibonacci grid.
Parameters:
length (int) : (int): The direction flag that indicates where the trend is going.
trend_direction (string) : (string): Direction of the trend (Long, Short or Neutral)
plot_grid (bool) : (bool): Plots the fibonacci grid.
plot_labels (bool) : (bool): Plots the datatable.
bars_to_right (int) : (bool): Plots the datatable.
include_levels (bool) : (bool): Plots the datatable.
Returns: : Returns a map with the grid levels, as string with the direction of the grid and a map with the values for the dataTable.
Indikatoren und Strategien
Thrax - Intraday Market Pressure ZonesTHRAX - INTRADAY MARKET PRESSURE ZONES
This indicator identifies potential support and resistance zones based on areas of significant market pressure. It dynamically plots these zones and adjusts their visibility based on real-time price action and user-defined thresholds. The indicator is useful for traders seeking to understand intraday market pressure, visualize zones of potential price reversals, and analyze volume imbalances at critical levels.
1. Support/Resistance Zones: Wherever the price retraces significantly from its high a support zone is drawn and when it retraces significantly from it low a resistance zone is drawn. The significant retracing is measured by the wick threshold percentage. For instance, if set to 75%, it implies price retracement of 75% either from high or from low for a particular candel
Volume delat: Displays volume delta information where the zones are formed. This can be used by trader to consider only those zones where delta is significant.
2. Breakout Detection: Monitors for price breakouts beyond established zones, deleting zones that are invalidated by price movement. when the price breaks a given zone with the threshold, it is considered to be mitigated and chances of trend continuation is decent.
Candle Coloring: Uses color codes (green, red, and yellow) to represent bullish, bearish, and indecisive (doji) candles, aiding quick visual assessment.
INPUTS
1. Wick Threshold (%) : Sets the minimum wick percentage required for a candle to be considered a support or resistance candidate.
2. Breakout Threshold (%) : Determines the percentage above or below a support or resistance zone that defines a breakout condition. if breaks a zone with the set threshold then the zone will be considered mititgated.
3. Max Number of Support/Resistance Zones : Limits the maximum number of support/resistance zones displayed on the chart, ranging from 1 to 5.
4. Show Wick Percentage Labels : Toggles the display of percentage values for upper and lower wicks on each candle.
TRADE SETUP
Identifying Entry Points: Look for the formation of support or resistance zones. Wait for price to retrace to these zones. if you are willing to take risk, you can consider even zones with low delta. If you want to be more cautious you should consider zones with high delta.
Volume Confirmation: Use the volume information to confirm the strength of the zone. Strong volume differences (displayed as labels) can indicate significant market pressure at these levels.
Breakout Trades: If price breaks through a support/resistance zone by more than the breakout threshold, consider this a signal for a potential trend continuation in the breakout direction.
Risk Management: Set stop-loss levels slightly outside of the identified zones to minimize risk in case of false breakouts. This can be set in input setting for breakout threshold.
Bonus Tip : Mark your significant highs and lows from where prices have retraced multiple times in the near past and if the zone is near these levels it can serve s a strong candidate of support or resistance
Therefore, in conclusion monitor the zones, based on delta and volume presence filter out the zone, wait for price retracement to the zone, intiate the trade with stop loss below zone with a set percentage.
Momentum Cloud.V33🌟 Introducing MomentumCloud.V33 🌟
MomentumCloud.V33 is a cutting-edge indicator designed to help traders capture market momentum with clarity and precision. This versatile tool combines moving averages, directional movement indexes (DMI), and volume analysis to provide real-time insights into trend direction and strength. Whether you’re a scalper, day trader, or swing trader, MomentumCloud.V33 adapts to your trading style and timeframe, making it an essential addition to your trading toolkit. 📈💡
🔧 Customizable Parameters:
• Moving Averages: Adjust the periods of the fast (MA1) and slow (MA2) moving averages to fine-tune your trend analysis.
• DMI & ADX: Customize the DMI length and ADX smoothing to focus on strong, actionable trends.
• Volume Multiplier: Modify the cloud thickness based on trading volume, emphasizing trends with significant market participation.
📊 Trend Detection:
• Color-Coded Clouds:
• Green Cloud: Indicates a strong uptrend, suggesting buying opportunities.
• Red Cloud: Indicates a strong downtrend, signaling potential short trades.
• Gray Cloud: Reflects a range-bound market, helping you avoid low-momentum periods.
• Dynamic Volume Integration: The cloud thickness adjusts dynamically with trading volume, highlighting strong trends supported by high market activity.
📈 Strength & Momentum Analysis:
• Strength Filtering: The ADX component ensures that only strong trends are highlighted, filtering out market noise and reducing false signals.
• Visual Momentum Gauge: The cloud color and thickness provide a quick visual representation of market momentum, enabling faster decision-making.
🔔 Alerts:
• Custom Alerts: Set up alerts for when the trend shifts or reaches critical levels, keeping you informed without needing to constantly monitor the chart.
🎨 Visual Enhancements:
• Gradient Cloud & Shadows: The indicator features a gradient-filled cloud with shadowed moving averages, enhancing both aesthetics and clarity on your charts.
• Adaptive Visual Cues: MomentumCloud.V33’s color transitions and dynamic thickness provide an intuitive feel for the market’s rhythm.
🚀 Quick Guide to Using MomentumCloud.V33
1. Add the Indicator: Start by adding MomentumCloud.V33 to your chart. Customize the settings such as MA periods, DMI length, and volume multiplier to match your trading style.
2. Analyze the Market: Observe the color-coded cloud and its thickness to gauge market momentum and trend direction. The thicker the cloud, the stronger the trend.
3. Set Alerts: Activate alerts for trend changes or key levels to capture trading opportunities without needing to watch the screen continuously.
⚙️ How It Works:
MomentumCloud.V33 calculates market momentum by combining moving averages, DMI, and volume. The cloud color changes based on the trend direction, while its thickness reflects the strength of the trend as influenced by trading volume. This integrated approach ensures you can quickly identify robust market movements, making it easier to enter and exit trades at optimal points.
Settings Overview:
• Moving Averages: Define the lengths for the fast and slow moving averages.
• DMI & ADX: Adjust the DMI length and ADX smoothing to focus on significant trends.
• Volume Multiplier: Customize the multiplier to control cloud thickness, highlighting volume-driven trends.
📚 How to Use MomentumCloud.V33:
• Trend Identification: The direction and color of the cloud indicate the prevailing trend, while the cloud’s thickness suggests the trend’s strength.
• Trade Execution: Use the green cloud to look for long entries and the red cloud for short positions. The gray cloud advises caution, as it represents a range-bound market.
• Alerts: Leverage the custom alerts to stay on top of market movements and avoid missing critical trading opportunities.
Unleash the power of trend and momentum analysis with MomentumCloud.V33! Happy trading! 📈🚀✨
Multi-Step FlexiSuperTrend - Indicator [presentTrading]This version of the indicator is built upon the foundation of a strategy version published earlier. However, this indicator version focuses on providing visual insights and alerts for traders, rather than executing trades. This one is mostly for @thorcmt.
█ Introduction and How it is Different
The **Multi-Step FlexiSuperTrend Indicator** is a versatile tool designed to provide traders with a highly customizable and flexible approach to trend analysis. Unlike traditional supertrend indicators, which focus on a single factor or threshold, the **FlexiSuperTrend** allows users to define multiple levels of take-profit targets and incorporate different trend normalization methods.
It comes with several advanced customization features, including multi-step take profits, deviation plotting, and trend normalization, making it suitable for both novice and expert traders.
BTCUSD 6hr Performance
█ Strategy, How It Works: Detailed Explanation
The **Multi-Step FlexiSuperTrend** works by calculating a supertrend based on multiple factors and incorporating oscillations from trend deviations. Here’s a breakdown of how it functions:
🔶 SuperTrend Calculation
At the heart of the indicator is the SuperTrend formula, which dynamically adjusts based on price movements.
🔶 Normalization of Deviations
To enhance accuracy, the **FlexiSuperTrend** calculates multiple deviations from the trend and normalizes them.
🔶 Multi-Step Take Profit Levels
The indicator allows setting up to three take profit levels, which are displayed via price level alerts. lows traders to exit part of their position at various profit intervals.
For more detail, please check the strategy version - Multi-Step-FlexiSuperTrend-Strategy:
and 'FlexiSuperTrend-Strategy'
█ Trade Direction
The **Multi-Step FlexiSuperTrend Indicator** supports both long and short trade directions.
This flexibility allows traders to adapt to trending, volatile, or sideways markets.
█ Usage
To use the **FlexiSuperTrend Indicator**, traders can set up their preferences for the following key features:
- **Trading Direction**: Choose whether to focus on long, short, or both signals.
- **Indicator Source**: The price source to calculate the trend (e.g., close, hl2).
- **Indicator Length**: The number of periods to calculate the ATR and trend (the larger the value, the smoother the trend).
- **Starting and Increment Factor**: These adjust how reactive the trend is to price movements. The starting factor dictates how far the initial trend band is from the price, and the increment factor adjusts subsequent trend deviations.
The indicator then displays buy and sell signals on the chart, along with alerts for each take-profit level.
Local picture
█ Default Settings
The default settings of the **Multi-Step FlexiSuperTrend** are carefully designed to provide an optimal balance between sensitivity and accuracy. Let’s examine these default parameters and their effect on performance:
🔶 Indicator Length (Default: 10)
The **Indicator Length** determines the lookback period for the ATR calculation. A smaller value makes the indicator more reactive to price changes, but may generate more false signals. A longer length smooths the trend and reduces noise but may delay signals.
Effect on performance: Shorter lengths perform better in volatile markets, while longer lengths excel in trending markets.
🔶 Starting Factor (Default: 0.618)
This factor adjusts the starting distance of the SuperTrend from the current price. The smaller the starting factor, the closer the trend is to the price, making it more sensitive. Conversely, a larger factor allows more distance, reducing sensitivity but filtering out false signals.
Effect on performance: A smaller factor provides quicker signals but can lead to frequent false positives. A larger factor generates fewer but more reliable signals.
🔶 Increment Factor (Default: 0.382)
The **Increment Factor** controls how the trend bands adjust as the price moves. It increases the distance of the bands from the price with each iteration.
Effect on performance: A higher increment factor can result in wider stop-loss or trend reversal bands, allowing for longer trends to develop without frequent exits. A lower factor keeps the bands closer to the price and is more suited for shorter-term trades.
🔶 Take Profit Levels (Default: 2%, 8%, 18%)
The default take-profit levels are set at 2%, 8%, and 18%. These values represent the thresholds at which the trader can partially exit their positions. These multi-step levels are highly customizable depending on the trader’s risk tolerance and strategy.
Effect on performance: Lower take-profit levels (e.g., 2%) capture small, quick profits in volatile markets, while higher levels (8%-18%) allow for a more gradual exit in strong trends.
🔶 Normalization Method (Default: None)
The default normalization method is **None**, meaning the deviations are not normalized. However, enabling normalization (e.g., **Max-Min**) can improve the clarity of the indicator’s signals in volatile or choppy markets by smoothing out the noise.
Effect on performance: Using a normalization method can reduce the effect of extreme deviations, making signals more stable and less prone to false positives.
Bearish signal using Point of Control (POC) with PAC by guruThis indicator code helps traders identify potential sell opportunities using several important technical indicators:
Point of Control (POC) – This is the price level where the most volume was traded over the past several days.
Previous Day's Low – This shows the lowest price reached during the previous day.
PAC (Price Action Channel) EMA – These are two moving averages (one based on the low price and one based on the close price) that help determine if the price is trending within a certain range.
Volume SMA – This is a 3-day simple moving average (SMA) of volume, which helps filter out signals based on market activity.
What the Script Does:
Point of Control (POC):
The script looks at the last 50 days (configurable) and calculates which price level had the highest trading volume.
It then plots a red line on the chart at the POC level. This is important because it helps identify areas where there was strong market interest in the past.
Volume Moving Average:
The script calculates a 3-day SMA of volume, but it excludes the current day to avoid premature signals based on today’s trading.
The volume SMA is used to ensure there’s enough market activity (with a threshold set to 25 units) before triggering a sell signal.
Price Action Channel (PAC) EMA:
The PAC consists of two exponential moving averages (EMAs):
The PAC Low EMA: This is based on the low prices over the last 34 periods (configurable).
The PAC Close EMA: This is based on the closing prices over the last 34 periods.
These EMAs help determine if the price is trending above or below certain price levels.
Sell Signal Logic: The script checks three conditions before displaying a "Sell" signal:
Price Below POC and Previous Day’s Low:
The close price must be below both the Point of Control (POC) and the previous day's low.
Volume SMA Above 25:
The 3-day volume SMA must be greater than 25. This ensures the signal only triggers when there’s enough trading volume in the market.
Today’s Low is Above PAC EMAs:
Today's low price must be above both the PAC low EMA and the PAC close EMA. This prevents sell signals when prices are already significantly below the PAC, indicating possible exhaustion in the downtrend.
If all three conditions are met, the script will display a red "Sell" label on the chart, signaling a potential selling opportunity.
No Sell Signal if Price Reverses:
If the price crosses back above the POC or the previous day's low, the script will remove the sell signal and reset for a new opportunity.
Summary of Conditions:
For the script to display a "Sell" label:
The close price must be below the Point of Control (POC) and the previous day’s low.
The 3-day volume SMA (excluding today) must be greater than 25 units.
The low price of the current day must be above both the PAC low EMA and the PAC close EMA.
If these conditions are met, a red sell label appears on the chart as a potential signal for a short (sell) trade.
Trend CCITrend CCI (TCCI) Indicator
Description:
The Trend CCI (TCCI) indicator is a unique combination of the Commodity Channel Index (CCI) and the Average True Range (ATR), designed to identify trends and market reversals with a refined sensitivity to price volatility. The indicator plots the CCI, adjusted by an ATR filter, and color-codes the trendline to signal uptrends and downtrends.
How It Works:
This indicator uses the CCI to measure price momentum and an ATR-based filter to smooth out market noise, making it easier to detect significant shifts in the market trend. Key parameters such as the ATR Period, ATR Multiplier, and CCI Period have been carefully chosen to optimize the indicator's performance:
1. ATR Period (default: 18)
The ATR Period determines the number of periods used to calculate the **Average True Range**, which reflects market volatility. In this case, an **ATR Period of 18** has been selected for several reasons:
Balance between responsiveness and noise reduction : A period of 18 strikes a balance between being responsive to recent price movements and filtering out minor fluctuations. Shorter ATR periods might be too reactive, creating false signals, while longer periods might miss shorter-term trends.
Adaptable to various market conditions : An 18-period ATR is suitable for both intraday and swing trading strategies, making it versatile across different time frames.
Standard industry practice : Many traders use ATR settings between 14 and 20 periods as a convention for detecting reliable volatility levels.
2. ATR Multiplier (default: 1.5)
The ATR Multiplier is applied to the ATR value to define how sensitive the indicator is to volatility. In this case, a multiplier of 1.5 has been chosen:
Avoiding whipsaws in low volatility markets: By setting the multiplier to 1.5, the indicator filters out smaller, less significant price movements, reducing the likelihood of whipsaw signals (i.e., false trend reversals during periods of low volatility).
Optimizing signal accuracy: A moderate multiplier like 1.5 ensures that the indicator only generates signals when the price moves a significant distance from the average range. Higher multipliers (e.g., 2.0) may ignore valid opportunities, while lower multipliers (e.g., 1.0) might create too many signals.
Enhancing trend clarity : The multiplier’s role in widening the range allows the indicator to respond more clearly during periods of strong trends, reducing signal noise and false positives.
3. CCI Period (default: 63)
The CCI Period defines the number of periods used to calculate the Commodity Channel Index. A 63-period CCI is selected based on the following considerations:
Smoothing the momentum calculation: A longer period, such as 63, is used to smooth out the CCI and reduce the effects of short-term price fluctuations. This period captures longer-term momentum, making it ideal for identifying more significant market trends.
-Filtering out short-term noise: While shorter CCI periods (e.g., 14 or 20) may be more reactive, they tend to produce more signals, some of which may be false. A 63-period CCI focuses on stronger and more sustained price movements, providing fewer but higher-quality signals.
Adapted to intermediate trading: A 63-period CCI aligns well with traders looking for medium-term trend-following strategies, striking a balance between long-term trend identification and responsiveness to significant price shifts.
How to Use:
Green Area: When the trendline turns green, it signals that the CCI is positive, reflecting upward momentum. This can be interpreted as a buy signal, indicating the potential for long positions or continuing bullish trades.
Red Area: When the trendline turns red, it signals that the CCI is negative, reflecting downward momentum. This can be interpreted as a sell signal, indicating potential short positions or bearish trades.
ATR Filter: The ATR helps reduce false signals by ignoring minor price movements. Traders can adjust the ATR Multiplier to make the indicator more or less sensitive based on market conditions. A lower multiplier (e.g., 1.2) may increase signal frequency, while a higher multiplier (e.g., 2.0) reduces it.
Originality:
The Trend CCI (TCCI) stands out due to its combination of the CCI and ATR. While many indicators simply plot raw CCI values, this script enhances the CCI’s effectiveness by incorporating an ATR-based volatility filter. This ensures that only significant trends trigger signals, making it a more reliable tool in volatile markets. The choice of the ATR period, multiplier, and CCI period ensures a refined balance between trend detection and noise reduction, distinguishing it as a powerful trend-following indicator.
Additionally, the visual aspect—using color-coded trendlines that dynamically shift between green and red—simplifies the interpretation of market trends, offering traders a clear and immediate understanding of trend direction and momentum strength.
Final Recommendations:
Use in Trending Markets The TCCI is most effective in trending markets, where its signals align with broader market momentum. In sideways or low-volatility markets, consider adjusting the ATR multiplier or using other complementary indicators to confirm the signals.
Risk Management: Always integrate robust risk management practices, such as using stop-loss orders and position sizing, to protect against sudden market reversals or periods of heightened volatility.
Adjust for Volatility: Consider the volatility of the asset being traded. In highly volatile assets, a higher ATR multiplier (e.g., 2.0) may be necessary to filter out noise, while in more stable assets, a lower multiplier (e.g., 1.2) might generate earlier signals.
By using the Trend CCI (TCCI) indicator with a deeper understanding of its key parameters, traders can better identify trends, reduce noise, and improve their overall decision-making in the markets.
Good Profits!
DRIP Yearly PerformanceOverview: The DRIP Yearly Performance indicator is designed for long-term investors using Dividend Reinvestment Plans (DRIP). This script calculates both the total and average yearly performance of an asset, factoring in the reinvestment of dividends over time. It provides key insights into portfolio growth by tracking the number of accumulated units from dividend reinvestment and how this impacts overall performance.
Key Features:
Dividend Reinvestment (DRIP) Calculation: Automatically adjusts the number of units held by reinvesting dividends, enhancing the calculation of total returns.
Custom Start Date: Choose a custom start date to begin tracking performance from a specific time period, allowing for more tailored performance analysis.
Performance Metrics: Displays key metrics such as the initial investment value, current value, total performance percentage, and the average yearly performance, all in an easy-to-read table format.
Visual Representation: Plots accumulated units and overall performance on the chart, with customizable colors for clarity.
Inputs Explained:
Start Quantity: Define the initial number of units (shares) held at the start of the investment.
Dividend Type: Choose between tracking Net or Gross dividends for reinvestment purposes. Net is always better unless you have a special case and you need to base your calculations on gross.
Start Date: Select a custom date to begin tracking performance. This allows users to focus on performance from any historical point.
Table Size: Customize the size of the text in the performance table to suit your visual preferences.
Performance Line Color: Choose the color of the performance plot line that tracks the value of your investment over time.
Accumulator Line Color: Customize the color of the line that tracks the accumulated units (shares) due to reinvested dividends.
Who Can Benefit: This indicator is ideal for long-term investors and dividend growth investors who want to measure their investment returns over time while factoring in the effects of dividend reinvestment.
Use Cases:
Tracking Dividend Impact: See how reinvesting dividends enhances your overall portfolio value.
Custom Performance Analysis: Set a custom start date to analyze performance from a specific point in time.
Visualizing Growth: Use the chart's plots to visually track your growing number of shares (units) and overall performance.
Uptrick: Market MoodsThe "Uptrick: Market Moods" indicator is an advanced technical analysis tool designed for the TradingView platform. It combines three powerful indicators—Relative Strength Index (RSI), Average True Range (ATR), and Bollinger Bands—into one cohesive framework, aimed at helping traders better understand and interpret market sentiment. By capturing shifts in the emotional climate of the market, it provides a holistic view of market conditions, which can range from calm to stressed or even highly excited. This multi-dimensional analysis tool stands apart from traditional single-indicator approaches by offering a more complete picture of market dynamics, making it a valuable resource for traders looking to anticipate and react to changes in market behavior.
The RSI in the "Uptrick: Market Moods" indicator is used to measure momentum. RSI is an essential component of many technical analysis strategies, and in this tool, it is used to identify potential market extremes. When RSI values are high, they indicate an overbought condition, meaning the market may be approaching a peak. Conversely, low RSI values suggest an oversold condition, signaling that the market could be nearing a bottom. These extremes provide crucial clues about shifts in market sentiment, helping traders gauge whether the current emotional state of the market is likely to result in a reversal. This understanding is pivotal in predicting whether the market is transitioning from calm to stressed or from excited to overbought.
The Average True Range adds another layer to this analysis by offering insights into market volatility. Volatility is a key factor in understanding the mood of the market, as periods of high volatility often reflect high levels of excitement or stress, while low volatility typically indicates a calm, steady market. ATR is calculated based on the range of price movements over a given period, and the higher the value, the more volatile the market is. The "Uptrick: Market Moods" indicator uses ATR to dynamically gauge volatility levels, helping traders understand whether the market is currently moving in a way that aligns with its emotional mood. For example, an increase in ATR accompanied by an RSI value that indicates overbought conditions could suggest that the market is in a highly excited state, with the potential for either strong momentum continuation or a sharp reversal.
Bollinger Bands complement these tools by providing visual cues about price volatility and the range within which the market is likely to move. Bollinger Bands plot two standard deviations away from a simple moving average of the price. This banding technique helps traders visualize how far the price is likely to deviate from its average over a certain period. The "Uptrick: Market Moods" indicator uses Bollinger Bands to establish price boundaries and identify breakout conditions. When prices break above the upper band or below the lower band, it often signals that the market is either highly stressed or excited. This breakout condition serves as a visual representation of the market mood, alerting traders to moments when prices are moving beyond typical ranges and when significant emotional shifts are occurring in the market.
Technically, the "Uptrick: Market Moods" indicator has been developed using TradingView’s Pine Script language, a highly efficient language for building custom indicators. It employs functions like ta.rsi, ta.atr, and ta.sma to perform the necessary calculations. The use of these built-in functions ensures that the calculations are both accurate and efficient, allowing the indicator to operate in real-time without lagging, even in volatile market conditions. The ta.rsi function is used to compute the Relative Strength Index, while ta.atr calculates the Average True Range, and ta.sma is used to smooth out price data for the Bollinger Bands. These functions are applied dynamically within the script, allowing the "Uptrick: Market Moods" indicator to respond to changes in market conditions in real time.
The user interface of the "Uptrick: Market Moods" indicator is designed to provide a visually intuitive experience. The market mood is color-coded on the chart, making it easy for traders to identify whether the market is calm, stressed, or excited at a glance. This feature is especially useful for traders who need to make quick decisions in fast-moving markets. Additionally, the indicator includes an interactive table that updates in real-time, showing the most recent mood state and its frequency. This provides valuable statistical insights into market behavior over specific time frames, helping traders track the dominant emotional state of the market. Whether the market is in a prolonged calm state or rapidly transitioning through moods, this real-time feedback offers actionable data that can help traders adjust their strategies accordingly.
The RSI component of the "Uptrick: Market Moods" indicator helps detect the speed and direction of price movements, offering insight into whether the market is approaching extreme conditions. By providing signals based on overbought and oversold levels, the RSI helps traders decide whether to enter or exit positions. The ATR element acts as a volatility gauge, dynamically adjusting traders’ expectations in response to changes in market volatility. Meanwhile, the Bollinger Bands help identify trends and potential breakout conditions, serving as an additional confirmation tool that highlights when the price has moved beyond normal boundaries, indicating heightened market excitement or stress.
Despite the robust capabilities of the "Uptrick: Market Moods" indicator, it does have limitations. In markets affected by sudden shifts, such as those driven by major news events or external economic factors, the indicator’s performance may not always be reliable. These external factors can cause rapid mood swings that are difficult for any technical analysis tool to fully anticipate. Additionally, the indicator’s complexity may pose a learning curve for novice traders, particularly those who are unfamiliar with the concepts of RSI, ATR, and Bollinger Bands. However, with practice, traders can become proficient in using the tool to its full potential, leveraging the insights it provides to better navigate market shifts.
For traders seeking a deeper understanding of market sentiment, the "Uptrick: Market Moods" indicator is an invaluable resource. It is recommended for those dealing with medium to high volatility instruments, where understanding emotional shifts can offer a strategic advantage. While it can be used on its own, integrating it with other forms of analysis, such as fundamental analysis and additional technical indicators, can enhance its effectiveness. By confirming signals with other tools, traders can reduce the likelihood of false signals and improve their overall trading strategy.
To further enhance the accuracy of the "Uptrick: Market Moods" indicator, it can be integrated with volume-based tools like Volume Profile or On-Balance Volume (OBV). This combination allows traders to confirm the moods identified by the indicator with volume data, providing additional confirmation of market sentiment. For example, when the market is in an excited mood, an increase in trading volume could reinforce the reliability of that signal. Conversely, if the market is stressed but volume remains low, traders may want to proceed with caution. Using multiple indicators together creates a more comprehensive trading approach, helping traders better manage risk and make informed decisions based on multiple data points.
In conclusion, the "Uptrick: Market Moods" indicator is a powerful and unique addition to the suite of technical analysis tools available on TradingView. It provides traders with a multi-dimensional view of market sentiment by combining the analytical strengths of RSI, ATR, and Bollinger Bands into a single tool. Its ability to capture and interpret the emotional mood of the market makes it an essential tool for traders seeking to gain an edge in understanding market behavior. While the indicator has certain limitations, particularly in rapidly shifting markets, its ability to provide real-time insights into market sentiment is a valuable asset for traders of all experience levels. Used in conjunction with other tools and sound trading practices, the "Uptrick: Market Moods" indicator offers a comprehensive solution for navigating the complexities of financial markets.
High Yield Spread Strategy with SMA FilterThis Pine Script strategy is designed for statistical analysis and research purposes only, not for live trading or financial decision-making. The script evaluates the relationship between financial volatility (measured by either the VIX or the High Yield Spread) and market positioning strategies (long or short) based on user-defined conditions. Specifically, it allows users to test the assumption that elevated levels of VIX or the High Yield Spread may justify short positions in the market—a widely held belief in financial circles—but this script demonstrates that shorting is not always the optimal choice, even under these conditions.
Key Components:
1. High Yield Spread and VIX:
• High Yield Spread is the difference between the yields of corporate high-yield (or “junk”) bonds and U.S. Treasury securities. A rising spread often reflects increased market risk perception.
• VIX (Volatility Index) is often referred to as the market’s “fear gauge.” Higher VIX levels usually indicate heightened market uncertainty or expected volatility.
2. Strategy Logic:
• The script allows users to specify a threshold for the VIX or High Yield Spread, and it automatically evaluates if the spread exceeds this level, which traditionally would suggest an environment for higher market risk and thus potentially favoring short trades.
• However, the strategy provides flexibility to enter long or short positions, even in a high-risk environment, emphasizing that a high VIX or High Yield Spread does not always warrant shorting.
3. SMA Filter:
• A Simple Moving Average (SMA) filter can be applied to the price data, where positions are only entered if the price is above or below the SMA (depending on the trade direction). This adds a technical component to the strategy, incorporating price trends into decision-making.
4. Hold Duration:
• The script also allows users to define how long to hold a position after entering, enabling an analysis of different timeframes.
Theoretical Background:
The traditional belief that high VIX or High Yield Spreads favor short positions is not universally supported by research. While a spike in the VIX or credit spreads is often associated with increased market risk, research suggests that excessive volatility does not always lead to negative returns. In fact, high volatility can sometimes signal an approaching market rebound.
For example:
• Studies have shown that long-term investments during periods of heightened volatility can yield favorable returns due to mean reversion. Whaley (2000) notes that VIX spikes are often followed by market recoveries as volatility tends to revert to its mean over time .
• Research by Blitz and Vliet (2007) highlights that low-volatility stocks have historically outperformed high-volatility stocks, suggesting that volatility may not always predict negative returns .
• Furthermore, credit spreads can widen in response to broader market stress, but these may overshoot the actual credit risk, presenting opportunities for long positions when spreads are high and risk premiums are mispriced .
Educational Purpose:
The goal of this script is to challenge assumptions about shorting during volatile periods, showing that long positions can be equally, if not more, effective during market stress. By incorporating an SMA filter and customizable logic for entering trades, users can test different hypotheses regarding the effectiveness of both long and short positions under varying market conditions.
Note: This strategy is not intended for live trading and should be used solely for educational and statistical exploration. Misinterpreting financial indicators can lead to incorrect investment decisions, and it is crucial to conduct comprehensive research before trading.
References:
1. Whaley, R. E. (2000). “The Investor Fear Gauge”. The Journal of Portfolio Management, 26(3), 12-17.
2. Blitz, D., & van Vliet, P. (2007). “The Volatility Effect: Lower Risk Without Lower Return”. Journal of Portfolio Management, 34(1), 102-113.
3. Bhamra, H. S., & Kuehn, L. A. (2010). “The Determinants of Credit Spreads: An Empirical Analysis”. Journal of Finance, 65(3), 1041-1072.
This explanation highlights the academic and research-backed foundation of the strategy and the nuances of volatility, while cautioning against the assumption that high VIX or High Yield Spread always calls for shorting.
Sector Performance v0.3Sector Performance Dashboard v0.3 (Work In Progress)
- Provides a comprehensive view of sector and stock performance across multiple timeframes
Features:
- Displays performance data for various Indian market sectors and their constituent stocks
- Allows selection of different sector groups (e.g., NIFTY, BANKNIFTY, CNXAUTO, etc.)
- Shows performance over four customizable time periods (default: Year, Quarter, Month, Week)
- Calculates percentage change for each time period
- Presents current price, 250-day high and low, and percentage distance from these extremes
- Uses color-coding to quickly identify positive (green) and negative (red) performance
- Adjustable text size for better visibility
- Functionality:
- Creates a table in the center of the chart
- Populates the table with up to 15 symbols per sector
- Updates data in real-time on daily timeframe
- Allows for easy comparison of different stocks within a sector
- User Inputs:
- Sector selection
- Four customizable date inputs for different time periods
- Adjustable text size for the table
- Use Cases:
- Quick sector rotation analysis
- Identifying outperforming and underperforming stocks within a sector
- Monitoring multiple timeframes simultaneously for comprehensive market view
- Assisting in stock screening and selection process
Enhanced MACD and RSI Buy/Sell Signals - Created by Marco NucupKey Features:
EMA Filter: Adds an Exponential Moving Average (EMA) to filter signals based on the trend. Buys are only considered when the price is above the EMA, and sells when below it.
Customizable Inputs: Users can adjust parameters for EMA, MACD, and RSI directly from the TradingView interface, allowing for more personalized strategies.
Alerts: The script includes alert conditions for both buy and sell signals, enabling users to receive notifications.
Signal Plotting: Visual indicators for buy and sell signals on the chart, along with the EMA line for trend reference.
Bitcoin Logarithmic Growth Curve 2024The Bitcoin logarithmic growth curve is a concept used to analyze Bitcoin's price movements over time. The idea is based on the observation that Bitcoin's price tends to grow exponentially, particularly during bull markets. It attempts to give a long-term perspective on the Bitcoin price movements.
The curve includes an upper and lower band. These bands often represent zones where Bitcoin's price is overextended (upper band) or undervalued (lower band) relative to its historical growth trajectory. When the price touches or exceeds the upper band, it may indicate a speculative bubble, while prices near the lower band may suggest a buying opportunity.
Unlike most Bitcoin growth curve indicators, this one includes a logarithmic growth curve optimized using the latest 2024 price data, making it, in our view, superior to previous models. Additionally, it features statistical confidence intervals derived from linear regression, compatible across all timeframes, and extrapolates the data far into the future. Finally, this model allows users the flexibility to manually adjust the function parameters to suit their preferences.
The Bitcoin logarithmic growth curve has the following function:
y = 10^(a * log10(x) - b)
In the context of this formula, the y value represents the Bitcoin price, while the x value corresponds to the time, specifically indicated by the weekly bar number on the chart.
How is it made (You can skip this section if you’re not a fan of math):
To optimize the fit of this function and determine the optimal values of a and b, the previous weekly cycle peak values were analyzed. The corresponding x and y values were recorded as follows:
113, 18.55
240, 1004.42
451, 19128.27
655, 65502.47
The same process was applied to the bear market low values:
103, 2.48
267, 211.03
471, 3192.87
676, 16255.15
Next, these values were converted to their linear form by applying the base-10 logarithm. This transformation allows the function to be expressed in a linear state: y = a * x − b. This step is essential for enabling linear regression on these values.
For the cycle peak (x,y) values:
2.053, 1.268
2.380, 3.002
2.654, 4.282
2.816, 4.816
And for the bear market low (x,y) values:
2.013, 0.394
2.427, 2.324
2.673, 3.504
2.830, 4.211
Next, linear regression was performed on both these datasets. (Numerous tools are available online for linear regression calculations, making manual computations unnecessary).
Linear regression is a method used to find a straight line that best represents the relationship between two variables. It looks at how changes in one variable affect another and tries to predict values based on that relationship.
The goal is to minimize the differences between the actual data points and the points predicted by the line. Essentially, it aims to optimize for the highest R-Square value.
Below are the results:
It is important to note that both the slope (a-value) and the y-intercept (b-value) have associated standard errors. These standard errors can be used to calculate confidence intervals by multiplying them by the t-values (two degrees of freedom) from the linear regression.
These t-values can be found in a t-distribution table. For the top cycle confidence intervals, we used t10% (0.133), t25% (0.323), and t33% (0.414). For the bottom cycle confidence intervals, the t-values used were t10% (0.133), t25% (0.323), t33% (0.414), t50% (0.765), and t67% (1.063).
The final bull cycle function is:
y = 10^(4.058 ± 0.133 * log10(x) – 6.44 ± 0.324)
The final bear cycle function is:
y = 10^(4.684 ± 0.025 * log10(x) – -9.034 ± 0.063)
The main Criticisms of growth curve models:
The Bitcoin logarithmic growth curve model faces several general criticisms that we’d like to highlight briefly. The most significant, in our view, is its heavy reliance on past price data, which may not accurately forecast future trends. For instance, previous growth curve models from 2020 on TradingView were overly optimistic in predicting the last cycle’s peak.
This is why we aimed to present our process for deriving the final functions in a transparent, step-by-step scientific manner, including statistical confidence intervals. It's important to note that the bull cycle function is less reliable than the bear cycle function, as the top band is significantly wider than the bottom band.
Even so, we still believe that the Bitcoin logarithmic growth curve presented in this script is overly optimistic since it goes parly against the concept of diminishing returns which we discussed in this post:
This is why we also propose alternative parameter settings that align more closely with the theory of diminishing returns.
Our recommendations:
Drawing on the concept of diminishing returns, we propose alternative settings for this model that we believe provide a more realistic forecast aligned with this theory. The adjusted parameters apply only to the top band: a-value: 3.637 ± 0.2343 and b-parameter: -5.369 ± 0.6264. However, please note that these values are highly subjective, and you should be aware of the model's limitations.
Conservative bull cycle model:
y = 10^(3.637 ± 0.2343 * log10(x) - 5.369 ± 0.6264)
Nifty Dashboard//@version=5
//Author @GODvMarkets
indicator("GOD NSE Nifty Dashboard", "Nifty Dashboard")
i_timeframe = input.timeframe("D", "Timeframe")
// if not timeframe.isdaily
// runtime.error("Please switch timeframe to Daily")
i_text_size = input.string(size.auto, "Text Size", )
//-----------------------Functions-----------------------------------------------------
f_oi_buildup(price_chg_, oi_chg_) =>
switch
price_chg_ > 0 and oi_chg_ > 0 =>
price_chg_ > 0 and oi_chg_ < 0 =>
price_chg_ < 0 and oi_chg_ > 0 =>
price_chg_ < 0 and oi_chg_ < 0 =>
=>
f_color(val_) => val_ > 0 ? color.green : val_ < 0 ? color.red : color.gray
f_bg_color(val_) => val_ > 0 ? color.new(color.green,80) : val_ < 0 ? color.new(color.red,80) : color.new(color.black,80)
f_bg_color_price(val_) =>
fg_color_ = f_color(val_)
abs_val_ = math.abs(val_)
transp_ = switch
abs_val_ > .03 => 40
abs_val_ > .02 => 50
abs_val_ > .01 => 60
=> 80
color.new(fg_color_, transp_)
f_bg_color_oi(val_) =>
fg_color_ = f_color(val_)
abs_val_ = math.abs(val_)
transp_ = switch
abs_val_ > .10 => 40
abs_val_ > .05 => 50
abs_val_ > .025 => 60
=> 80
color.new(fg_color_, transp_)
f_day_of_week(time_=time) =>
switch dayofweek(time_)
1 => "Sun"
2 => "Mon"
3 => "Tue"
4 => "Wed"
5 => "Thu"
6 => "Fri"
7 => "Sat"
//-------------------------------------------------------------------------------------
var table table_ = table.new(position.middle_center, 22, 20, border_width = 1)
var cols_ = 0
var text_color_ = color.white
var bg_color_ = color.rgb(1, 5, 19)
f_symbol(idx_, symbol_) =>
symbol_nse_ = "NSE" + ":" + symbol_
fut_cur_ = "NSE" + ":" + symbol_ + "1!"
fut_next_ = "NSE" + ":" + symbol_ + "2!"
= request.security(symbol_nse_, i_timeframe, [close, close-close , close/close -1, volume], ignore_invalid_symbol = true, lookahead = barmerge.lookahead_on)
= request.security(fut_cur_, i_timeframe, , ignore_invalid_symbol = true, lookahead = barmerge.lookahead_on)
= request.security(fut_next_, i_timeframe, , ignore_invalid_symbol = true, lookahead = barmerge.lookahead_on)
= request.security(fut_cur_ + "_OI", i_timeframe, [close, close-close ], ignore_invalid_symbol = true, lookahead = barmerge.lookahead_on)
= request.security(fut_next_ + "_OI", i_timeframe, [close, close-close ], ignore_invalid_symbol = true, lookahead = barmerge.lookahead_on)
stk_vol_ = stk_vol_nse_
fut_vol_ = fut_cur_vol_ + fut_next_vol_
fut_oi_ = fut_cur_oi_ + fut_next_oi_
fut_oi_chg_ = fut_cur_oi_chg_ + fut_next_oi_chg_
fut_oi_chg_pct_ = fut_oi_chg_ / fut_oi_
fut_stk_vol_x_ = fut_vol_ / stk_vol_
fut_vol_oi_action_ = fut_vol_ / math.abs(fut_oi_chg_)
= f_oi_buildup(chg_pct_, fut_oi_chg_pct_)
close_color_ = fut_cur_close_ > fut_vwap_ ? color.green : fut_cur_close_ < fut_vwap_ ? color.red : text_color_
if barstate.isfirst
row_ = 0, col_ = 0
table.cell(table_, col_, row_, "Symbol", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Close", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "VWAP", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Pts", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Stk Vol", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Fut Vol", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Fut/Stk Vol", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "OI Cur", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "OI Next", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "OI Cur Chg", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "OI Next Chg", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "COI ", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "COI Chg", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Vol/OI Chg", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "COI Chg%", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "Pr.Chg%", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
table.cell(table_, col_, row_, "OI Buildup", text_color = text_color_, bgcolor = bg_color_, text_size = i_text_size), col_ += 1
cell_color_ = color.white
cell_bg_color_ = color.rgb(1, 7, 24)
if barstate.islast
row_ = idx_, col_ = 0
table.cell(table_, col_, row_, str.format("{0}", symbol_), text_color = f_color(chg_pct_), bgcolor = f_bg_color_price(chg_pct_), text_size = i_text_size, text_halign = text.align_left), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#.00}", fut_cur_close_), text_color = close_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#.00}", fut_vwap_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,0.00}", chg_pts_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", stk_vol_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_vol_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,0.00}", fut_stk_vol_x_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_cur_oi_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_next_oi_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_cur_oi_chg_), text_color = f_color(fut_cur_oi_chg_), bgcolor = f_bg_color(fut_cur_oi_chg_), text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_next_oi_chg_), text_color = f_color(fut_next_oi_chg_), bgcolor = f_bg_color(fut_next_oi_chg_), text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_oi_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,#,###}", fut_oi_chg_), text_color = f_color(fut_oi_chg_), bgcolor = f_bg_color(fut_oi_chg_), text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,0.00}", fut_vol_oi_action_), text_color = cell_color_, bgcolor = cell_bg_color_, text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,0.00%}", fut_oi_chg_pct_), text_color = f_color(fut_oi_chg_pct_), bgcolor = f_bg_color_oi(fut_oi_chg_pct_), text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0,number,0.00%}", chg_pct_), text_color = f_color(chg_pct_), bgcolor = f_bg_color_price(chg_pct_), text_size = i_text_size, text_halign = text.align_right), col_ += 1
table.cell(table_, col_, row_, str.format("{0}", oi_buildup_), text_color = oi_buildup_color_, bgcolor = color.new(oi_buildup_color_,80), text_size = i_text_size, text_halign = text.align_left), col_ += 1
idx_ = 1
f_symbol(idx_, "BANKNIFTY"), idx_ += 1
f_symbol(idx_, "NIFTY"), idx_ += 1
f_symbol(idx_, "CNXFINANCE"), idx_ += 1
f_symbol(idx_, "RELIANCE"), idx_ += 1
f_symbol(idx_, "HDFC"), idx_ += 1
f_symbol(idx_, "ITC"), idx_ += 1
f_symbol(idx_, "HINDUNILVR"), idx_ += 1
f_symbol(idx_, "INFY"), idx_ += 1
Simplified Gap Strategy with SMA FilterThe Simplified Gap Strategy leverages price gaps as a trading signal, focusing on their significance in market behavior. Gaps occur when the opening price of a security differs significantly from the previous closing price, often signaling potential continuation or reversal patterns.
Key Features:
Gap Threshold:
This strategy requires a minimum percentage gap (defined by the user) to qualify for trading signals.
Directional Trading:
Users can select from various gap types, including "Long Up Gap" and "Short Down Gap," allowing for tailored trading approaches.
SMA Filter:
An optional Simple Moving Average (SMA) filter helps refine trade entries based on trend direction, increasing the probability of successful trades.
Hold Duration:
Positions can be held for a user-defined duration, providing flexibility in trade management.
Statistical Significance of Gaps:
Research has shown that gaps can provide insights into future price movements. According to studies such as those by Hutton and Jiang (2008), price gaps are often followed by momentum in the direction of the gap, indicating that they can serve as reliable indicators for traders. The "Gap Theory" suggests that gaps are filled approximately 90% of the time, emphasizing their relevance in market dynamics (Nikkinen, Sahlström, & Kinnunen, 2006).
Important Note:
This strategy is designed solely for statistical analysis and should not be construed as financial advice. Users are encouraged to conduct their own research and analysis before applying this strategy in live trading scenarios.
By understanding the underlying mechanisms of price gaps and their statistical significance, traders can enhance their decision-making processes and potentially improve trading outcomes.
References:
Hutton, A. W., & Jiang, W. (2008). "Price Gaps: A Guide to Trading Gaps."
Nikkinen, J., Sahlström, P., & Kinnunen, J. (2006). "The Gaps in Financial Markets: An Empirical Study."
This description provides an overview of the strategy while emphasizing its analytical purpose and backing it with relevant academic insights.
CANSLIM Screener [TrendX_]INTRODUCTION:
The CANSLIM investment strategy, developed by William J. O'Neil, is a powerful tool for identifying growth stocks that have the potential to outperform the market. TrendX has enhanced this approach with its unique indicators, making it easier for investors to assess stocks based on seven critical criteria.
➊ C: Current Quarterly EPS or PE with Growth Benchmark
The first criterion focuses on the Earnings Per Share (EPS) growth in the most recent quarter compared to previous quarters. A company should demonstrate significant EPS growth, ideally exceeding expectations and benchmarks within its industry.
➋ A: Average Annual EPS Growth with Growth Benchmark
This aspect evaluates a company's average annual EPS growth over the last three years. A consistent upward trend suggests that the company is effectively increasing its profitability. TrendX provides a customizable benchmark to help investors identify firms with sustainable growth trajectories.
➌ N: New Highs or New Product Development
TrendX interprets this criterion through an Annual Research & Development to Revenue Ratio (RNDR). A decreasing RNDR ratio may indicate that a company is finishing new products, which could lead to reduced revenue if product launches are unsuccessful.
➍ S: Supply and Demand
This component assesses supply and demand dynamics by analyzing the movement of Float Shares Outstanding. A decrease in float shares typically indicates higher demand for the stock, suggesting that the company is in good shape for future growth.
➎ L: Leader
TrendX employs comparative analysis between the Relative Strength Index (RSI) of a company and that of the overall market. If a company's RSI is higher than the market's, it signifies that the stock is leading rather than lagging.
➏ I: Institutional Sponsorship
Institutional sponsorship is gauged through the total dividends paid by a company. High dividend payouts can signal strong institutional interest, support and confidence in the company's future prospects.
➐ M: Market Direction
TrendX evaluates market direction by comparing a company's RSI against its Moving Average of RSI, along with utilizing Market Structure in Smart Money Concept indicator for alternative trend insights.
HOW TO USE
The TrendX CANSLIM indicator provides an evaluation score based on each of the seven criteria outlined above, which displays in a table containing:
Scoring System: Each letter in CANSLIM contributes to a total score out of 100%. A stock does not need to meet all seven criteria; achieving a score above 70% (5 out of 7) is generally considered indicative of a promising growth stock.
Screening Feature: The tool includes a screening feature that evaluates multiple stocks simultaneously, allowing investors to compare their CANSLIM scores efficiently. This feature streamlines identifying potential investment opportunities across various sectors.
DISCLAIMER
This indicator is not financial advice, it can only help traders make better decisions. There are many factors and uncertainties that can affect the outcome of any endeavor, and no one can guarantee or predict with certainty what will occur.
Therefore, one should always exercise caution and judgment when making decisions based on past performance.
ATR+StdTR Band and Trailing StopThis Pine Script code plots the "ATR+StdTR Band and Trailing Stop," serving as a tool for volatility-based risk management and trend detection. While bands are typically set using a multiple of ATR, this script uses StdTR (the True Range standard deviation) and sets the band width based on ±(ATR + n times StdTR). StdTR is a great tool for detecting price volatility and anomalies, allowing traders to adapt to rapid changes in extreme market conditions. This helps traders proactively manage risk during sudden market fluctuations.
The following features are provided:
Table Display
A table is shown on the chart, allowing traders to visually track the current ATR value, StdTR (σ), and the long/short stop-loss levels (±ATR ± nσ). This enables real-time monitoring of risk management data.
Band Plots
The script plots bands that combine ATR with StdTR (nσ).
The upper and lower bands are calculated using the previous candle’s closing price (the source is customizable) and are plotted as ±(ATR + nσ), providing a clear visual of the price range.
ATR ± nσ Trailing Stop
The trailing stop dynamically adjusts the stop-loss levels based on price movements. In an uptrend, the stop-loss rises, while in a downtrend, it lowers, helping traders lock in profits while minimizing losses during significant reversals.
Breakout Detection
Breakouts are detected when the price exceeds the upper band or drops below the lower band. A visual marker (X) is displayed on the chart, allowing traders to quickly recognize when the price has moved beyond normal volatility ranges, making it easier to respond to trend formations or reversals.
Customization Points:
The ATR period and StdTR (n) are fully customizable.
The source for ATR band calculation can be adjusted, allowing traders to choose from close, open, high, low, etc.
The table’s display position and design (text color, size, etc.) can be customized to present the information clearly and effectively.
Ultimate ZonesThe story is simple: I didn't find a support/resistance zones indicator that I actually liked, so I made my own.
Features:
Independent of the chart timeframe (zones don't change if you switch timeframes) - very important for practical use
Live mode (repainting) plus historic mode (non-repainting)
Selectable timeframe for zone calculation (default: daily)
Can adjust how far the indicator looks back into the past (default: 500 days)
Can adjust pivot period to find more or fewer zones
Zone heights are based on long-term ATR (to adapt to the asset's volatility automatically)
Price tolerance multiplier is adjustable
Option to merge zones which are close together into one ("fat zones")
I find that together these options (especially those in the "sensitivity" section) allow me to automatically generate almost all the zones I want to see. Occasionally, I do draw some additional zones to get the perfect image I'm looking for on the chart.
Explanation
We detect pivot points on the selected zone timeframe (taking pivot period and lookback limit into account). Then we combine these pivot points into a zone if they are close enough together in price (here the tolerance parameter comes into play). If "fat zones" is selected, we perform these merges more aggressively even if the resulting zone becomes taller than the standard tolerance.
The ATR used for the tolerance is a 500 period ATR, but if there are less than 500 bars available, we use the average of the bars available so far, so we always have a value to work with.
In order for a zone to be displayed, it must have been touched by at least 2 separate pivot points. We do not distinguish between pivot highs and pivot lows because support is known to turn into resistance and vice versa.
In live mode, we draw the currently active zones as boxes.
In historic mode, we plot the active zones at each bar using "plot" and "fill", so there is no repainting or erasing, and you can see which zones were active at any past date. For practical reasons, we draw a maximum of 15 zones around the current price (i.e. 7-8 zones above and 7-8 zones below the price).
Support and ResistanceThis indicator, titled "Support and Resistance," is designed to identify and display key price levels based on volume and pivot points. It's a versatile tool that can be adapted for different market views and timeframes.
Key Features
Market View Options
The indicator offers three market view settings:
Short term
Standard
Long term
These settings affect the lookback periods used in calculations, allowing users to adjust the indicator's sensitivity to market movements.
Volume-Based Levels
The indicator calculates support and resistance levels using a rolling Point of Control (POC) derived from volume data. This approach helps identify price levels where the most trading activity has occurred.
Pivot Points
In addition to volume-based levels, the indicator incorporates pivot points to identify potential support and resistance areas.
Customizable Appearance
Users can adjust:
Number of lines to display (1-8)
Colors for support and resistance levels
Line thickness based on level importance
Calculation Methods
Rolling POC
The indicator uses a custom function f_rolling_poc to calculate the rolling Point of Control. This function analyzes volume distribution across price levels within a specified lookback period.
Pivot Points
Both standard and quick pivot points are calculated using the rolling POC as input, rather than traditional price data.
Level Importance
The indicator assigns importance to each level based on:
Number of touches (how often price has interacted with the level)
Duration (how long the level has been relevant)
This importance score determines the thickness of the displayed lines.
Unique Aspects
Dynamic Line Thickness: Lines become thicker when levels overlap, highlighting potentially stronger support/resistance areas.
Adaptive Coloring: The color of each line changes dynamically based on whether the current price is above or below the level, indicating whether it's acting as support or resistance.
Flexible Time Frames: The market view options allow the indicator to be easily adapted for different trading styles and timeframes.
Potential Uses
This indicator could be valuable for:
Identifying key price levels for entry and exit points
Recognizing potential breakout or breakdown levels
Understanding the strength of support and resistance based on line thickness
Adapting analysis to different market conditions and timeframes
Overall, this "Support and Resistance" indicator offers a sophisticated approach to identifying key price levels, combining volume analysis with pivot points and providing visual cues for level importance and current market position.
This Support and Resistance indicator is provided for informational and educational purposes only. It should not be considered as financial advice or a recommendation to buy or sell any security. The indicator's calculations are based on historical data and may not accurately predict future market movements. Trading decisions should be made after thorough research and consultation with a licensed financial advisor. The creator of this indicator is not responsible for any losses incurred from its use. Past performance does not guarantee future results. Use at your own risk.
Streak-Based Trading StrategyThe strategy outlined in the provided script is a streak-based trading strategy that focuses on analyzing winning and losing streaks. It’s important to emphasize that this strategy is not intended for actual trading but rather for statistical analysis of streak series.
How the Strategy Works
1. Parameter Definition:
• Trade Direction: Users can choose between “Long” (buy) and “Short” (sell).
• Streak Threshold: Defines how many consecutive wins or losses are needed to trigger a trade.
• Hold Duration: Specifies how many periods the position will be held.
• Doji Threshold: Determines the sensitivity for Doji candles, which indicate market uncertainty.
2. Streak Calculation:
• The script identifies Doji candles and counts winning and losing streaks based on the closing price compared to the previous closing price.
• Streak counting occurs only when no position is currently held.
3. Trade Conditions:
• If the loss streak reaches the defined threshold and the trade direction is “Long,” a buy position is opened.
• If the win streak is met and the trade direction is “Short,” a sell position is opened.
• The position is held for the specified duration.
4. Visualization:
• Winning and losing streaks are plotted as histograms to facilitate analysis.
Scientific Basis
The concept of analyzing streaks in financial markets is well-documented in behavioral economics and finance. Studies have shown that markets often exhibit momentum and trend-following behavior, meaning the likelihood of consecutive winning or losing periods can be higher than what random statistics would suggest (see, for example, “The Behavior of Stock-Market Prices” by Eugene Fama).
Additionally, empirical research indicates that investors often make decisions based on psychological factors influenced by streaks. This can lead to irrational behavior, as they may focus on past wins or losses (see “Behavioral Finance: Psychology, Decision-Making, and Markets” by R. M. F. F. Thaler).
Overall, this strategy serves as a tool for statistical analysis of streak series, providing deeper insights into market behavior and trends rather than being directly used for trading decisions.
Balance of Power [SYNC & TRADE]Balance of Power
Overview
This indicator analyzes the balance of power between buyers and sellers in the market. It uses volume, price action and the relative strength index (RSI) to determine the strength of buyers and sellers, as well as to identify potential zones where one side dominates the other.
How it works
The indicator calculates the average volume over a specified period.
It determines the strength of each bar, taking into account volume and price action.
RSI is used as an additional factor to assess the strength of the trend.
Based on these factors, the "balance of power" between buyers and sellers is calculated.
When the balance of power exceeds a specified threshold, the indicator marks the beginning of the "buyer zone" or "seller zone".
How to use
Add the indicator to your chart in TradingView.
Configure the input parameters:
"Period for average volume": determines the sensitivity to volume changes.
"RSI period": affects the sensitivity of the RSI to price changes.
"Strength threshold": sets the level for determining a significant imbalance.
"Table Size": select the appropriate size of the information table.
Observe the signals on the chart:
Blue triangle up: the beginning of the buyer zone.
Red triangle down: the beginning of the seller zone.
Use the information table to get additional data:
Current balance of power
Buyers or sellers have strength
Current RSI value
Advantages
Comprehensive analysis of market conditions
Visual signals for potential entry points
Customizable parameters to adapt to different trading styles
Informative table for quick analysis of the current situation
Limitations
Like any indicator, it can give false signals
Requires additional analysis and confirmation with other tools
Efficiency may vary depending on market conditions
Recommendations
Use this indicator in combination with other analysis methods to make trading decisions. Experiment with the settings to optimize for your trading style and selected assets.
Balance of Power Ru
Обзор
Этот индикатор анализирует баланс сил между покупателями и продавцами на рынке. Он использует объем, ценовое движение и индекс относительной силы (RSI) для определения силы покупателей и продавцов, а также для выявления потенциальных зон, где одна сторона доминирует над другой.
Как это работает
Индикатор рассчитывает среднее значение объема за указанный период.
Он определяет силу каждого бара, учитывая объем и ценовое движение.
RSI используется как дополнительный фактор для оценки силы тренда.
На основе этих факторов вычисляется "баланс сил" между покупателями и продавцами.
Когда баланс сил превышает заданный порог, индикатор отмечает начало "зоны покупателей" или "зоны продавцов".
Как использовать
Добавьте индикатор на ваш график в TradingView.
Настройте входные параметры:
"Период для среднего объема": определяет чувствительность к изменениям объема.
"Период RSI": влияет на чувствительность RSI к ценовым изменениям.
"Порог силы": устанавливает уровень для определения значимого дисбаланса.
"Размер таблицы": выберите подходящий размер информационной таблицы.
Наблюдайте за сигналами на графике:
Синий треугольник вверх: начало зоны покупателей.
Красный треугольник вниз: начало зоны продавцов.
Используйте информационную таблицу для получения дополнительных данных:
Текущий баланс сил
Наличие силы у покупателей или продавцов
Текущее значение RSI
Преимущества
Комплексный анализ рыночных условий
Визуальные сигналы для потенциальных точек входа
Настраиваемые параметры для адаптации к разным торговым стилям
Информативная таблица для быстрого анализа текущей ситуации
Ограничения
Как и любой индикатор, может давать ложные сигналы
Требует дополнительного анализа и подтверждения другими инструментами
Эффективность может варьироваться в зависимости от рыночных условий
Рекомендации
Используйте этот индикатор в сочетании с другими методами анализа для принятия торговых решений. Экспериментируйте с настройками для оптимизации под ваш торговый стиль и выбранные активы.
Fibonacci Pivot | SyedFibonacci pivots combine Fibonacci retracement levels with pivot points to provide potential support and resistance levels. This tool is based on the idea that price tends to retrace a predictable portion of a move, after which it often continues in the original direction.
Here’s a breakdown of Fibonacci pivots:
1. Pivot Point (PP)
The central level that acts as the main reference point for support and resistance levels. It’s calculated as the average of the high, low, and close of the previous period (typically a day).
Formula:
𝑃
𝑃
=
(
𝐻
𝑖
𝑔
ℎ
+
𝐿
𝑜
𝑤
+
𝐶
𝑙
𝑜
𝑠
𝑒
)
3
PP=
3
(High+Low+Close)
2. Fibonacci-Based Support and Resistance Levels
These levels are derived by multiplying the range (High - Low) of the previous period with key Fibonacci ratios (23.6%, 38.2%, 61.8%, etc.), then adding or subtracting this result from the Pivot Point.
The Fibonacci ratios used in Fibonacci pivots are typically:
38.2%: A strong retracement level.
61.8%: The golden ratio, a key Fibonacci level that often acts as major support or resistance.
100%: Full retracement from the previous period's high or low.
Fibonacci Support Levels (S1, S2, S3, etc.)
These levels indicate potential areas where the price might find support:
S1 = PP - (Range * 0.382)
S2 = PP - (Range * 0.618)
S3 = PP - (Range * 1)
Fibonacci Resistance Levels (R1, R2, R3, etc.)
These are the areas where price might face resistance:
R1 = PP + (Range * 0.382)
R2 = PP + (Range * 0.618)
R3 = PP + (Range * 1)
Interpretation
R1/R2/R3: Potential resistance levels where price might face selling pressure.
S1/S2/S3: Potential support levels where price might encounter buying interest.
Pivot Point (PP): Acts as the primary level of interest. If the price is above the PP, it suggests bullish sentiment; if below, bearish sentiment.
Example