GenericTradingLibrary "GenericTrading"
This library aims to collect rare but useful operations for
get_most_recent_long_or_short_position_closed_index() : returns most recent long/short closed bar index.
get_most_recent_long_or_short_position_open_index() : returns most recent long/short closed bar index.
These two functions designed to help to speed up the coding for strategies that contains "re-enter" logic.
These two functions also could applies in the situations where time-count is needed in your condition.
Percentage
BBW EMA RIBBON+BB%B+EMA BUY/SELL SignalsBINANCE:BTCUSDT
* * * TESTED ON BTCUSDT 4H CHART * * *
The indicator gives signals based on possible ENTRY/EXIT zones (calculated using an ema ribbon of the BBW) and BB%B oversold/overbought conditions, also a 200 EMA filter is used to trade following the major trend.
ENTRY/EXIT zones can be used as a confirmation on other strategies (green zones suggest a possible entry for a long in an uptrend and for a short in a downtrend, red zones suggest a possible exit for long & short)
Only LONG signals are given.
Signals are divided in 3 categories based on their strenght:
- Weak BUY/SELL (green/red circles on chart)
- normal BUY/SELL (green/red triangles with "BUY" or "SELL" text on chart)
- strong BUY/SELL (green/red labels with "STRONG BUY" or "STRONG SELL" text on chart)
You can use signals from the same category as triggers for entering or exiting a trade or you can try using signals from different categories
All indicators settings can be costumized
Possible EXTRY/EXIT zones can be turned ON/OFF
Every signal label can be turned ON/OFF
EMA that changes color based on last candle close can be turned ON/OFF
Alerts can be set for:
- General Signals (every signal will trigger it)
- Weak Signals (only weak signals will trigger it)
- Normal Signals (only normal signals will trigger it)
- Strong Signals (only strong signals will trigger it)
There are 3 BB%B Oversold & 3 BB%B Overbought value presets:
- BASIC (default values)
- LOW (slightly lower values from default)
- HIGH (slightly higher values from default)
Tips:
Use BB%B OS LOW preset to find entries at a better price
Use BB%B OS HIGH preset to find entries faster
Use BB%B OB LOW preset to find exits faster
Use BB%B OB HIGH preset to find exits at a better price
There are 3 Filters already included:
- A checkbox to toggle ON/OFF the use of Heikin Ashi candels to detect trades
- A checkbox to toggle ON/OFF the use of an ema filter for the ribbon that tries to reduce the number of false signals on over-extended price movements
- A checkbox to toggle ON/OFF the use of an ema filter that tries to reduce the number of false signals when price crosses the moving average many times consecutively
All-Time High with Percentage Drops for ETF's and Large CapsPlots the percentage drop levels from the All-Time High of any ticker. You can use this within a pullback trading system. For example, if you historically look at the average pullback of large cap stocks and ETF's, you can use this indicator to plot the levels it could pullback to for an entry to go long. It can be used as potential targets when trading a ticker short. Another use for this is to backtest the set percentage targets using TradingView's bar replay feature to see how ETF's and large cap stocks have reacted at these levels.
Currently percentage levels are statically set to 1, 2, 3, 5, 7, 10, & 20% levels below the All-Time High.
*Not financial advice but in my opinion the current percentage levels set (see above) are best used for ETF's and Large Cap Stocks.
Profit Percentage TrackerThis script provides a quick and easy way to visualize profits in a chart, based on the given entry date and price.
Optionally, alerts can be sent when profits cross up the given " profit unit ".
In short:
Tracks how much profit one could take based on the input " entry date " and the input " entry price "
These inputs are interactive (www.tradingview.com)
Displays the result in a label on top of the last candle
(Optional) Sends alerts based on the given " profit unit ", that is: if ' 0.5 ' is given, then an alert is triggered every time the profit is raised by that number
(Be careful with low values, as TradingView could stop an alert if it triggers too much.)
For alerts to be displayed, a " script alert " must be created right after the script was added to the chart:
- www.tradingview.com
(Choose ' Profits ' as condition and ' Any alert() function call ')
Good to know: if you check " Notify on app ", alerts can be delivered directly to your phone:
i.imgur.com
Prerequirements :
The chart's timezone has to be set to " Exchange " (this is required in order to support the alert's logic):
- kodify.net
Average Change % (14-day)Simple script which calculates and shows the average change in a percentage format over a 14-day period.
Created due to the fact I couldn't find a percentage measure of average change when searching for it.
I have very little coding experience in Pine or otherwise so feel free to take and edit the script to make it a bit more user friendly.
Gain/StopLoss Percentage LinesGain/StopLoss Percentage Lines is a quick way to enter your Entry Price in to a stock and track the percentage of gain or loss at the 5% and 10% markers.
Click on the gear settings icon and type in your entry price. The percentage is defaulted to 5%. You can change this to a different percentage at this screen. Note that whatever number you enter will be doubled for the upper and lower lines. For instance, if you want to set your first red line stop loss and green gain line at 2.5%, your two other upper and lower green and red lines will be at 5%.
However, this will not change the text on the tab marker.
To change the tab text, go in to the Pine Editor and change the green text that says "5% Gain" and "5% Loss" to your new percentages.
Zendog Bar PercentageThis script will add text to bars showing the price change of the bar as a percentage, both for open/close and high/low.
It can be used together with Rate of Change to better get an idea of how the price moved at a previous point in time.
Script uses labels for text, as there is a maximum limit of 500 labels if you want to study price movement for a specific timeframe, you can limit the timeframe from the script settings. Keep in mind that labels are applied to the last 500 candles of any timeframe.
Script also displays statistics for max changes in the selected time period, for both green and red candles both as percentage and base currency absolute value.
Uses:
- Study the behavior of an asset under previous market conditions, black swan events a.s.o.
- Calculate leverage position risk versus extreme price movements
Example: ZENUSDT pumped ~35% on 15 Sep 2021 in the first seconds after the news on getting listed on Coinbase so shorts with 3x leverage would have been liquidated.
Simple Watchlist with % Change Screener & AlertsHi fellow traders..
TV has generously increased the number of alerts!!
A Simple Watchlist with heatmap based on % change on daily timeframe.
Gives % change and RSI
you can set the percentage in the input box and then set alerts on your favorite watchlist.
Alerts also include days high and low..
Simple Table and array based code.
set for scrip close >10 can be easily changed in line 43..
Hope you Like it!
Averange Percentage RangeThis Indicator displays the two different Averange Percentage Range (APR) and the Percentage Range of the current bar.
If the long term APR is over the short term it indicates a lower volatility otherwise a higher.
You can set the calculation method, rising for (highest/lowest-1)*-100 or falling for (lowest/highest-1)*-100.
Percentage MACD Enhanced 3This MACD is calculated using percentage above or below the zero line for consistency and compatibility across different stocks and markets. The price bars are colored when MACD is above/below extreme levels and crossed in that direction. The intention is to use this setting on a longer time frame and trade only in the direction the bars are colored. This setting is also a powerful way to take profits! As usual, my scripts are public for scrutiny and to adjust for your personal needs.
Screener Price Percentage ChangeA screener that displays price percentage change in actual chart timeframe and the default Daily, Weekly and Monthly.
The actual time frame also displays last value percentage change.
For example, if actual timeframe is "Monthly, it is going to display also the last "previous Monthly percentage price change.
Can select 3 more assets to display.
Full control of Panel position and size.
A modified version of @Mohamed3nan
Para el Shiaks
Momentum Performance This Indicator displays the momentum (performance) of the symbol in percent.
You can compare the performance with other symbols.
The default benchmarks are the S&P 500, the MSCI World and the FTSE All World EX US.
The default length corresponds to one year in the timeframes monthly, weekly and daily.
In intraday the default length is 200, but you can also set your own setting.
You have also the opportunity to display a average momentum performance of the main symbol.
MTF Price/Volume % [Anan]Hello friends,
This is a multi-timeframe table with these features:
Display price change percentage compared with the last timeframe candle close.
Display price change percentage compared with the last timeframe candle close MA.
Displays change percentage compared with the last timeframe candle volume.
Displays change percentage compared with the last timeframe candle volume MA.
Change type/length of MA for Price/Volume.
Full control of Panel position and size.
Full control of displaying any row or column.
Difference in price changeCompares price change between current symbol and other one (eg. BTC vs S&P500). It calculates price change on each bar (from high to low or from open to close) and compares with price change of equivalent bar from the other source.
Example
Current symbol
open = 10 USD
close = 7 USD
change = -3 USD
% change = -30%
Second symbol
open = 3 USD
close = 4 USD
change = +1 USD
% change = +33%
Performance of price change = (-30) - (+30) = -63 // It means that current source has weaker performance right now
Zig Lines with Percent & ValueOverview, Features, and Usage:
The Zig Lines with Percent & Value is an indicator that highlights the highest and lowest points of the market from pivot points and zigzag lines based on the ZigZag Period setting. By a default value of 13 for the ZigZag Period this works well on Bitcoin or other alt coins on the 1 hour or higher timeframe charts.
What makes this indicator unique is that it draws a green line to signify an uptrend or a red line to signify a down trend. It will also show the percent difference between the previous point/line, for example: If you see a -negative percentage point with a red line drawn to it, then you are looking at a low pivot point and then as the green line is drawn to a +positive percentage value the percentage you see is the difference between the two points. This is great to see a trend reversal as you can look at previous pivot points and notice about how far the price moves before it changes direction (trend reversal).
There is an invisible EMA line that is used to assist with coloring the negative vs positive values. The value above or below the percentage is the lowest or highest price at that pivot point . The display of the price at the pivot point depends on your ZigZag Period setting and the timeframe of your chart.
Added Bollinger Bands as it fits perfectly with the visuals of the Zig Lines & Pivots.
Usage of Bollinger Bands:
~As the price or candle gets close to the top or bottom of the Bollinger band it can give you a better confirmation that the pivot location is at it's final place, and the trend is more likely to switch directions.
It’s important to know this indicator should not be used for alerts of any type it does repaint as the green or red line is drawing based on live chart data and it can change depending on the direction of the market. This is a great visual tool for trend analysis or to be used with other indicators as a confirmation for a possible good entry or exit position.
Credits ( and consent to use ):
Credits go to user LonesomeTheBlue for creation of this 'Double Zig Zag with HHLL' script.
The addition of the Value above/below the Percentages is from user Noldo and that script is found here:
The Bollinger Bands setup was suggested by user countseven12 and his script that uses the same BB setup is found here:
References:
1. Chen, James. (2021 March 15). Zig Zag Indicator . Received from http: www.investopedia.com
2. Mitchell, Cory. (2021 April 30). Pivot Points . Received from http: www.investopedia.com
INDICES against BTC & ETHThe idea is the following; you can easily chart the FTX perp indices against (currently) two baselines, ETH & BTC.
I always choose ETH since it is way harder to outperform ETH at the moment. Doing this helps me see certain trends and/or fractal that might happen again in the future.
Since I already made D.A.M (Defi against Majors / Pricing Defi categories against BTC & ETH: ) I came across the idea of doing the same thing but with the perp indices that FTX offer. At first, I wanted to add this to D.A.M but it has no place in this indicator since this will not only look at Defi but the macro market as a whole.
The indicator currently only looks at the following indexes (weighting can be found here: https:// help. ftx. com/hc/en-us/articles/360027668812-Index-Calculation) :
DRGN: THE DRAGON INDEX
ARPA, BTM, IOST, NEO, NULS, ONT, QTUM, TRX, VET
ALT: ALTCOIN INDEX
BCH, BNB, EOS, ETH, LTC, XRP, TRX, DOT, LINK, ADA
MID: THE MID CAP INDEX
ALGO, ATOM, BAT, CRO, DASH, DCR, DOGE, HT, IOTA, LEO, NEO, OKB, ONT, QTUM, VET, XEM, XLM, XMR, XTZ, ZEC, ZRX, OMG, COMP, BSV, FTT, YFI, UNI, SNX, MKR, AAVE
SHIT: THE SHITCOIN INDEX
AE, AION, ARDR, ARPA, BCD, BEAM, BTG, BTM, BTS, BTT, CHZ, CKB, DGB, ELF, ENJ, GNT, GRIN, GT, HBAR, HC, ICX, IOST, KMD, KNC, LAMB, LRC, LSK, MANA, MATIC, MCO, NANO, NULS, OMG, POWR, PUNDIX, REN, REP, RVN, SC, SNT, STEEM, THETA, TOMO, VSYS, WAVES, XVG, XZC, ZEN, ZIL, ZRX
PRIV: THE PRIVACY INDEX
BEAM, DCR, GRIN, KMD, XMR, XVG, XZC, ZEC, ZEN
DEFI: THE DECENTRALIZED FINANCE INDEX
KNC, MKR, ZRX, REN, REP, SNX, COMP, TOMO, RUNE, CRV, DOT, LINK, MTA, SOL, CREAM, BAND, SRM, SUSHI, SWRV, AVAX, YFI, UNI, WNXM, AAVE, BAL
Safe Scalpy Stop Loss. Percentage from price visualizer.This is my first script I have published so bear with me.
I have thrown this together so you can easily see on the chart where -0.5%, -1% and -2% would be from the last candle close. I also replicated these to show positive values in case you are shorting.
I have also added a custom value setting so you can set the line at whatever percentage value you like and included an adjustable recent higher high and higher low finder to help create a recent range as it seems to work well in tandem for scalping range based price movement.
You can turn all these things on and off in the settings on the style checkboxes.
I felt the need to make this because I like to scalp trade with leverage like a total degen from time to time. Often the setups happen very quickly. It is difficult to calculate where to set a stop loss in a hurry so I keep a fixed account size/lev and just vary the position percentage size based on the percentage of the stop loss from the current price.
Sometimes when switching from a lower volatility chart to high volatility one it is easy to get caught out by quickly entering a scalp trade only to find you made your position way too big or you shouldn't have entered at all. You thought it was only moving 0.2% per candle instead of 3%. Whoops. Rekt.
This indicator is all about trying to help me avoid that with a visual clue to back up the bad maths I do quickly in my head.
I often hide it and only show it when I'm ready to enter a position to double check my SL and entry are set in a sensible area.
I thought I would publish it in case someone else finds such a simple tool handy.
Apologies if there is already something out there that does this job. I couldn't find it.
See you all on the moon.
Moving Average Percentage Hunter by HassonyaIn this indicator study, we aim to capture the moving averages to which the bar close is closest. The indicator shows the moving averages, which are closest to the percentage value we selected, on the label. It indicates the names of the closest averages at the top of the label with a (near) note next to them. If none of the averages are close to the specified percentage value, there will be a no nearness warning. The indicator supports the heikin ashi candles. For this setting, check the I'm using heikin ashi candles box.
Thanks to this feature of the indicator, you will be able to see bar proximity to the moving averages you use continuously. You can make purchases and sales by using this feature to your advantage. This way you can easily catch reaction turns.
If you want, you can turn off moving averages in the settings section. You can open it whenever you need. You can do this in the show moving averages box. Appears if you check it, disappears if you uncheck it.
There are 5 moving average options. SMA, EMA, WMA, TMA and HullMA moving averages. Moving average names and values in the list are dynamically adjusted. When you change the settings, the moving average names and values in the list will change automatically. At the bottom of the settings, you can determine the lengths of the moving averages yourself. In the next update, each moving average will have a different average option.
You can enter percentage values, fractional figures. for example (3.5, 5.2 vb.) The indicator will show you the value you give and the proximity of the value below that value. You can adjust this setting in MA Percentage Nearness.
More detailed options will be available in the next update. Range of values, options below, above, and so on.
In the settings section, there is a Show distance option. If you check this option, you can continuously see the percentage values of the distance to the moving averages on the label. For this feature, you have to check the show distance box.
The alarm feature will come in the next update.
Thanks for support. Good Luck.
Candle Percent Volatility by AllenlkThis indicator gives you the percentage movement of each candle. Measurements are taken between the candle High point and Low point, and also between the Open and Close and calculated in percent %. From there it smooths out the data with a moving average. This gives you an idea of how much volatility is within each candle given the time resolution of the chart.
I like to use this information as a way to turn off a strategy, or select a proper time resolution for a strategy. If each candle has less than 2.5% Volatility most strategies will typically buy and sell rapidly at prices that are too close together, potentially losing money. During those times it seems best to either temporarily turn off the strategy, change the time resolution or switch to another strategy.
Date-selected Synch and Compare Script Module [yoxxx]This Script is a Convenience Script Module for calculations based or started on a fix time / date.
(In difference to bar_index-based where the reference point is shifting from bar to bar, thus is dynamic).
Purpose examples:
- Comparison by start date
- Time driven studies or strategies
- Measuring from Date of Interest
The script also contains a date input box with the feature of auto-converting the default time to local user time (a newer feature of Tradingview which too me a lot of research to find; so here integrated).
Last not least it the module gives you a ready to go example for multi security comparison on percentage scale with a free selectable start date.
Enjoy
Yoxxx
P.S:. For further notes look at the script code.
They are concerning usage and how avoiding some strange display issues.
Percentage Or Point Bar CalculatorHello Everyone This Indicator Base on Bar (Candle)
How to work its indicator?
➤This indicator calculating Every Bar Percentage Or Point with any Time Frame For eg: if you want to 50 Percentage above or below bar
Indicator Feature
➤ Long Signal with Alert
➤ Short Signal with Alert
➤ You can add Custom Point
➤ You can add Custom Percentage
Coming soon Feature
Take Profit
Stop Lose
Trailing Stoplose
Important: This Indicator we are using for Automation Trading if You Want This Indicator Access, Please Contact me PM on Tradingview
CryptoDon's Buy and Sell Targets Version 1.1This script is str1nger All-time high and percentage drops script with some small mods, such as the previous candles high and low prices.
This script helps me target buy and sell zones based on what percentage the price has dropped.
This is revision #2
Updated as of 2-10-21
CryptoDon's Buy and Sell TargetsThis script is str1nger All-time high and percentage drops script with some small mods, such as the previous candles high and low prices.
This script helps me target buy and sell zones based on what percentage the price has dropped.