IU Support and Resistance How this script works :
1. This script is an indicator script which calculates the support and resistance based on pivot high and pivot low and plot them as zone onto the chart.
2. The first user input is minimum number of touches which indicates how many time pivot high or pivot low should be tested in order to be a valid support or resistance level.
3.The second user input "Set Buffer" check if the user wants to use a custom buffer or not if it's unchanged then the default is 50% of the 1000 period ATR value .
4. If "Set Buffer" is checked meaning if it's set to true then only the third user input will be execute which is the "buffer" which indicates how much price range user wants his zone to have.
5. After the user input part this script create two arrays to store the pivot high and pivot low values every time he have a new value.
6. This script also creates two arrays to store the bar index of the bar where the new pivot high or pivot low is detected those bar index will be later use while creating the support and resistance zones.
7. Then the script creates four more arrays to store the final support and resistance values and their respective bar index which will be use for creating the support and resistance zones.
8. After this the script check that we are at the last bar of our chart if we are then we sort the support and resistance indices by descending order and store them into an new variable after that we sort the support and resistance arrays by descending order, then we loop through the arrays elements and we check if the previous element comes under the zone of the current element if so we increase the "minimum touch" variable by 1, once we have 5 or more count in our variable and we no longer have a valid zone then we store the element value and the sorted index of the element into our final arrays.
9. Finally the script will loop through the final support and resistance arrays and it will create a box for each support and resistance with respect to extending it on both directions.
10.The green zones are the support and the red zones are the resistance.
How user can benifits from this script:
1. User can automatically identify support and resistance zones and he can plan his trade as per that.
2. User can test how different markets reacts with support and resistance zones.
3. User can plan breakout trade on the break of the support or resistance level.
4. User can adjust he stop loss and take profit as per the support and resistance zones.
Точки разворота и уровни
PKJ StrategyWelcome to the Daily Price Action Mastery Strategy, a powerful approach to navigating the financial markets using the purest form of market analysis – price action. This trading view strategy is meticulously crafted for those seeking a method that harnesses the daily price movements to make informed and strategic trading decisions.
Key Features:
Daily Candlestick Analysis: Dive into the daily candlestick patterns to identify key support and resistance levels, trend reversals, and potential breakout points. The strategy leverages the valuable information encapsulated in each day's price action to discern market sentiment.
Trend Identification: Utilize trend analysis tools and indicators to pinpoint the prevailing market direction. By understanding the dynamics of daily trends, traders can align their positions with the broader market movement for higher probability trades.
Dynamic Support and Resistance: Implement dynamic support and resistance levels derived from daily price action. These levels act as crucial markers for entry and exit points, helping traders set effective stop-loss and take-profit orders.
Chart Patterns Recognition: Uncover chart patterns such as head and shoulders, flags, and triangles on the daily timeframe. The strategy incorporates pattern recognition techniques to identify potential trend continuation or reversal scenarios, offering traders a comprehensive view of market dynamics.
Volatility Analysis: Gauge market volatility by studying daily price ranges and fluctuations. Volatility indicators are integrated to help traders adjust their risk management strategies in response to varying market conditions.
Confirmation through Indicators: Supplement price action analysis with carefully selected indicators for additional confirmation signals. These indicators are chosen to align with the philosophy of the Daily Price Action Mastery Strategy, enhancing the precision of trade entries and exits.
Risk Management Guidelines: Discover effective risk management practices tailored to the daily timeframe. Learn how to optimize position sizes, set appropriate stop-loss levels, and manage capital to ensure long-term success and sustainability in your trading journey.
Whether you are a seasoned trader or a newcomer to the markets, the Daily Price Action Mastery Strategy provides a comprehensive framework to navigate the complexities of daily price movements. Elevate your trading experience by incorporating this strategy into your analysis, and empower yourself to make well-informed decisions in the dynamic world of finance.
Swing IdentifierThe "Swing Identifier" is a custom Pine Script indicator designed for use in the TradingView platform. It serves to visually identify and mark swing highs and swing lows on a trading chart, which are key concepts in technical analysis. This script is comprehensive and customizable, making it a useful tool for traders looking to pinpoint potential trend reversals and support or resistance areas.
**Key Features of the 'Swing Identifier' Indicator:**
1. **Swing Range Input:**
- This input determines the number of bars to the left and right of the current bar that the script will examine to identify a swing high or low. A larger value will look for swings over a broader range, potentially identifying more significant swings but at the expense of sensitivity.
2. **Swing Strength Input:**
- The swing strength is set as a percentage and is used to filter out insignificant price movements. A swing high or low is only considered valid if the percentage change from the last swing is greater than this input value. This feature helps in avoiding false signals in sideways or less volatile markets.
3. **Use Wicks Option:**
- Users can choose whether to consider the wicks of the candles or just the closing prices in identifying swings. This feature adds flexibility, allowing the script to be tailored to different trading styles and strategies.
4. **Line Color Customization:**
- The color of the lines marking the swings can be customized, enhancing the visual appeal and readability of the chart.
**Operational Mechanics:**
1. **Identification of Swing Highs and Lows:**
- The script uses the `ta.pivothigh` and `ta.pivotlow` functions to identify swing highs and lows. Whether it uses the high/low of the candles or their closing prices is determined by the user's choice in the "Use Wicks" option.
2. **Drawing and Updating Lines:**
- When a new swing high or low is identified, and it meets the percentage change criteria from the previous swing, a line is drawn from the last swing low to the current high (or vice versa). If a new swing high (or low) is identified that is higher (or lower) than the previous one, the old line is deleted, and a new line is drawn.
3. **Swing Update Logic:**
- The script maintains a toggle mechanism to look alternatively for highs and lows. This ensures that it sequentially identifies a high and then a low (or vice versa), which aligns with how actual market swings behave.
**Usage in Trading:**
1. **Identifying Trend Reversals:**
- By marking swing highs and lows, the script helps traders identify potential trend reversals. A break of a swing low in an uptrend or a swing high in a downtrend could signal a change in the prevailing trend.
2. **Support and Resistance:**
- Swing highs and lows often act as levels of support and resistance. Traders can use these levels for setting entry or exit points, stop losses, and take profit orders.
3. **Customization for Strategy:**
- The customizable nature of the script allows traders to adjust the parameters according to their trading strategy, time frame, and asset volatility.
In summary, the "Swing Identifier" is a versatile and customizable tool that aids in visually identifying crucial price swing points, thereby assisting traders in making informed decisions based on technical analysis principles.
Algoflow's Levels PlotterAlgoflow's Levels Plotter - Indicator
Release Date: Jan. 15, 2024
Release version: v3 r1
Release notes date: Jan. 15, 2024
Overview
Parses user's input of levels to be plotted and labeled on the chart for NQ & ES futures
Features
Quick plotting of predetermined price levels.
- Type or copy from another source of values in a predetermined output format.
Supports separate line plotting for Weekly, OVN and RTH values
- Plot only Weekly, OVN or RTH levels, or all
- Configure colors separately for Inflection Points, Weekly, OVN & RTH levels
- Shift/place price labels separately to easily identify levels
User Impacts of Changes
Requires users to remove previous version and re-add indicator "Algoflow's Levels Plotter", then re-add values. Colors and shift values will need to be re-entered and/or reconfigured
Support
Questions, feedbacks, and requests are welcomed. Please feel free to use Comments or direct private message via TradingView.
Quick usage notes:
The indicator allows you to enter data for both ES & NQ at the same time. This is useful in single chart window/layout situations, like viewing on the phone. When you switch between futures, the data is already there.
If you leave the entries blank, nothing will be plotted. This is useful if you want to have separate charts for ES & NQ. So you can just enter only the relevant data of either.
As an indicator, input values are saved within it, until it is removed from the chart. Input for one chart will not update other charts of the same ticker, even in the same layout.
The easiest and quickest way to share the inputs across all charts and layouts is to use the Indicator Templates feature.
- After input values are entered (for both ES & NQ futures) via the indicator's Settings, select ""Save as Default"".
- Click on ""Indicator Templates"" (4 squares icon), and click on ""Save Indicator template...""
- Remove the previous version of the indicator in other charts.
- Click on ""Indicator Templates"" icon, and select the newly created template. Repeat this for other charts of the same futures ticker
The labels can be disabled in settings > Style tab. Use the Inputs tab to configure orientation (left or right of current bar on chart), and how much spacing from the current (in distance of bars)
Format example:
Primary directional inflection point: 1234
For Bulls: 1244.25, 1254, 1264.50
For Bears: 1224, 1214, 1204
Changes
v3 r1 - Fixed erroneous default values in Weekly input sections. Added options to en/disable display of each set (session) of levels. Default label text size to normal, from small.
- Jan 15, 2024
v2 r9 - Added support for USTEC & US500.
- Dec. 10, 2023
v2 r8 - Added configuration features for users to modify the labels' text colors and size. Simplified code further by moving inputs processing modules into a single user function.
- Oct. 31, 2023
v2 r7 - Added support for the micro NQ & ES. Modified to ignore string case in inputs
- Oct 18, 2023
v2 r4 - Added support of weekly lines and labels features. Began the process of optimizing/simplifying code
- Oct. 15, 2023
v2 r3 - Made Inflection Point levels' colors configurable
- Oct. 04, 2023
v2 r2 - Removed comments & debug codes from development build revision #518
- Oct. 04, 2023
v2 r1 - Released from development revision #518. Major rewrite to fix previous and overlapping plots of lines and labels.
- Oct. 04, 2023
v1 r2 - First release of indicator
- Oct. 02, 2023
Intraday Fibonacci Levels [Gorb]Welcome to the Intraday Fibonacci Levels indicator, a dynamic and customizable tool designed for traders who incorporate Fibonacci retracements and extensions into their technical analysis. This indicator focuses on intraday price action, allowing you to select a specific candle from any trading session and visualize crucial Fibonacci levels derived from its high and low prices.
Features:
Candle Selection for Fibonacci Analysis: Select any candle based on its time to plot Fibonacci levels, giving you control over the period of analysis.
Customizable .236 and .618 Fibonacci Levels: Plot and customize the .236 and .618 Fibonacci retracement and extension levels. Adjust color and line style for each level to fit your chart preferences.
User-Friendly Interface: Easy-to-use input fields for selecting the candle time and configuring Fibonacci settings. Intuitive toggle options to display or hide specific Fibonacci levels.
Dynamic Updating: The indicator updates in real-time as new price data is received, ensuring you have the latest Fibonacci levels on your chart.
Usage Case:
This indicator is ideal for day traders and technical analysts who utilize Fibonacci tools to identify potential support and resistance levels, trend reversals, or continuation patterns. Whether you are analyzing a high-impact news event candle or a significant pivot point in the trading day, this indicator helps bring clarity to your Fibonacci-based trading strategy.
Guidelines for Usage:
Use the indicator settings to select the candle time and configure your desired Fibonacci levels. You can choose any time you want, in order to use premarket candles you need to enable electronic hours on your chart to have levels plot from pre/post.
These auto plotted levels can act as pivot points or points of support and resistance for traders to make informed trading decisions near these levels. Analyze the plotted Fibonacci levels in conjunction with other technical indicators or price action patterns for informed trading decisions.
Conclusion:
This indicator is a versatile and essential tool for traders who rely on Fibonacci analysis as part of their trading arsenal. By offering the flexibility to analyze specific candles and customize Fibonacci levels, this indicator empowers you to make more informed trading decisions. Its user-friendly design and real-time updating capabilities ensure that you have access to accurate and relevant Fibonacci data at any moment of the trading day.
RISK DISCLAIMER
All content, tools, scripts & education provided by Monstanzer or Gorb Algo are for informational & educational purposes only. Trading is risk and most lose their money, past performance does not guarantee future results.
Key Levels | Flux Charts💎 GENERAL OVERVIEW
Introducing our new Key Levels indicator! This indicator allows you to see the key levels on the current chart such as previous day lows / highs, pre-market data, yesterday's close, today's open, pivot points, and much more! It's highly user-friendly with every line being individually customizable and having a wide range of text options.
Features of the new Key Levels indicator :
Today & Yesterday High, Low, Open & Close
Previous 3-10th Day Highs & Lows
Pre-Market Highs & Lows
Previous Month High & Low
High & Low Pivots
Combination Of Same Levels
Wide Customization Options
📌 HOW DOES IT WORK ?
Key levels are important areas in a chart where a significant reaction is expected. In this indicator, you can enable up to the previous 10 days highs and lows, yesterday's close / today's open, and the latest pivot points. Key levels generally act like support & resistance. Here are a few examples :
As shown, key levels play an important role determining the current trend and can be useful in identifying potential levels where the market will reverse or breakout.
🚩UNIQUENESS
1. More Key Levels
We believe that past key levels may be as important as current ones. Some of the key-levels indicators do not include them even though strong reactions can happen around them. Thus, our indicator let's you check up to 10 days backwards.
You can select the ones you think that are the most important and just enable them, making the indicator customizable to your liking.
2. Pre-Market Data
With assets that have pre-market data available, it's crucial to analyze it to have a better understanding of the market in regular trading hours. Our indicator will plot pre-market highs and lows, even if your chart is in the regular trading hours only mode. We believe this will be helpful with your analyzing process.
3. Combination
The indicator can dynamically combine same key levels, so you can have a clear look to the chart without lines & text colliding with each other. This would also help you determine stronger key levels as if a key level occured more than a time, it could be a sign that it's a stronger one. An example :
To summarize, using key levels is an essential skill while detecting zones where strong reactions are expected. This indicator provides up to 10 day's high and low levels, and all of them can be individually turned on / off. Traders that believe older key levels can be important and want to look at the whole picture may use this feature. Also for assets that have pre-market data available, the indicator provides pre-market levels as well. Besides all that, High & Low pivots will provide latest key levels so traders can use them in their decisions.
⚙️SETTINGS
1. General Configuration
You can enable / disable :
1. Today's High / Low / Open
2. Yesterday's High / Low / Close
3. 3th-10th Day High / Low
4. Pre-Market High / Low
5. Previous Month High / Low
You can also change the colors and switch their line styles between solid, dashed and dotted.
2. High & Low Pivots
Enabled -> Enable / Disable High & Low Pivots
Pivot Range -> The range used in the detection of pivot points. Larger values will result in less pivot points, while smaller values will provide more pivot points. This essentially determines how many bars to the right & left shouldn't exceed the pivot's high or low.
You can also change the text color and text size of the pivots from the settings.
3. Style settings
Text Offset -> How many bars of offset should the texts have to the right. Increase if text collides with bars while Align Labels option is set to "Right".
Extend Lines -> If enabled, lines will be extended infinitely to right & left. If disabled, all lines will be clamped in their timelines.
Show Line Values -> If enabled, line information text will contain their price.
Align Labels ->
Right = Align line labels to right.
Center = Line labels will always be at the center of the screen.
DominancesIndicator allows to observe market via different types of Dominations: BTC, ETH, Altcoins and Stablecoins. Moreover, if you'll open altcoin on the main chart it will display dominance for it as well (so you can turn off other dominances in the settings, so it see only dominance of the opened token)
Please, we aware that not all of the coins in the market allows to observe their dominations. So don't be afraid if error will be displayed, just open other token and everything will be all right again.
CANDLE LEVELS [PRO]This indicator provides you with 55 levels! with labels to help you identify quickly where current price is in relation to the OPEN, CLOSE, HIGH OF DAY and LOW OF DAY to a respective level. Choose from levels as low as the 5 minute time frame all the way up to 200 days. All of the levels except the day's OPEN, HIGH OF DAY AND LOW OF DAY use the PREVIOUS time frame's level. In other words, when you're looking at the "1 DAY HIGH", that's actually the previous day's HIGH OF DAY. Whether you're a scalper on the lower time frames or a swing trader that mainly uses the 1 hour and above, these candle levels can be an invaluable source of support and resistance; in other words you'll often see price bounce off of a level (whether price is increasing or decreasing) once or multiple times and that could be an indication of a price's direction. Another way that you could utilize this indicator is to use it in confluence with other popular signals, such as an EMA crossover. For instance, you could watch as price rises above the 21 EMA all the while price is also crossing up and over the previous day's HIGH OF DAY with a relative volume that's double that of the previous week's average. These are just a few of some potential bullish signals that you could look for to go long on a trade using the candle levels provided.
I've made this indicator extremely customizable:
⚡Each level has 2 labels: 1 "at level" and 1 "at right", each label and price can be disabled
⚡Each label has its own input for label padding. The "at right" label padding input allows you to zoom in and out of a chart without the labels moving along their respective axis
⚡Each label's text can be customized via an "input.string" code base
⚡Each level's label can be changed via a plot style setting to determine if the label is centered with it's respective level or rides along the top of it
⚡Significant figures input allows you to round price up or down
⚡A "bias EMA" tool that color codes the candles and price line to show you where price is in relation to the 21 EMA (or another value that you pick). As a result, this can be an effective visual to help reduce cognitive load
⚡A "fill level" where color is determined by price opening above or below the previous day's close
⚡A "use current close" setting that's great to use in pre-market as it shows you where price is in relation to the previous days' close
----------------------------------------------------------------------------------------------------------------------
🙏Thanks to (c)satymahajan for the inspiration behind the ATR "previous close" and "bias candle" code base
🙏Thanks to my mentor (c)SimpleCryptoLife for the libraries and extensive code to help create this indicator
VWAP LEVELS [PRO]32 VWAP levels with labels and a table to help you identify quickly where current price is in relation to your favorite VWAP pivot levels. To help reduce cognitive load, 4 colors are used to show you where price is in relation to a VWAP level as well as the strength of that respective level. Ultimately, VWAP can be an invaluable source of support and resistance; in other words you'll often see price bounce off of a level (whether price is increasing or decreasing) once or multiple times and that could be an indication of a price's direction. Another way that you could utilize this indicator is to use it in confluence with other popular signals, such as an EMA crossover. Many traders will wait till a bar's close on the 5m or 10m time frame above a VWAP level (developing 1D VWAP would be a popular choice) before making a decision on a potential trade especially if price is rising above the 1D VWAP *and* there's been a recent 100 EMA cross UP of the 200 EMA. These are 2 bullish signals that you could look for before possibly entering in to a trade.
I've made this indicator extremely customizable:
⚡Each VWAP level has 2 labels: 1 "at level" and 1 "at right", each label and price can be disabled
⚡Each VWAP label has its own input for label padding. The "at right" label padding input allows you to zoom in and out of a chart without the labels moving along their respective axis. However, the "at level" label padding input doesn't work the same way once you move the label out of the "0" input. The label will move slightly when you zoom in and out
⚡Both "current" and "previous" VWAP levels have their own plot style that can be changed from circles, crosses and lines
⚡Significant figures input allows you to round a price up or down
⚡A price line that allows you to identify where price is in relation to a VWAP level
⚡A table that's color coded the same way as the labels. The labels and table cells change to 1 of 4 colors when "OC Check Mode" is enabled. This theory examines if the VWAP from the Open is above or below the VWAP from Close and if price is above or below normal VWAP (HLC3). This way we have 4 states:
Red = Strong Downtrend
Light Red = Weak Downtrend
Light = Weak Uptrend
Green = Strong Uptrend
Something to keep in mind: At the start of a new year, week or month, some levels will converge and they'll eventually diverge slowly or quickly depending on the level and/or time frame. You could add a few labels "at level" to show which levels are converging at the time. Since we're at the beginning of a new year, you'll see current month, 2 month, 3 month etc converge in to one level.
🙏Thanks to (c)MartinWeb for the inspiration behind this indicator.
🙏Thanks to (c)SimpleCryptoLife for the libraries and code to help create the labels.
SandTigerSandTiger is an auto-counting tool that counts naturally occurring events in a price series. This version has been reduced to 377 lines of code and should run faster than previous versions. Although not shown here, I highly recommend running my 'ELB' script with SandTiger. ELB is an 'event locator' and will mark all points that SandTiger numbers - giving you visual cues as to where these points are located. ELB also displays support/resistance levels.
SandTiger is designed to be used with MAGENTA - a counting system for Forex and other markets.
MAGENTA is a free and open framework for understanding and explaining price movement in financial markets. Any materials associated with MAGENTA are strictly for educational purposes only.
SandTiger tracks Component Values, Dyads, and Sum Table Values (STV's) over straight and curved trends, allowing a trader to discern where directional shifts are likely to occur.
SandTiger requires just 3 things to function accurately:
1) A correct starting point (this will typically be an obvious trend turn high or low in a series of price moves).
2) A 'push 1' count ('push 1' runs from the starting point to the event prior to the first terminal of the first FCT or Fractured Counter-Trend).
3) A 'high prime' value (the high prime count runs from the starting point through to the second terminal of the first FCT with no skips).
FRAMEWORK OVERVIEW: 'Component' values are filtered from the prime set (including the half prime and further reductions). Once we have the comp table we add the values to get a 'total'. With the 'total' we divide and multiply by two to get two additional values. 'Derivatives' are based on various calculations using these three values.
We're looking for 'total/2' to count into either itself, 'total', 'total*2', or a derivative. Comp counts are in Tx form and counted from trend start. If the trend doesn't turn on a comp value it will likely turn on a Dyad or STV value. If that also doesn't happen it's likely you have a 'curved' trend/sequence that will turn on one of the above after moving away from its high/low. This can also be traded using SandTiger's 'Seg Terminals' skip option.
Sum tables and Dyad values are drawn from the 'primes' and Dyads use the 'push1' value as well. In a structural trend, primes are gotten by counting pushpulls 1 & 2 in 'Ti' form. Comps, Sum table values, and Dyads are equivalent, sequences can turn on either value type belonging to the 1st or 2nd prime set. Both STV's and Dyads are counted in 'Tx' form (except where count-through signals occur).
Types and antitypes correlate and are associated with a 12-count 'cycle.' (Ti = 'Terminals Included'; Tx = 'Terminals eXcluded'; both refer to FCT terminals)
THE STRATEGY:
For Structures: Trade Comps, Dyads, and STV's from sets 1 (all) and 2 (Dyads and STV's only) in the 'main' segment then on the 'carry-over' by skipping segment terminals. If a PC or cycle caps the sequence, trade that as well.
For NSM's: Trade movements that flash a signal prior to the end of the initial cycle. The mark will be the push1 value. Twelve will be the 'high prime.' Skip interrupts and trade carry-over values.
The first version of SandTiger was conceived/planned/authored by Erek A.D. and coded by Erek A.D. and @SimpleCryptoLife beginning in August 2022 and finishing in Dec. 2022
The current version was written and developed July 3, 2023 and has been refined and upgraded by Erek A.D. through Jan. 2024...
Pivot Percentile Trend - Strategy [presentTrading]
█ Introduction and How it is Different
The "Pivot Percentile Trend - Strategy" from PresentTrading represents a paradigm shift in technical trading strategies. What sets this strategy apart is its innovative use of pivot percentiles, a method that goes beyond traditional indicator-based analyses. Unlike standard strategies that might depend on single-dimensional signals, this approach takes a multi-layered view of market movements, blending percentile calculations with SuperTrend indicators for a more nuanced and dynamic market analysis.
This strategy stands out for its ability to process multiple data points across various timeframes and pivot lengths, thereby capturing a broader and more detailed picture of market trends. It's not just about following the price; it's about understanding its position in the context of recent historical highs and lows, offering a more profound insight into potential market movements.
BTC 6h L/S
Where traditional methods might react to market changes, the Pivot Percentile Trend strategy anticipates them, using a calculated approach to identify trend strengths and weaknesses. This foresight gives traders a significant advantage, allowing for more strategic decision-making and potentially increasing the chances of successful trades.
In essence, this strategy introduces a more comprehensive and proactive approach to trading, harnessing the power of advanced percentile calculations combined with the robustness of SuperTrend indicators. It's a strategy designed for traders who seek a deeper understanding of market dynamics and a more calculated approach to their trading decisions.
Local picture
█ Strategy, How It Works: Detailed Explanation
🔶 Percentile Calculations
- The strategy employs percentile calculations to assess the relative position of current market prices against historical data.
- For a set of lengths (e.g., `length * 1`, `length * 2`, up to `length * 7`), it calculates the 75th percentile for high values (`percentilesHigh`) and the 25th percentile for low values (`percentilesLow`).
- These percentiles provide a sense of where the current price stands compared to recent price ranges.
Length - 10
Length - 15
🔶 SuperTrend Indicator
- The SuperTrend indicator is a key component, providing trend direction signals.
- It uses the `currentTrendValue`, derived from the difference between bull and bear strengths calculated from the percentile data.
* used the Supertrend toolkit by @EliCobra
🔶 Trend Strength Counts
- The strategy calculates counts of bullish and bearish indicators based on comparisons between the current high and low against high and low percentiles.
- `countBull` and `countBear` track the number of times the current high is above the high percentiles and the current low is below the low percentiles, respectively.
- Weak bullish (`weakBullCount`) and bearish (`weakBearCount`) counts are also determined by how often the current lows and highs fall within the percentile range.
*The idea of this strength counts mainly comes from 'Trend Strength Over Time' @federalTacos5392b
🔶 Trend Value Calculation
- The `currentTrendValue` is a crucial metric, computed as `bullStrength - bearStrength`.
- It indicates the market's trend direction, where a positive value suggests a bullish trend and a negative value indicates a bearish trend.
🔶 Trade Entry and Exit Logic
- The entry points for trades are determined by the combination of the trend value and the direction indicated by the SuperTrend indicator.
- For a long entry (`shouldEnterLong`), the `currentTrendValue` must be positive and the SuperTrend indicator should show a downtrend.
- Conversely, for a short entry (`shouldEnterShort`), the `currentTrendValue` should be negative with the SuperTrend indicating an uptrend.
- The strategy closes positions when these conditions reverse.
█ Trade Direction
The strategy is versatile, allowing traders to choose their preferred trading direction: long, short, or both. This flexibility enables traders to tailor their strategies to their market outlook and risk appetite.
█ Default Settings and Customization
1. Trade Direction: Selectable as Long, Short, or Both, affecting the type of trades executed.
2. Indicator Source: Pivot Percentile Calculations, key for identifying market trends and reversals.
3. Lengths for Percentile Calculation: Various configurable lengths, influencing the scope of trend analysis.
4. SuperTrend Settings: ATR Length 20, Multiplier 18, affecting indicator sensitivity and trend detection.
5. Style Options: Custom colors for bullish (green) and bearish (red) trends, aiding visual interpretation.
6. Additional Settings: Includes contrarian signals and UI enhancements, offering strategic and visual flexibility.
Threshold counterOVERVIEW
The "Threshold Counter" is a tool for quantifying occurrences of closing prices of an asset that align with specified criteria and is a flexible and visual approach to studying price action.
A user-definable target threshold can be set and a comparator (<, =, >, and so on) can be selected. The indicator counts values on the main chart meeting these conditions, over a user-defined `lookback` period.
KEY FEATURES
User definable threshold: target value with optional upper bound can be specified
Versatile Comparisons: Choose from "=", ">=", ">", "<=", "<", "between", and "between (inclusive)" for diverse analysis.
Historical Analysis: Assess occurrences over a customisable period.
Visual Representation: Displays instances graphically on the chart with customisable colours.
Summary: Provides a summary label for a quick understanding of the analysed data.
USE-CASES
Pattern Recognition: Identify patterns or trends based on user-defined price criteria.
Threshold Analysis: Quantify occurrences of prices crossing or staying within a specified range.
Strategy Testing: Evaluate historical performance of strategies relying on specific price conditions.
Behavioural Insights: Gain insights into price behaviour by counting occurrences of interest.
The "Threshold Counter" indicator offers a flexible and visual approach to studying price action, which may aid in making decisions based on historical data.
IMPORTANT CONSIDERATIONS
Period selection: The effectiveness of the analysis may be influenced by the choice of the lookback period. Consider an appropriate duration based on the strategy or pattern being analysed.
Comparator Selection: Comparison operator selection will obviously affect the results. There are two range operators of `between` and `between (inclusive)`. The latter will add closing prices that exactly meet the threshold and upper bound. The former does not.
Visualisation: Interpretation of the visual representation is colour-coded.
Red is threshold condition is not met.
Green is threshold condition is met.
Aqua is outside of the lookback period.
User Discretion: This script relies on historical data and should be used with caution. Past performance is not indicative of future results.
Supplementary Analysis: Trading decisions should not rely solely on this script. Users should exercise judgment and consider market conditions.
2bandHello traders
In this script, I have defined two bands with a deviation of 2 and 3
I designed the setup so that the upper lines represent red resistance, the lower lines represent green support, and the blue line represents the average price of the previous 20 candles in each time frame.
This code can be used mostly in time frames above 30 minutes and somehow predict possible price targets.
For example, if the price closes above the blue line in the one-hour time frame, the two fixed lines above are considered as targets and vice versa.
I have also added the pivot point calculation formula in orange
Most importantly, I added the closing price of the previous days in black
I hope it will be used by dear traders and you will support more for new works.
Consolidation FilterDescription:
Consolidation is a technical analysis term used to describe a assets's price movement within a given support and resistance range for a period of time. Consolidations happen either during trending market phases or before a new trend. Consolidation is generally interpreted as market indecisiveness and uncertainty as to which way the market will go next caused due to trader indecisiveness, which ends when the asset's price moves above or below the trading level. A consolidation level could be broken for several reasons, such as the release of materially important news or the triggering of a succession of limit orders.
Markets spend a great amount of time ranging and going sideways. It pays off to know how to identify and trade consolidations because they happen so frequently.
Periods of consolidation can be found in price charts for any time interval, and these periods can last for days, weeks, or months. Technical traders look for support and resistance levels in price charts and then use these levels to make buy and sell decisions. Typically, traders look for certain consolidation patterns: sideways ranges, downward or upward sloping ranges (also called flags), or triangular consolidations (triangles, wedges and pennants).
In contrast, this script offers an alternative, fairly straightforward but effective, way to pinpoint consolidation periods using a forecast oscillator method and simply highlighting relevant regions in the chart (with a yellow background).
In the settings menu you can select one of the three calculation methods, but all of them are based on the forecast oscillator. The indicator settings depend on the asset and on the timeframe. For example for the 2H timeframe BTSUSD preferred settings are period:10/method:2/threshold:0.2, and for the 15M timeframe BTSUSD the settings are period:10/method:2/threshold:0.02. Feel free to experiment with settings to suit your needs.
Fair Value Gap Finder with Integrated Gann BoxTitle: Fair Value Gap Finder with Integrated Gann Box Analysis
Description:
The "Fair Value Gap Finder with Integrated Gann Box Analysis" is a unique technical indicator designed for traders who wish to incorporate the concepts of Fair Value Gaps (FVG) and Gann Box methodologies into their trading strategy. This tool is beneficial for both trend-following and scalping techniques across various markets and timeframes.
Functionality:
The indicator identifies Fair Value Gaps, which are areas on the chart where price has skipped a range, creating a 'gap'. Recognizing these zones can be crucial for understanding potential price support and resistance areas. Alongside FVG detection, this script employs Gann Box principles to project potential levels of interest. Gann Boxes are drawn automatically when an FVG is identified, providing additional insights based on W.D. Gann's theories, which relate to time and price symmetry.
Usage:
Upon detecting an FVG, the indicator will highlight the gap on the chart and overlay a Gann Box between the high and low points of the gap. Traders can use these zones to make informed decisions about entry and exit points, stop loss, and take profit levels. The script offers customization options for the appearance and behavior of the FVG boxes and Gann Lines, allowing users to adapt the tool to their preferences.
Originality:
What sets this indicator apart is the integration of FVG with Gann Box levels within a single tool, streamlining the analysis process. It takes the classic approach of identifying gaps and enriches it with the geometric significance of Gann's work, all while allowing users to visualize and interact with these levels in a user-friendly manner.
Open-Source Nature:
This script is open-source, making it a transparent solution for those who wish to understand the underlying calculations. While not all traders are versed in Pine Script, the logic of identifying FVGs and applying Gann Box levels is explained through the script's annotations and the user interface itself.
Instructions for Use:
Apply the script to your chart, and it will automatically detect FVGs.
Adjust the settings in the indicator's input menu to match your trading style and preferences.
Use the FVG and Gann Box levels as potential areas of interest for trade setups.
This script does not guarantee profits and should be used as part of a comprehensive trading plan. It is best used in conjunction with other analysis methods to confirm signals and strategies.
PercenageDropFromATHINFO:
The PercenageDropFromATH script is fairly simple indicator, which is able to:
detect the last ATH (real ATH of the full chart, not related to the selected timeframe) and plot it
user can select a percentage of drop from this price, and once reached can receive a notification
Note that if the ATH is outside of the visibility of the currently selected timeframe the indicator will not be able to show it. Recommended settings is 1D TF!
DETAILS:
The purpose of the script is to serve to ease passive investments in ETFs and indices, once those are dropping below certain point from the ATH.
Individual stocks are not really recommended in my view, as unlike the indices which are cherry picking the best companies from the sector, individual companies can always start drifting away.
Anyway, the indicator should work on all assets, including crypto, gold, etc.
Example usage could be of setting an alert for 25% drop in SPY, and start accumulating positions on every next 10% additional drop, so DCA can be done with favorable prices.
SETTINGS
The settings are pretty straight forward:
ATH Source - source for computing the ATH, default to "high", but user can select to check only on open/close/low as well
Percentage drop target from ATH - self explaining, default to 20
ATH color - only the last ATH until the current bar is been drawn
Plot ATH drop target price - optionally the target price after the percentage drop can be plotted as well
ATH drop target color - the color of the price after the percentage drop from ATH
BreakoutTrendFollowingINFO:
The "BreakoutTrendFollowing" indicator is a comprehensive trading system designed for trend-following in various market environments. It combines multiple technical indicators, including Moving Averages (MA), MACD, and RSI,
along with volume analysis and breakout detection from consolidation, to identify potential entry points in trending markets. This strategy is particularly effective for assets that exhibit strong trends and significant price movements.
Note that using the consolidation filter reduces the amount of entries the strategy detects significantly, and needs to be used if we want to have an increased confidence in the trend via breakout.
However, the strategy can be easily transformed to various only trend-following strategies, by applying different filters and configurations.
The indicator can be used to connect to the Signal input of the TTS (TempalteTradingStrategy) by jason5480 in order to backtest it, thus effectively turning it into a strategy (instructions below in TTS CONNECTIVITY section)
DETAILS:
The strategy's core is built upon several key components:
Moving Average (MA): Used to determine the general trend direction. The strategy checks if the price is above the selected MA type and length.
MACD Filter: Analyzes the relationship between two moving averages to confirm the trend's momentum.
Consolidation Detection: Identifies periods of price consolidation and triggers trades on breakouts from these ranges.
Volume Analysis: Assesses trading volume to confirm the strength and validity of the breakout.
RSI: Used to avoid overbought conditions, ensuring trades are entered in favorable market situations.
Wick filters: make sure there is not a long wick that indicates selling pressure from above
The strategy generates buy signals when several conditions are met concurrently (each one of them can be individually enabled/disabled)"
The price is above the selected MA.
A breakout occurs from a configurable consolidation range.
The MACD line is above the signal line, indicating bullish momentum.
The RSI is below the overbought threshold.
There's an increase in trading volume, confirming the breakout's strength.
Currently the strategy fires SL signals, as the approach is to check for loss of momentum - i.e. crossunder of the MACD line and signal line, but that is to everyone to determine the exit conditions.
The buy and SL signals are set on the chart using green or orange triangles on the below/above the price action.
SETTINGS:
Users can customize various parameters, including MA type and period, MACD settings, consolidation length, and volume increase percentage. The strategy is equipped with alert conditions for both entry (buy signals) and exit (set stop loss) points, facilitating both manual and automated trading.
Each one of the technical indicators, as well as the consilidation range and breakout/wick settings can be configured and enabled/disabled individually.
Please thoroughly review the available settings of the script, but here is an outline of the most important ones:
Use bar wicks (instead of open/close) - the ref_high/low will be taken based on the bar wicks, rather than the open/close when determining the breakout and MA
Enter position only on green candles - additional filters to make sure that we enter only on strong momentum
MA Filter: (enable, source, type, length) - general settings for MA filter to be checked against the stock price (close or upper wick)
MACD Filter: (enable, source, Osc MA type, Signal MA type, Fast MA length, Slow MA length, Low MACD Hist) - detailed settings for fine MACD tuning
Consolidation:
Consolidation Type: we have two different ways of detecting the consolidation, note the types below.
CONSOLIDATION_BASIC - consolidation areas by looking for the pivot point of a trend and counts the number of bars that have not broken the consolidation high/low levels.
CONSOLIDATIO_RANGE_PERCENT - identifies consolidation by comparing the range between the highest and lowest price points over a specified period.
So in summary the CONSOLIDATIO_RANGE_PERCENT uses a percentage-based range to define consolidation, while CONSOLIDATION_BASIC uses a count of bars within a high-low range to establish consolidation.
Thus the former is more focused on the tightness of the price range, whereas the latter emphasizes the duration of the consolidation phase.
The CONSOLIDATIO_RANGE_PERCENT might be more sensitive to recent price movements and suitable for shorter-term analysis, while CONSOLIDATION_BASIC could be better for identifying longer-term consolidation patterns.
Min consolidation length - applicable for CONSOLIDATION_BASIC case, the min number of bars for the price to be in the range to consider consolidation
Consolidation Loopback period - applicable for CONSOLIDATION_BASIC case, the loopback number of bars to look for consolidation
Consolidation Range percent - applicable for CONSOLIDATIO_RANGE_PERCENT, the percent between the high and low in the range to consider consolidation
Plot consolidation - enables plotting of the consolidation (only for debug purposes)
Breakout: (enable, low, high) - the definition of the breakout from the previous consolidation range, the price should be between to determine the breakout as successfull
Upper wick: (enable, percent) - defines the percent of the upper wick compared to the whole candle to allow breakout (if the wick is too big part of the candle we can consider entering the position riskier)
RSI: (enable, length, overbought) - general settings for RSI TA
Volume (enbale, percentage increase, average volume filter en, loopback bars) - percentage of increase of the volume to consider for a breakout. There are two modes - percentage increase compared to the previous bar, or percentage against the average volume for the last loopback bars.
Note that there are many different configuration that you can play with, and I believe this is the strength of the strategy, as it can provide a single solution for different cases and scenarios.
My advice is to try and play with the different options for different markets based on the approach you want to implement and try turning features on/off and tuning them further.
TTS SETTINGS (NEEDED IF USED TO BACKTEST WITH TTS):
The TempalteTradingStrategy is a strategy script developed in Pine by jason5480, which I recommend for quick turn-around of testing different ideas on a proven and tested framework
I cannot give enough credit to the developer for the efforts put in building of the infrastructure, so I advice everyone that wants to use it first to get familiar with the concept and by checking
by checking jason5480's profile www.tradingview.com
The TTS itself is extremely functional and have a lot of properties, so its functionality is beyond the scope of the current script -
Again, I strongly recommend to be thoroughly explored by everyone that plans on using it.
In the nutshell it is a script that can be feed with buy/sell signals from an external indicator script and based on many configuration options it can determine how to execute the trades.
The TTS has many settings that can be applied, so below I will cover only the ones that differ from the default ones, at least according to my testing - do your own research, you may find something even better :)
The current/latest version that I've been using as of writing and testing this script is TTSv48
Settings which differ from the default ones:
Deal Conditions Mode - External (take enter/exit conditions from an external script)
🔌Signal 🛈➡ - BreakoutTrendFollowing: 🔌Signal to TTS (this is the output from the indicator script, according to the TTS convention)
Order Type - STOP (perform stop order)
Distance Method - HHLL (HigherHighLowerLow - in order to set the SL according to the strategy definition from above)
The next are just personal preferences, you can feel free to experiment according to your trading style
Take Profit Targets - 0 (either 100% in or out, no incremental stepping in or out of positions)
Dist Mul|Len Long/Short- 10 (make sure that we don't close on profitable trades by any reason)
Quantity Method - EQUITY (personal backtesting preference is to consider each backtest as a separate portfolio, so determine the position size by 100% of the allocated equity size)
Equity % - 100 (note above)
Tennis Ball ActionInspired by Mark Minervini's sell rules in "Think and Trade Like a Champion".
Used to determine if a stock is behaving well after a breakout
Used to determine when it might by prudent to reduce a position or sell
Used as a visual aid, but based purely off price and volume action
Here's a breakdown of what each condition checks for:
Up Close Counter: Checks for a sequence of upward closes. If there are 12 or more up closes in the last 15 days, it flags up_days as true.
Upper 50% Range Condition: Determines if 9 or more out of the last 15 closes are in the upper 50% of the price range.
Bullish Engulfing: Identifies a bullish engulfing candlestick pattern where the close is higher than the previous high and the open is lower than the previous low.
Stock Up 3% or More: Flags when the stock is up 3% or more on the day.
Inside Day Condition: Checks if the current day's high is lower than the previous day's high and the current day's low is higher than the previous day's low.
Close Below 50-day SMA: Indicates a negative confirmation when the stock closes below the 50-day Simple Moving Average (SMA).
Weak Close Condition: Similar to the Upper 50% Range Condition, but looking for lower closes.
Close Below 20-day SMA: Another negative confirmation when the stock closes below the 20-day SMA.
Three Lower Lows: Identifies a pattern where the current close is lower than the previous two closes.
Down on Above Average Volume: Flags when the stock closes lower than the previous day's close and the volume is higher than the 20-day SMA of volume.
The script then tallies up the confirmations and violations based on these conditions and plots them on a histogram. Confirmations are represented in green, violations in red.
This indicator evaluates both bullish and bearish signals based on various technical conditions to assist traders in decision-making. The confirmations suggest potential bullish movements, while violations indicate potential bearish movements in the stock.
Support and Resistance (MTF) | Flux Charts💎 GENERAL OVERVIEW
Introducing a groundbreaking support and resistance indicator designed to revolutionize your trading experience on TradingView! This innovative tool operates across three distinct timeframes, offering a comprehensive view of market dynamics to help you make informed trading decisions.
The indicator offers a large variety of features :
Select Up To 3 Timeframes
Select Strength Of Supports & Resistances
Select Between Zones & Lines
Show Breaks & Restests
Break & Retest Alerts
Avoid False Breaks
Inverse Color After Broken
Expand Lines & Zones
🚩UNIQUENESS
What sets this indicator apart is its ability to seamlessly integrate and analyze support and resistance levels across multiple timeframes simultaneously. By combining data from three different timeframes, this indicator provides a holistic perspective on market trends and key levels. The adaptive nature of this tool ensures a dynamic assessment of support and resistance zones, empowering traders to adapt to changing market conditions efficiently.
⚙️SETTINGS
1. General Configration
Support & Resistance Count -> Select between 1-3 support & resistance zones for each timeframe.
Pivot Range -> The pivot range is taken into calculations when finding high & low pivots in the chart. Increase if you need a more general look at the support & support zones, or decrease if you need a more detailed look.
Strength -> The strength of the support & resistance zones are determined by how many times the price touched the zone in the past. You can increase the strength up to 4.
Expand Lines & Zones -> If enabled, the support & resistance zones will be expanded to both left and right infinitely. If disabled, the support & resistance zones will be clamped between the time they are first seen, and the time they become broken.
2. Support & Resistance Zones
Enable Zones -> The support & resitsance lines will be converted to zones if enabled.
Zone Width -> The width of the zones. 1 -> %0.05, 2 -> %0.06, 3 -> %0.075.
3. Timeframes
Enable & Disable up to 3 different timeframes using the checkboxes. You can set the timeframes using the selectboxes.
4. Breaks & Retests
Show Breaks -> Points the break points with a blue label with the text "B" on it.
Show Retests -> Points the times when the support & resistance zones are being retested in the current chart.
Avoid False Breaks -> If enabled, the algorithm will try to avoid false break points by comparing the average volume of the point to a longer average volume.
Break Volume Threshold % -> If "Avoid False Breaks" option is enabled, the average volume of the break point should surpass the general average volume by this percent. Higher values mean it's less likely to be a break.
Inverse Color After Broken -> As broken support & resistance zones often become resistance & support zones respectively, if you enable this option the broken zones will inverse their color.
5. Alerts
To make the alerts work, you'll need to add an alert to the chart using the TradingView® alert feature.
Enable Retest Alerts -> You will receive alerts when restests happen on any of the support & resistance zones. "Show Retests" option needs to be enabled to get alerts of this category.
Enable Break Alerts -> You will receive alerts when breaks happen on any of the support & resistance zones.
Opening/Closing Highs and LowsDescription:
This indicator tracks the daily, monthly, and yearly opening, closing, highs, and lows in the stock market. It's designed to display crucial price points within different time frames, aiding traders in assessing significant market movements.
Features:
Daily View: Shows the opening, closing, highest, and lowest prices within each trading day.
Monthly Overview: Highlights the monthly opening, closing, highs, and lows to offer insights into broader market trends.
Yearly Perspective: Presents the annual opening, closing, highs, and lows, aiding in long-term market analysis.
How to Use:
Daily Analysis: Monitor daily fluctuations and spot intraday trends by observing the daily opening/closing ranges.
Monthly Trends: Identify monthly patterns by reviewing the monthly opening/closing levels.
Yearly Insights: Gain a broader perspective on yearly market movements by analyzing the annual highs and lows
Peak & Valley Levels [AlgoAlpha]The Peak & Valley Levels indicator is a sophisticated script designed to pinpoint key support and resistance levels in the market. By utilizing candle length and direction, it accurately identifies potential reversal points, offering traders valuable insights for their strategies.
Core Components:
Peak and Valley Detection: The script recognizes peaks and valleys in price action. Peaks (potential resistance levels) are identified when a candle is longer than the previous one, changes direction, and closes lower, especially on lower volume. Valleys (potential support levels) are detected under similar conditions but with the candle closing higher.
Color-Coded Visualization:
Red lines mark resistance levels, signifying peaks in the price action.
Green lines indicate support levels, representing valleys.
Dynamic Level Adjustment: The script adapts these levels based on ongoing market movements, enhancing their relevance and accuracy.
Rejection Functions:
Bullish Rejection: Determines if a candlestick pattern rejects a level as potential support.
Bearish Rejection: Identifies if a pattern rejects a level as possible resistance.
Usage and Strategy Integration:
Visual Aid for Support and Resistance: The indicator is invaluable for visualizing key market levels where price reversals may occur.
Entry and Exit Points: Traders can use the identified support and resistance levels to fine-tune entry and exit points in their trading strategies.
Trend Reversal Signals: The detection of peaks and valleys serves as an early indicator of potential trend reversals.
Application in Trading:
Versatile for Various Trading Styles: This indicator can be applied across different trading styles, including swing trading, scalping, or trend-following approaches.
Complementary Tool: For best results, it should be used alongside other technical analysis tools to confirm trading signals and strategies.
Customization and Adaptability: Traders are encouraged to experiment with different settings and timeframes to tailor the indicator to their specific trading needs and market conditions.
In summary, the Peak & Valley Levels by AlgoAlpha is a dynamic and adaptable tool that enhances a trader’s ability to identify crucial market levels. Its integration of candlestick analysis with dynamic level adjustment offers a robust method for spotting potential reversal points, making it a valuable addition to any trader's toolkit.
Adaptive MFT Extremum Pivots [Elysian_Mind]Adaptive MFT Extremum Pivots
Overview:
The Adaptive MFT Extremum Pivots indicator, developed by Elysian_Mind, is a powerful Pine Script tool that dynamically displays key market levels, including Monthly Highs/Lows, Weekly Extremums, Pivot Points, and dynamic Resistances/Supports. The term "dynamic" emphasizes the adaptive nature of the calculated levels, ensuring they reflect real-time market conditions. I thank Zandalin for the excellent table design.
---
Chart Explanation:
The table, a visual output of the script, is conveniently positioned in the bottom right corner of the screen, showcasing the indicator's dynamic results. The configuration block, elucidated in the documentation, empowers users to customize the display position. The default placement is at the bottom right, exemplified in the accompanying chart.
The deliberate design ensures that the table does not obscure the candlesticks, with traders commonly situating it outside the candle area. However, the flexibility exists to overlay the table onto the candles. Thanks to transparent cells, the underlying chart remains visible even with the table displayed atop.
In the initial column of the table, users will find labels for the monthly high and low, accompanied by their respective numerical values. The default precision for these values is set at #.###, yet this can be adjusted within the configuration block to suit markets with varying degrees of volatility.
Mirroring this layout, the last column of the table presents the weekly high and low data. This arrangement is part of the upper half of the table. Transitioning to the lower half, users encounter the resistance levels in the first column and the support levels in the last column.
At the center of the table, prominently displayed, is the monthly pivot point. For a comprehensive understanding of the calculations governing these values, users can refer to the documentation. Importantly, users retain the freedom to modify these mathematical calculations, with the table seamlessly updating to reflect any adjustments made.
Noteworthy is the table's persistence; it continues to display reliably even if users choose to customize the mathematical calculations, providing a consistent and adaptable tool for informed decision-making in trading.
This detailed breakdown offers traders a clear guide to interpreting the information presented by the table, ensuring optimal use and understanding of the Adaptive MFT Extremum Pivots indicator.
---
Usage:
Table Layout:
The table is a crucial component of this indicator, providing a structured representation of various market levels. Color-coded cells enhance readability, with blue indicating key levels and a semi-transparent background to maintain chart visibility.
1. Utilizing a Table for Enhanced Visibility:
In presenting this wealth of information, the indicator employs a table format beneath the chart. The use of a table is deliberate and offers several advantages:
2. Structured Organization:
The table organizes the diverse data into a structured format, enhancing clarity and making it easier for traders to locate specific information.
3. Concise Presentation:
A table allows for the concise presentation of multiple data points without cluttering the main chart. Traders can quickly reference key levels without distraction.
4. Dynamic Visibility:
As the market dynamically evolves, the table seamlessly updates in real-time, ensuring that the most relevant information is readily visible without obstructing the candlestick chart.
5. Color Coding for Readability:
Color-coded cells in the table not only add visual appeal but also serve a functional purpose by improving readability. Key levels are easily distinguishable, contributing to efficient analysis.
Data Values:
Numerical values for each level are displayed in their respective cells, with precision defined by the iPrecision configuration parameter.
Configuration:
// User configuration: You can modify this part without code understanding
// Table location configuration
// Position: Table
const string iPosition = position.bottom_right
// Width: Table borders
const int iBorderWidth = 1
// Color configuration
// Color: Borders
const color iBorderColor = color.new(color.white, 75)
// Color: Table background
const color iTableColor = color.new(#2B2A29, 25)
// Color: Title cell background
const color iTitleCellColor = color.new(#171F54, 0)
// Color: Characters
const color iCharColor = color.white
// Color: Data cell background
const color iDataCellColor = color.new(#25456E, 0)
// Precision: Numerical data
const int iPrecision = 3
// End of configuration
The code includes a configuration block where users can customize the following parameters:
Precision of Numerical Table Data (iPrecision):
// Precision: Numerical data
const int iPrecision = 3
This parameter (iPrecision) sets the precision of the numerical values displayed in the table. The default value is 3, displaying numbers in #.### format.
Position of the Table (iPosition):
// Position: Table
const string iPosition = position.bottom_right
This parameter (iPosition) sets the position of the table on the chart. The default is position.bottom_right.
Color preferences
Table borders (iBorderColor):
// Color: Borders
const color iBorderColor = color.new(color.white, 75)
This parameters (iBorderColor) sets the color of the borders everywhere within the window.
Table Background (iTableColor):
// Color: Table background
const color iTableColor = color.new(#2B2A29, 25)
This is the background color of the table. If you've got cells without custom background color, this color will be their background.
Title Cell Background (iTitleCellColor):
// Color: Title cell background
const color iTitleCellColor = color.new(#171F54, 0)
This is the background color the title cells. You can set the background of data cells and text color elsewhere.
Text (iCharColor):
// Color: Characters
const color iCharColor = color.white
This is the color of the text - titles and data - within the table window. If you change any of the background colors, you might want to change this parameter to ensure visibility.
Data Cell Background: (iDataCellColor):
// Color: Data cell background
const color iDataCellColor = color.new(#25456E, 0)
The data cells have a background color to differ from title cells. You can configure this is a different parameter (iDataColor). You might even set the same color for data as for the titles if you will.
---
Mathematical Background:
Monthly and Weekly Extremums:
The indicator calculates the High (H) and Low (L) of the previous month and week, ensuring accurate representation of these key levels.
Standard Monthly Pivot Point:
The standard pivot point is determined based on the previous month's data using the formula:
PivotPoint = (PrevMonthHigh + PrevMonthLow + Close ) / 3
Monthly Pivot Points (R1, R2, R3, S1, S2, S3):
Additional pivot points are calculated for Resistances (R) and Supports (S) using the monthly data:
R1 = 2 * PivotPoint - PrevMonthLow
S1 = 2 * PivotPoint - PrevMonthHigh
R2 = PivotPoint + (PrevMonthHigh - PrevMonthLow)
S2 = PivotPoint - (PrevMonthHigh - PrevMonthLow)
R3 = PrevMonthHigh + 2 * (PivotPoint - PrevMonthLow)
S3 = PrevMonthLow - 2 * (PrevMonthHigh - PivotPoint)
---
Code Explanation and Interpretation:
The table displayed beneath the chart provides the following information:
Monthly Extremums:
(H) High of the previous month
(L) Low of the previous month
// Function to get the high and low of the previous month
getPrevMonthHighLow() =>
var float prevMonthHigh = na
var float prevMonthLow = na
monthChanged = month(time) != month(time )
if (monthChanged)
prevMonthHigh := high
prevMonthLow := low
Weekly Extremums:
(H) High of the previous week
(L) Low of the previous week
// Function to get the high and low of the previous week
getPrevWeekHighLow() =>
var float prevWeekHigh = na
var float prevWeekLow = na
weekChanged = weekofyear(time) != weekofyear(time )
if (weekChanged)
prevWeekHigh := high
prevWeekLow := low
Monthly Pivots:
Pivot: Standard pivot point based on the previous month's data
// Function to calculate the standard pivot point based on the previous month's data
getStandardPivotPoint() =>
= getPrevMonthHighLow()
pivotPoint = (prevMonthHigh + prevMonthLow + close ) / 3
Resistances:
R3, R2, R1: Monthly resistance levels
// Function to calculate additional pivot points based on the monthly data
getMonthlyPivotPoints() =>
= getPrevMonthHighLow()
pivotPoint = (prevMonthHigh + prevMonthLow + close ) / 3
r1 = (2 * pivotPoint) - prevMonthLow
s1 = (2 * pivotPoint) - prevMonthHigh
r2 = pivotPoint + (prevMonthHigh - prevMonthLow)
s2 = pivotPoint - (prevMonthHigh - prevMonthLow)
r3 = prevMonthHigh + 2 * (pivotPoint - prevMonthLow)
s3 = prevMonthLow - 2 * (prevMonthHigh - pivotPoint)
Initializing and Populating the Table:
The myTable variable initializes the table with a blue background, and subsequent table.cell functions populate the table with headers and data.
// Initialize the table with adjusted bgcolor
var myTable = table.new(position = iPosition, columns = 5, rows = 10, bgcolor = color.new(color.blue, 90), border_width = 1, border_color = color.new(color.blue, 70))
Dynamic Data Population:
Data is dynamically populated in the table using the calculated values for Monthly Extremums, Weekly Extremums, Monthly Pivot Points, Resistances, and Supports.
// Add rows dynamically with data
= getPrevMonthHighLow()
= getPrevWeekHighLow()
= getMonthlyPivotPoints()
---
Conclusion:
The Adaptive MFT Extremum Pivots indicator offers traders a detailed and clear representation of critical market levels, empowering them to make informed decisions. However, users should carefully analyze the market and consider their individual risk tolerance before making any trading decisions. The indicator's disclaimer emphasizes that it is not investment advice, and the author and script provider are not responsible for any financial losses incurred.
---
Disclaimer:
This indicator is not investment advice. Trading decisions should be made based on a careful analysis of the market and individual risk tolerance. The author and script provider are not responsible for any financial losses incurred.
Kind regards,
Ely
Targets For Many Indicators [LuxAlgo]The Targets For Many Indicators is a useful utility tool able to display targets for many built-in indicators as well as external indicators. Targets can be set for specific user-set conditions between two series of values, with the script being able to display targets for two different user-set conditions.
Alerts are included for the occurrence of a new target as well as for reached targets.
🔶 USAGE
Targets can help users determine the price limit where the price might start deviating from an indication given by one or multiple indicators. In the context of trading, targets can help secure profits/reduce losses of a trade, as such this tool can be useful to evaluate/determine user take profits/stop losses.
Due to these essentially being horizontal levels, they can also serve as potential support/resistances, with breakouts potentially confirming new trends.
In the above example, we set targets 3 ATR's away from the closing price when the price crosses over the script built-in SuperTrend indicator using ATR period 10 and factor 3. Using "Long Position Target" allows setting a target above the price, disabling this setting will place targets below the price.
Users might be interested in obtaining new targets once one is reached, this can be done by enabling "New Target When Reached" in the target logic setting section, resulting in more frequent targets.
Lastly, users can restrict new target creation until current ones are reached. This can result in fewer and longer-term targets, with a higher reach rate.
🔹 Dashboard
A dashboard is displayed on the top right of the chart, displaying the amount, reach rate of targets 1/2, and total amount.
This dashboard can be useful to evaluate the selected target distances relative to the selected conditions, with a higher reach rate suggesting the distance of the targets from the price allows them to be reached.
🔶 DETAILS
🔹 Indicators
Besides 'External' sources, each source can be set at 1 of the following Build-In Indicators :
ACCDIST : Accumulation/distribution index
ATR : Average True Range
BB (Middle, Upper or Lower): Bollinger Bands
CCI : Commodity Channel Index
CMO : Chande Momentum Oscillator
COG : Center Of Gravity
DC (High, Mid or Low): Donchian Channels
DEMA : Double Exponential Moving Average
EMA : Exponentially weighted Moving Average
HMA : Hull Moving Average
III : Intraday Intensity Index
KC (Middle, Upper or Lower): Keltner Channels
LINREG : Linear regression curve
MACD (macd, signal or histogram): Moving Average Convergence/Divergence
MEDIAN : median of the series
MFI : Money Flow Index
MODE : the mode of the series
MOM : Momentum
NVI : Negative Volume Index
OBV : On Balance Volume
PVI : Positive Volume Index
PVT : Price-Volume Trend
RMA : Relative Moving Average
ROC : Rate Of Change
RSI : Relative Strength Index
SMA : Simple Moving Average
STOCH : Stochastic
Supertrend
TEMA : Triple EMA or Triple Exponential Moving Average
VWAP : Volume Weighted Average Price
VWMA : Volume-Weighted Moving Average
WAD : Williams Accumulation/Distribution
WMA : Weighted Moving Average
WVAD : Williams Variable Accumulation/Distribution
%R : Williams %R
Each indicator is provided with a link to the Reference Manual or to the Build-In Indicators page.
The latter contains more information about each indicator.
Note that when "Show Source Values" is enabled, only values that can be logically found around the price will be shown. For example, Supertrend , SMA , EMA , BB , ... will be made visible. Values like RSI , OBV , %R , ... will not be visible since they will deviate too much from the price.
🔹 Interaction with settings
This publication contains input fields, where you can enter the necessary inputs per indicator.
Some indicators need only 1 value, others 2 or 3.
When several input values are needed, you need to separate them with a comma.
You can use 0 to 4 spaces between without a problem. Even an extra comma doesn't give issues.
The red colored help text will guide you further along (Only when Target is enabled)
Some examples that work without issues:
Some examples that work with issues:
As mentioned, the errors won't be visible when the concerning target is disabled
🔶 SETTINGS
Show Target Labels: Display target labels on the chart.
Candle Coloring: Apply candle coloring based on the most recent active target.
Target 1 and Target 2 use the same settings below:
Enable Target: Display the targets on the chart.
Long Position Target: Display targets above the price a user selected condition is true. If disabled will display the targets below the price.
New Target Condition: Conditional operator used to compare "Source A" and "Source B", options include CrossOver, CrossUnder, Cross, and Equal.
🔹 Sources
Source A: Source A input series, can be an indicator or external source.
External: External source if 'External" is selected in "Source A".
Settings: Settings of the selected indicator in "Source A", entered settings of indicators requiring multiple ones must be comma separated, for example, "10, 3".
Source B: Source B input series, can be an indicator or external source.
External: External source if 'External" is selected in "Source B".
Settings: Settings of the selected indicator in "Source B", entered settings of indicators requiring multiple ones must be comma separated, for example, "10, 3".
Source B Value: User-defined numerical value if "value" is selected in "Source B".
Show Source Values: Display "Source A" and "Source B" on the chart.
🔹 Logic
Wait Until Reached: When enabled will not create a new target until an existing one is reached.
New Target When Reached: Will create a new target when an existing one is reached.
Evaluate Wicks: Will use high/low prices to determine if a target is reached. Unselecting this setting will use the closing price.
Target Distance From Price: Controls the distance of a target from the price. Can be determined in currencies/points, percentages, ATR multiples, ticks, or using multiple of external values.
External Distance Value: External distance value when "External Value" is selected in "Target Distance From Price".