Valid Monthly LevelsValid Monthly Levels (No Sweeps) + Smart Labels
This tool automatically plots the highs and lows of each completed monthly candle and tracks their validity in real time. A level is considered valid until it has been swept (price trades strictly beyond that high or low). Once swept, the line and label can either be removed or dimmed depending on your settings.
Key features:
Monthly highs and lows: Each month’s range is marked with horizontal levels that extend forward.
Valid vs. swept logic: Levels are only valid until breached; swept levels can be hidden or kept as dotted/grey lines.
Smart labels: Each level is labeled with the month and year (e.g., Sep ’25 H/L). On higher timeframes, labels sit at the candle; on lower timeframes, labels automatically shift to the right edge so they don’t disappear off-screen.
Customizable appearance: Choose colors for highs, lows, and swept levels; adjust line styles; and limit how many past months are shown.
Clutter control: Cap the maximum number of labels, so your chart stays readable even on small intraday timeframes.
This indicator is useful for traders who track monthly supply/demand extremes, liquidity sweeps, and higher-timeframe context when executing on lower timeframes.
Trend Analysis
Higher Lows, Lower Highs & Failures (updated)Use the Big triangles bullish or bearish, stop at the previous bull or bear indication, hold until the opposite indication. Can't guarantee anything. This is built for the 1m chart
Turtle Trading System (Not Financial Advise)I am testing this script, not financial advise, but this is how it works, i hope;
How the Script Works
The script is a TradingView strategy that backtests and automates the Turtle rules. It uses two systems, a short-term S1 (20-day) and a long-term S2 (55-day), which you can select to test.
The strategy follows these core principles:
Trend Identification: The script uses Donchian Channels to identify breakouts. A new trend is signaled when the price breaks above the highest high or below the lowest low of a specified period.
Position Sizing: The script automatically calculates the size of each trade unit to ensure you risk a consistent percentage of your capital on every trade. This is based on the Average True Range (ATR), which measures volatility.
Pyramiding: When a trade moves in a profitable direction, the script will add more units at specific intervals to increase your position and ride the trend. This is how the Turtles made their big profits.
Win/Loss Condition:
A crucial rule is implemented for System 1 (S1): you only enter a trade if the previous S1 trade was a loss. If the last S1 trade was a win, you must wait for a signal from System 2 (S2).
How to Enter and Exit a Long Position
The script will automatically enter a long position when the price breaks above the highest high of the last 20 days (S1) or 55 days (S2), depending on which system you've selected.
Stop-Loss (SL): Your stop-loss is automatically placed at a distance of 2 * N (ATR) below the entry price. . This is a crucial risk management rule that limits your potential loss. The stop-loss is also plotted visually on the chart.
Exit Long: The script will close the long position automatically under two conditions:
Reversal: The price drops and closes below the lowest low of the last 10 days (S1) or 20 days (S2).
Stop-Loss Hit: The price hits your initial stop-loss, limiting your loss.
How to Enter and Exit a Short Position
Enter Short: The script will automatically enter a short position when the price breaks below the lowest low of the last 20 days (S1) or 55 days (S2).
Stop-Loss (SL): Your stop-loss is automatically placed at a distance of 2 * N (ATR) above the entry price. . This prevents large losses if the price moves against you.
Exit Short: The script will close the short position automatically under two conditions:
Reversal: The price rallies and closes above the highest high of the last 10 days (S1) or 20 days (S2).
Stop-Loss Hit: The price hits your initial stop-loss, limiting your loss.
Engulfing Candles Tarama// This Pine Scriptâ„¢ code is subject to the terms of the Mozilla Public License 2.0 at mozilla.org
// © dipavcisi0007
//@version=5
indicator('Engulfing Candles Tarama', overlay=true)
longer = ta.sma(close, 50)
short = ta.sma(close, 20)
length1 = input(14)
price = close
length = input.int(20, minval=1)
ad = close == high and close == low or high == low ? 0 : (close - open) / (high - low) * volume
//ad = close==high and close==low or high==low ? 0 : ((2*close-low-high)/(high-low))*volume
mf = math.sum(ad, length) / math.sum(volume, length)
crsis = mf
openBarCurrent1 = open
closeBarCurrent1 = close
highBarCurrent1 = high
lowBarCurrent1 = low
volumeBarCurrent1 = volume
topvolumeBarCurrent1 = math.sum(volume , 50) / 50
BarOran1 = (closeBarCurrent1 - openBarCurrent1) / (highBarCurrent1 - lowBarCurrent1)
//BarOran1=(2*closeBarCurrent1-lowBarCurrent1-highBarCurrent1)/(highBarCurrent1-lowBarCurrent1)
openBarCurrent2 = open
closeBarCurrent2 = close
highBarCurrent2 = high
lowBarCurrent2 = low
volumeBarCurrent2 = volume
topvolumeBarCurrent2 = math.sum(volume , 50) / 50
BarOran2 = (closeBarCurrent2 - openBarCurrent2) / (highBarCurrent2 - lowBarCurrent2)
//BarOran2=(2*closeBarCurrent2-lowBarCurrent2-highBarCurrent2)/(highBarCurrent2-lowBarCurrent2)
openBarCurrent3 = open
closeBarCurrent3 = close
highBarCurrent3 = high
lowBarCurrent3 = low
volumeBarCurrent3 = volume
topvolumeBarCurrent3 = math.sum(volume , 50) / 50
BarOran3 = (closeBarCurrent3 - openBarCurrent3) / (highBarCurrent3 - lowBarCurrent3)
//BarOran3=(2*closeBarCurrent3-lowBarCurrent3-highBarCurrent3)/(highBarCurrent3-lowBarCurrent3)
cmi = 0.15
oran = 0.90
katsayi = 1.05
stoporan = 1
length2 = input(14)
price1 = close
vrsi = ta.rsi(price1, length2)
//If current bar open is less than equal to the previous bar close AND current bar open is less than previous bar open AND current bar close is greater than previous bar open THEN True
bullishEngulfing1 = BarOran1 > oran and BarOran1 * volumeBarCurrent1 > topvolumeBarCurrent1 * katsayi and crsis > cmi and close > highBarCurrent1
//If current bar open is greater than equal to previous bar close AND current bar open is greater than previous bar open AND current bar close is less than previous bar open THEN True
bullishEngulfing2 = BarOran2 > oran and BarOran2 * volumeBarCurrent2 > topvolumeBarCurrent2 * katsayi and crsis > cmi and close > highBarCurrent2
//If current bar open is greater than equal to previous bar close AND current bar open is greater than previous bar open AND current bar close is less than previous bar open THEN True
bullishEngulfing3 = BarOran3 > oran and BarOran3 * volumeBarCurrent3 > topvolumeBarCurrent3 * katsayi and crsis > cmi and close > highBarCurrent3
var K1 = 0.0
res = input.timeframe(title='Time Frame', defval='D')
if bullishEngulfing1
K1 := lowBarCurrent1
else if bullishEngulfing2
K1 := lowBarCurrent2
else if bullishEngulfing3
K1 := lowBarCurrent3
plot(K1, linewidth=2, color=color.new(color.purple, 0), title='TSL')
//bullishEngulfing/bearishEngulfing return a value of 1 or 0; if 1 then plot on chart, if 0 then don't plot
plotshape(bullishEngulfing1 or bullishEngulfing2 or bullishEngulfing3, style=shape.triangleup, location=location.belowbar, color=color.new(#43A047, 0), size=size.tiny)
////////////////////////
grupSec = input.string(defval='1', options= , group='Taraması yapılacak 40\'arlı gruplardan birini seçin', title='Grup seç')
per = input.timeframe(defval='', title='PERİYOT',group = "Tarama yapmak istediğiniz periyotu seçin")
func() =>
cond = bullishEngulfing1 or bullishEngulfing2 or bullishEngulfing3
//GRUP VE TARANACAK HİSSE SAYISINI AYNI ÅEKİLDE DİLEDİÄİNİZ GİBİ ARTIRABİLİRSİNİZ.
a01 = grupSec == '1' ? 'BIST:A1CAP' : grupSec == '2' ? 'BIST:ANSGR' : grupSec == '3' ? 'BIST:BEYAZ' : grupSec == '4' ? 'BIST:CEMZY' : grupSec == '5' ? 'BIST:DURKN' : grupSec == '6' ? 'BIST:EUYO' : grupSec == '7' ? 'BIST:HALKB' : grupSec == '8' ? 'BIST:ISGYO' : grupSec == '9' ? 'BIST:KOPOL' : grupSec == '10' ? 'BIST:MARKA' : grupSec == '11' ? 'BIST:ONCSM' : grupSec == '12' ? 'BIST:POLTK' : grupSec == '13' ? 'BIST:SISE' : grupSec == '14' ? 'BIST:TOASO' : grupSec == '15' ? 'BIST:YBTAS' : na
a02 = grupSec == '1' ? 'BIST:ACSEL' : grupSec == '2' ? 'BIST:ARASE' : grupSec == '3' ? 'BIST:BFREN' : grupSec == '4' ? 'BIST:CEOEM' : grupSec == '5' ? 'BIST:DYOBY' : grupSec == '6' ? 'BIST:EYGYO' : grupSec == '7' ? 'BIST:HATEK' : grupSec == '8' ? 'BIST:ISKPL' : grupSec == '9' ? 'BIST:KORDS' : grupSec == '10' ? 'BIST:MARTI' : grupSec == '11' ? 'BIST:ONRYT' : grupSec == '12' ? 'BIST:PRDGS' : grupSec == '13' ? 'BIST:SKBNK' : grupSec == '14' ? 'BIST:TRCAS' : grupSec == '15' ? 'BIST:YEOTK' : na
a03 = grupSec == '1' ? 'BIST:ADEL' : grupSec == '2' ? 'BIST:ARCLK' : grupSec == '3' ? 'BIST:BIENY' : grupSec == '4' ? 'BIST:CIMSA' : grupSec == '5' ? 'BIST:DZGYO' : grupSec == '6' ? 'BIST:FADE' : grupSec == '7' ? 'BIST:HATSN' : grupSec == '8' ? 'BIST:ISKUR' : grupSec == '9' ? 'BIST:KOTON' : grupSec == '10' ? 'BIST:MAVI' : grupSec == '11' ? 'BIST:ORCAY' : grupSec == '12' ? 'BIST:PRKAB' : grupSec == '13' ? 'BIST:SKTAS' : grupSec == '14' ? 'BIST:TRGYO' : grupSec == '15' ? 'BIST:YESIL' : na
a04 = grupSec == '1' ? 'BIST:ADESE' : grupSec == '2' ? 'BIST:ARDYZ' : grupSec == '3' ? 'BIST:BIGCH' : grupSec == '4' ? 'BIST:CLEBI' : grupSec == '5' ? 'BIST:EBEBK' : grupSec == '6' ? 'BIST:FENER' : grupSec == '7' ? 'BIST:HDFGS' : grupSec == '8' ? 'BIST:ISMEN' : grupSec == '9' ? 'BIST:KOZAA' : grupSec == '10' ? 'BIST:MEDTR' : grupSec == '11' ? 'BIST:ORGE' : grupSec == '12' ? 'BIST:PRKME' : grupSec == '13' ? 'BIST:SKYLP' : grupSec == '14' ? 'BIST:TRILC' : grupSec == '15' ? 'BIST:YGGYO' : na
a05 = grupSec == '1' ? 'BIST:ADGYO' : grupSec == '2' ? 'BIST:ARENA' : grupSec == '3' ? 'BIST:BIMAS' : grupSec == '4' ? 'BIST:CMBTN' : grupSec == '5' ? 'BIST:ECILC' : grupSec == '6' ? 'BIST:FLAP' : grupSec == '7' ? 'BIST:HEDEF' : grupSec == '8' ? 'BIST:ISSEN' : grupSec == '9' ? 'BIST:KOZAL' : grupSec == '10' ? 'BIST:MEGAP' : grupSec == '11' ? 'BIST:ORMA' : grupSec == '12' ? 'BIST:PRZMA' : grupSec == '13' ? 'BIST:SKYMD' : grupSec == '14' ? 'BIST:TSGYO' : grupSec == '15' ? 'BIST:YGYO' : na
a06 = grupSec == '1' ? 'BIST:AEFES' : grupSec == '2' ? 'BIST:ARSAN' : grupSec == '3' ? 'BIST:BINBN' : grupSec == '4' ? 'BIST:CMENT' : grupSec == '5' ? 'BIST:ECZYT' : grupSec == '6' ? 'BIST:FMIZP' : grupSec == '7' ? 'BIST:HEKTS' : grupSec == '8' ? 'BIST:ISYAT' : grupSec == '9' ? 'BIST:KRDMA' : grupSec == '10' ? 'BIST:MEGMT' : grupSec == '11' ? 'BIST:OSMEN' : grupSec == '12' ? 'BIST:PSDTC' : grupSec == '13' ? 'BIST:SMART' : grupSec == '14' ? 'BIST:TSKB' : grupSec == '15' ? 'BIST:YIGIT' : na
a07 = grupSec == '1' ? 'BIST:AFYON' : grupSec == '2' ? 'BIST:ARTMS' : grupSec == '3' ? 'BIST:BINHO' : grupSec == '4' ? 'BIST:CONSE' : grupSec == '5' ? 'BIST:EDATA' : grupSec == '6' ? 'BIST:FONET' : grupSec == '7' ? 'BIST:HKTM' : grupSec == '8' ? 'BIST:IZENR' : grupSec == '9' ? 'BIST:KRDMB' : grupSec == '10' ? 'BIST:MEKAG' : grupSec == '11' ? 'BIST:OSTIM' : grupSec == '12' ? 'BIST:PSGYO' : grupSec == '13' ? 'BIST:SMRTG' : grupSec == '14' ? 'BIST:TSPOR' : grupSec == '15' ? 'BIST:YKBNK' : na
a08 = grupSec == '1' ? 'BIST:AGESA' : grupSec == '2' ? 'BIST:ARZUM' : grupSec == '3' ? 'BIST:BIOEN' : grupSec == '4' ? 'BIST:COSMO' : grupSec == '5' ? 'BIST:EDIP' : grupSec == '6' ? 'BIST:FORMT' : grupSec == '7' ? 'BIST:HLGYO' : grupSec == '8' ? 'BIST:IZFAS' : grupSec == '9' ? 'BIST:KRDMD' : grupSec == '10' ? 'BIST:MEPET' : grupSec == '11' ? 'BIST:OTKAR' : grupSec == '12' ? 'BIST:QNBFK' : grupSec == '13' ? 'BIST:SNGYO' : grupSec == '14' ? 'BIST:TTKOM' : grupSec == '15' ? 'BIST:YKSLN' : na
a09 = grupSec == '1' ? 'BIST:AGHOL' : grupSec == '2' ? 'BIST:ASELS' : grupSec == '3' ? 'BIST:BIZIM' : grupSec == '4' ? 'BIST:CRDFA' : grupSec == '5' ? 'BIST:EFORC' : grupSec == '6' ? 'BIST:FORTE' : grupSec == '7' ? 'BIST:HOROZ' : grupSec == '8' ? 'BIST:IZINV' : grupSec == '9' ? 'BIST:KRGYO' : grupSec == '10' ? 'BIST:MERCN' : grupSec == '11' ? 'BIST:OTTO' : grupSec == '12' ? 'BIST:QNBTR' : grupSec == '13' ? 'BIST:SNICA' : grupSec == '14' ? 'BIST:TTRAK' : grupSec == '15' ? 'BIST:YONGA' : na
a10 = grupSec == '1' ? 'BIST:AGROT' : grupSec == '2' ? 'BIST:ASGYO' : grupSec == '3' ? 'BIST:BJKAS' : grupSec == '4' ? 'BIST:CRFSA' : grupSec == '5' ? 'BIST:EGEEN' : grupSec == '6' ? 'BIST:FRIGO' : grupSec == '7' ? 'BIST:HRKET' : grupSec == '8' ? 'BIST:IZMDC' : grupSec == '9' ? 'BIST:KRONT' : grupSec == '10' ? 'BIST:MERIT' : grupSec == '11' ? 'BIST:OYAKC' : grupSec == '12' ? 'BIST:QUAGR' : grupSec == '13' ? 'BIST:SNKRN' : grupSec == '14' ? 'BIST:TUCLK' : grupSec == '15' ? 'BIST:YUNSA' : na
a11 = grupSec == '1' ? 'BIST:AGYO' : grupSec == '2' ? 'BIST:ASTOR' : grupSec == '3' ? 'BIST:BLCYT' : grupSec == '4' ? 'BIST:CUSAN' : grupSec == '5' ? 'BIST:EGEPO' : grupSec == '6' ? 'BIST:FROTO' : grupSec == '7' ? 'BIST:HTTBT' : grupSec == '8' ? 'BIST:JANTS' : grupSec == '9' ? 'BIST:KRPLS' : grupSec == '10' ? 'BIST:MERKO' : grupSec == '11' ? 'BIST:OYAYO' : grupSec == '12' ? 'BIST:RALYH' : grupSec == '13' ? 'BIST:SNPAM' : grupSec == '14' ? 'BIST:TUKAS' : grupSec == '15' ? 'BIST:YYAPI' : na
a12 = grupSec == '1' ? 'BIST:AHGAZ' : grupSec == '2' ? 'BIST:ASUZU' : grupSec == '3' ? 'BIST:BMSCH' : grupSec == '4' ? 'BIST:CVKMD' : grupSec == '5' ? 'BIST:EGGUB' : grupSec == '6' ? 'BIST:FZLGY' : grupSec == '7' ? 'BIST:HUBVC' : grupSec == '8' ? 'BIST:KAPLM' : grupSec == '9' ? 'BIST:KRSTL' : grupSec == '10' ? 'BIST:METRO' : grupSec == '11' ? 'BIST:OYLUM' : grupSec == '12' ? 'BIST:RAYSG' : grupSec == '13' ? 'BIST:SODSN' : grupSec == '14' ? 'BIST:TUPRS' : grupSec == '15' ? 'BIST:YYLGD' : na
a13 = grupSec == '1' ? 'BIST:AHSGY' : grupSec == '2' ? 'BIST:ATAGY' : grupSec == '3' ? 'BIST:BMSTL' : grupSec == '4' ? 'BIST:CWENE' : grupSec == '5' ? 'BIST:EGPRO' : grupSec == '6' ? 'BIST:GARAN' : grupSec == '7' ? 'BIST:HUNER' : grupSec == '8' ? 'BIST:KAREL' : grupSec == '9' ? 'BIST:KRTEK' : grupSec == '10' ? 'BIST:METUR' : grupSec == '11' ? 'BIST:OYYAT' : grupSec == '12' ? 'BIST:REEDR' : grupSec == '13' ? 'BIST:SOKE' : grupSec == '14' ? 'BIST:TUREX' : grupSec == '15' ? 'BIST:ZEDUR' : na
a14 = grupSec == '1' ? 'BIST:AKBNK' : grupSec == '2' ? 'BIST:ATAKP' : grupSec == '3' ? 'BIST:BNTAS' : grupSec == '4' ? 'BIST:DAGHL' : grupSec == '5' ? 'BIST:EGSER' : grupSec == '6' ? 'BIST:GARFA' : grupSec == '7' ? 'BIST:HURGZ' : grupSec == '8' ? 'BIST:KARSN' : grupSec == '9' ? 'BIST:KRVGD' : grupSec == '10' ? 'BIST:MGROS' : grupSec == '11' ? 'BIST:OZATD' : grupSec == '12' ? 'BIST:RGYAS' : grupSec == '13' ? 'BIST:SOKM' : grupSec == '14' ? 'BIST:TURGG' : grupSec == '15' ? 'BIST:ZOREN' : na
a15 = grupSec == '1' ? 'BIST:AKCNS' : grupSec == '2' ? 'BIST:ATATP' : grupSec == '3' ? 'BIST:BOBET' : grupSec == '4' ? 'BIST:DAGI' : grupSec == '5' ? 'BIST:EKGYO' : grupSec == '6' ? 'BIST:GEDIK' : grupSec == '7' ? 'BIST:ICBCT' : grupSec == '8' ? 'BIST:KARTN' : grupSec == '9' ? 'BIST:KSTUR' : grupSec == '10' ? 'BIST:MHRGY' : grupSec == '11' ? 'BIST:OZGYO' : grupSec == '12' ? 'BIST:RNPOL' : grupSec == '13' ? 'BIST:SONME' : grupSec == '14' ? 'BIST:TURSG' : grupSec == '15' ? 'BIST:ZRGYO' : na
a16 = grupSec == '1' ? 'BIST:AKENR' : grupSec == '2' ? 'BIST:ATEKS' : grupSec == '3' ? 'BIST:BORLS' : grupSec == '4' ? 'BIST:DAPGM' : grupSec == '5' ? 'BIST:EKIZ' : grupSec == '6' ? 'BIST:GEDZA' : grupSec == '7' ? 'BIST:ICUGS' : grupSec == '8' ? 'BIST:KARYE' : grupSec == '9' ? 'BIST:KTLEV' : grupSec == '10' ? 'BIST:MIATK' : grupSec == '11' ? 'BIST:OZKGY' : grupSec == '12' ? 'BIST:RODRG' : grupSec == '13' ? 'BIST:SRVGY' : grupSec == '14' ? 'BIST:UFUK' : grupSec == '15' ? 'BIST:AKFIS' :na
a17 = grupSec == '1' ? 'BIST:AKFGY' : grupSec == '2' ? 'BIST:ATLAS' : grupSec == '3' ? 'BIST:BORSK' : grupSec == '4' ? 'BIST:DARDL' : grupSec == '5' ? 'BIST:EKOS' : grupSec == '6' ? 'BIST:GENIL' : grupSec == '7' ? 'BIST:IDGYO' : grupSec == '8' ? 'BIST:KATMR' : grupSec == '9' ? 'BIST:KTSKR' : grupSec == '10' ? 'BIST:MMCAS' : grupSec == '11' ? 'BIST:OZRDN' : grupSec == '12' ? 'BIST:ROYAL' : grupSec == '13' ? 'BIST:SUMAS' : grupSec == '14' ? 'BIST:ULAS' : grupSec == '15' ? 'BIST:ARMGD': na
a18 = grupSec == '1' ? 'BIST:AKFYE' : grupSec == '2' ? 'BIST:ATSYH' : grupSec == '3' ? 'BIST:BOSSA' : grupSec == '4' ? 'BIST:DCTTR' : grupSec == '5' ? 'BIST:EKSUN' : grupSec == '6' ? 'BIST:GENTS' : grupSec == '7' ? 'BIST:IEYHO' : grupSec == '8' ? 'BIST:KAYSE' : grupSec == '9' ? 'BIST:KUTPO' : grupSec == '10' ? 'BIST:MNDRS' : grupSec == '11' ? 'BIST:OZSUB' : grupSec == '12' ? 'BIST:RTALB' : grupSec == '13' ? 'BIST:SUNTK' : grupSec == '14' ? 'BIST:ULKER' : grupSec == '15' ? 'BIST:BALSU': na
a19 = grupSec == '1' ? 'BIST:AKGRT' : grupSec == '2' ? 'BIST:AVGYO' : grupSec == '3' ? 'BIST:BRISA' : grupSec == '4' ? 'BIST:DENGE' : grupSec == '5' ? 'BIST:ELITE' : grupSec == '6' ? 'BIST:GEREL' : grupSec == '7' ? 'BIST:IHAAS' : grupSec == '8' ? 'BIST:KBORU' : grupSec == '9' ? 'BIST:KUVVA' : grupSec == '10' ? 'BIST:MNDTR' : grupSec == '11' ? 'BIST:OZYSR' : grupSec == '12' ? 'BIST:RUBNS' : grupSec == '13' ? 'BIST:SURGY' : grupSec == '14' ? 'BIST:ULUFA' : grupSec == '15' ? 'BIST:BESLR':na
a20 = grupSec == '1' ? 'BIST:AKMGY' : grupSec == '2' ? 'BIST:AVHOL' : grupSec == '3' ? 'BIST:BRKO' : grupSec == '4' ? 'BIST:DERHL' : grupSec == '5' ? 'BIST:EMKEL' : grupSec == '6' ? 'BIST:GESAN' : grupSec == '7' ? 'BIST:IHEVA' : grupSec == '8' ? 'BIST:KCAER' : grupSec == '9' ? 'BIST:KUYAS' : grupSec == '10' ? 'BIST:MOBTL' : grupSec == '11' ? 'BIST:PAGYO' : grupSec == '12' ? 'BIST:RYGYO' : grupSec == '13' ? 'BIST:SUWEN' : grupSec == '14' ? 'BIST:ULUSE' : grupSec == '15' ? 'BIST:DSTKF': na
a21 = grupSec == '1' ? 'BIST:AKSA' : grupSec == '2' ? 'BIST:AVOD' : grupSec == '3' ? 'BIST:BRKSN' : grupSec == '4' ? 'BIST:DERIM' : grupSec == '5' ? 'BIST:EMNIS' : grupSec == '6' ? 'BIST:GIPTA' : grupSec == '7' ? 'BIST:IHGZT' : grupSec == '8' ? 'BIST:KCHOL' : grupSec == '9' ? 'BIST:KZBGY' : grupSec == '10' ? 'BIST:MOGAN' : grupSec == '11' ? 'BIST:PAMEL' : grupSec == '12' ? 'BIST:RYSAS' : grupSec == '13' ? 'BIST:TABGD' : grupSec == '14' ? 'BIST:ULUUN' : grupSec == '15' ? 'BIST:GLRMK': na
a22 = grupSec == '1' ? 'BIST:AKSEN' : grupSec == '2' ? 'BIST:AVPGY' : grupSec == '3' ? 'BIST:BRKVY' : grupSec == '4' ? 'BIST:DESA' : grupSec == '5' ? 'BIST:ENERY' : grupSec == '6' ? 'BIST:GLBMD' : grupSec == '7' ? 'BIST:IHLAS' : grupSec == '8' ? 'BIST:KENT' : grupSec == '9' ? 'BIST:KZGYO' : grupSec == '10' ? 'BIST:MPARK' : grupSec == '11' ? 'BIST:PAPIL' : grupSec == '12' ? 'BIST:SAFKR' : grupSec == '13' ? 'BIST:TARKM' : grupSec == '14' ? 'BIST:UMPAS' : grupSec == '15' ? 'BIST:KLYPV': na
a23 = grupSec == '1' ? 'BIST:AKSGY' : grupSec == '2' ? 'BIST:AVTUR' : grupSec == '3' ? 'BIST:BRLSM' : grupSec == '4' ? 'BIST:DESPC' : grupSec == '5' ? 'BIST:ENJSA' : grupSec == '6' ? 'BIST:GLCVY' : grupSec == '7' ? 'BIST:IHLGM' : grupSec == '8' ? 'BIST:KERVN' : grupSec == '9' ? 'BIST:LIDER' : grupSec == '10' ? 'BIST:MRGYO' : grupSec == '11' ? 'BIST:PARSN' : grupSec == '12' ? 'BIST:SAHOL' : grupSec == '13' ? 'BIST:TATEN' : grupSec == '14' ? 'BIST:UNLU' :grupSec == '15' ? 'BIST:MOPAS': na
a24 = grupSec == '1' ? 'BIST:AKSUE' : grupSec == '2' ? 'BIST:AYCES' : grupSec == '3' ? 'BIST:BRMEN' : grupSec == '4' ? 'BIST:DEVA' : grupSec == '5' ? 'BIST:ENKAI' : grupSec == '6' ? 'BIST:GLRYH' : grupSec == '7' ? 'BIST:IHYAY' : grupSec == '8' ? 'BIST:LIDFA' : grupSec == '10' ? 'BIST:MRSHL' : grupSec == '11' ? 'BIST:PASEU' : grupSec == '12' ? 'BIST:SAMAT' : grupSec == '13' ? 'BIST:TATGD' : grupSec == '14' ? 'BIST:USAK' : grupSec == '15' ? 'BIST:A1YEN': na
a25 = grupSec == '1' ? 'BIST:AKYHO' : grupSec == '2' ? 'BIST:AYDEM' : grupSec == '3' ? 'BIST:BRSAN' : grupSec == '4' ? 'BIST:DGATE' : grupSec == '5' ? 'BIST:ENSRI' : grupSec == '6' ? 'BIST:GLYHO' : grupSec == '7' ? 'BIST:IMASM' : grupSec == '8' ? 'BIST:KFEIN' : grupSec == '9' ? 'BIST:LILAK' : grupSec == '10' ? 'BIST:MSGYO' : grupSec == '11' ? 'BIST:PATEK' : grupSec == '12' ? 'BIST:SANEL' : grupSec == '13' ? 'BIST:TAVHL' : grupSec == '14' ? 'BIST:VAKBN' : grupSec == '15' ? 'BIST:BIGEN': na
a26 = grupSec == '1' ? 'BIST:ALARK' : grupSec == '2' ? 'BIST:AYEN' : grupSec == '3' ? 'BIST:BRYAT' : grupSec == '4' ? 'BIST:DGGYO' : grupSec == '5' ? 'BIST:ENTRA' : grupSec == '6' ? 'BIST:GMTAS' : grupSec == '7' ? 'BIST:INDES' : grupSec == '8' ? 'BIST:KGYO' : grupSec == '9' ? 'BIST:LINK' : grupSec == '10' ? 'BIST:MTRKS' : grupSec == '11' ? 'BIST:PCILT' : grupSec == '12' ? 'BIST:SANFM' : grupSec == '13' ? 'BIST:TBORG' : grupSec == '14' ? 'BIST:VAKFN' : grupSec == '15' ? 'BIST:BULGS': na
a27 = grupSec == '1' ? 'BIST:ALBRK' : grupSec == '2' ? 'BIST:AYES' : grupSec == '3' ? 'BIST:BSOKE' : grupSec == '4' ? 'BIST:DGNMO' : grupSec == '5' ? 'BIST:EPLAS' : grupSec == '6' ? 'BIST:GOKNR' : grupSec == '7' ? 'BIST:INFO' : grupSec == '8' ? 'BIST:KIMMR' : grupSec == '9' ? 'BIST:LKMNH' : grupSec == '10' ? 'BIST:MTRYO' : grupSec == '11' ? 'BIST:PEHOL' : grupSec == '12' ? 'BIST:SANKO' : grupSec == '13' ? 'BIST:TCELL' : grupSec == '14' ? 'BIST:VAKKO' : grupSec == '15' ? 'BIST:CGCAM': na
a28 = grupSec == '1' ? 'BIST:ALCAR' : grupSec == '2' ? 'BIST:AYGAZ' : grupSec == '3' ? 'BIST:BTCIM' : grupSec == '4' ? 'BIST:DIRIT' : grupSec == '5' ? 'BIST:ERBOS' : grupSec == '6' ? 'BIST:GOLTS' : grupSec == '7' ? 'BIST:INGRM' : grupSec == '8' ? 'BIST:KLGYO' : grupSec == '9' ? 'BIST:LMKDC' : grupSec == '10' ? 'BIST:MZHLD' : grupSec == '11' ? 'BIST:PEKGY' : grupSec == '12' ? 'BIST:SARKY' : grupSec == '13' ? 'BIST:TCKRC' : grupSec == '14' ? 'BIST:VANGD' : grupSec == '15' ? 'BIST:EGEGY': na
a29 = grupSec == '1' ? 'BIST:ALCTL' : grupSec == '2' ? 'BIST:AZTEK' : grupSec == '3' ? 'BIST:BUCIM' : grupSec == '4' ? 'BIST:DITAS' : grupSec == '5' ? 'BIST:ERCB' : grupSec == '6' ? 'BIST:GOODY' : grupSec == '7' ? 'BIST:INTEK' : grupSec == '8' ? 'BIST:KLKIM' : grupSec == '9' ? 'BIST:LOGO' : grupSec == '10' ? 'BIST:NATEN' : grupSec == '11' ? 'BIST:PENGD' : grupSec == '12' ? 'BIST:SASA' : grupSec == '13' ? 'BIST:TDGYO' : grupSec == '14' ? 'BIST:VBTYZ' : grupSec == '15' ? 'BIST:ENDAE':na
a30 = grupSec == '1' ? 'BIST:ALFAS' : grupSec == '2' ? 'BIST:BAGFS' : grupSec == '3' ? 'BIST:BURCE' : grupSec == '4' ? 'BIST:DMRGD' : grupSec == '5' ? 'BIST:EREGL' : grupSec == '6' ? 'BIST:GOZDE' : grupSec == '7' ? 'BIST:INTEM' : grupSec == '8' ? 'BIST:KLMSN' : grupSec == '9' ? 'BIST:LRSHO' : grupSec == '10' ? 'BIST:NETAS' : grupSec == '11' ? 'BIST:PENTA' : grupSec == '12' ? 'BIST:SAYAS' : grupSec == '13' ? 'BIST:TEKTU' : grupSec == '14' ? 'BIST:VERTU' : grupSec == '15' ? 'BIST:RUZYE': na
a31 = grupSec == '1' ? 'BIST:ALGYO' : grupSec == '2' ? 'BIST:BAHKM' : grupSec == '3' ? 'BIST:BURVA' : grupSec == '4' ? 'BIST:DMSAS' : grupSec == '5' ? 'BIST:ERSU' : grupSec == '6' ? 'BIST:GRNYO' : grupSec == '7' ? 'BIST:INVEO' : grupSec == '8' ? 'BIST:KLNMA' : grupSec == '9' ? 'BIST:LUKSK' : grupSec == '10' ? 'BIST:NIBAS' : grupSec == '11' ? 'BIST:PETKM' : grupSec == '12' ? 'BIST:SDTTR' : grupSec == '13' ? 'BIST:TERA' : grupSec == '14' ? 'BIST:VERUS' : grupSec == '15' ? 'BIST:SERNT': na
a32 = grupSec == '1' ? 'BIST:ALKA' : grupSec == '2' ? 'BIST:BAKAB' : grupSec == '3' ? 'BIST:BVSAN' : grupSec == '4' ? 'BIST:DNISI' : grupSec == '5' ? 'BIST:ESCAR' : grupSec == '6' ? 'BIST:GRSEL' : grupSec == '7' ? 'BIST:INVES' : grupSec == '8' ? 'BIST:KLRHO' : grupSec == '9' ? 'BIST:LYDHO' : grupSec == '10' ? 'BIST:NTGAZ' : grupSec == '11' ? 'BIST:PETUN' : grupSec == '12' ? 'BIST:SEGMN' : grupSec == '13' ? 'BIST:TEZOL' : grupSec == '14' ? 'BIST:VESBE' : grupSec == '15' ? 'BIST:SMRVA':na
a33 = grupSec == '1' ? 'BIST:ALKIM' : grupSec == '2' ? 'BIST:BALAT' : grupSec == '3' ? 'BIST:BYDNR' : grupSec == '4' ? 'BIST:DOAS' : grupSec == '5' ? 'BIST:ESCOM' : grupSec == '6' ? 'BIST:GRTHO' : grupSec == '7' ? 'BIST:IPEKE' : grupSec == '8' ? 'BIST:KLSER' : grupSec == '9' ? 'BIST:LYDYE' : grupSec == '10' ? 'BIST:NTHOL' : grupSec == '11' ? 'BIST:PGSUS' : grupSec == '12' ? 'BIST:SEGYO' : grupSec == '13' ? 'BIST:TGSAS' : grupSec == '14' ? 'BIST:VESTL' : grupSec == '15' ? 'BIST:VSNMD':na
a34 = grupSec == '1' ? 'BIST:ALKLC' : grupSec == '2' ? 'BIST:BANVT' : grupSec == '3' ? 'BIST:CANTE' : grupSec == '4' ? 'BIST:DOBUR' : grupSec == '5' ? 'BIST:ESEN' : grupSec == '6' ? 'BIST:GSDDE' : grupSec == '7' ? 'BIST:ISATR' : grupSec == '8' ? 'BIST:KLSYN' : grupSec == '9' ? 'BIST:MAALT' : grupSec == '10' ? 'BIST:NUGYO' : grupSec == '11' ? 'BIST:PINSU' : grupSec == '12' ? 'BIST:SEKFK' : grupSec == '13' ? 'BIST:THYAO' : grupSec == '14' ? 'BIST:VKFYO' : na
a35 = grupSec == '1' ? 'BIST:ALMAD' : grupSec == '2' ? 'BIST:BARMA' : grupSec == '3' ? 'BIST:CASA' : grupSec == '4' ? 'BIST:DOCO' : grupSec == '5' ? 'BIST:ETILR' : grupSec == '6' ? 'BIST:GSDHO' : grupSec == '7' ? 'BIST:ISBIR' : grupSec == '8' ? 'BIST:KMPUR' : grupSec == '9' ? 'BIST:MACKO' : grupSec == '10' ? 'BIST:NUHCM' : grupSec == '11' ? 'BIST:PKART' : grupSec == '12' ? 'BIST:SEKUR' : grupSec == '13' ? 'BIST:TKFEN' : grupSec == '14' ? 'BIST:VKGYO' : na
a36 = grupSec == '1' ? 'BIST:ALTNY' : grupSec == '2' ? 'BIST:BASCM' : grupSec == '3' ? 'BIST:CATES' : grupSec == '4' ? 'BIST:DOFER' : grupSec == '5' ? 'BIST:ETYAT' : grupSec == '6' ? 'BIST:GSRAY' : grupSec == '7' ? 'BIST:ISBTR' : grupSec == '8' ? 'BIST:KNFRT' : grupSec == '9' ? 'BIST:MAGEN' : grupSec == '10' ? 'BIST:OBAMS' : grupSec == '11' ? 'BIST:PKENT' : grupSec == '12' ? 'BIST:SELEC' : grupSec == '13' ? 'BIST:TKNSA' : grupSec == '14' ? 'BIST:VKING' : na
a37 = grupSec == '1' ? 'BIST:ALVES' : grupSec == '2' ? 'BIST:BASGZ' : grupSec == '3' ? 'BIST:CCOLA' : grupSec == '4' ? 'BIST:DOGUB' : grupSec == '5' ? 'BIST:EUHOL' : grupSec == '6' ? 'BIST:GUBRF' : grupSec == '7' ? 'BIST:ISCTR' : grupSec == '8' ? 'BIST:KOCMT' : grupSec == '9' ? 'BIST:MAKIM' : grupSec == '10' ? 'BIST:OBASE' : grupSec == '11' ? 'BIST:PLTUR' : grupSec == '12' ? 'BIST:SELGD' : grupSec == '13' ? 'BIST:TLMAN' : grupSec == '14' ? 'BIST:VRGYO' : na
a38 = grupSec == '1' ? 'BIST:ANELE' : grupSec == '2' ? 'BIST:BAYRK' : grupSec == '3' ? 'BIST:CELHA' : grupSec == '4' ? 'BIST:DOHOL' : grupSec == '5' ? 'BIST:EUKYO' : grupSec == '6' ? 'BIST:GUNDG' : grupSec == '7' ? 'BIST:ISDMR' : grupSec == '8' ? 'BIST:KONKA' : grupSec == '9' ? 'BIST:MAKTK' : grupSec == '10' ? 'BIST:ODAS' : grupSec == '11' ? 'BIST:PNLSN' : grupSec == '12' ? 'BIST:SELVA' : grupSec == '13' ? 'BIST:TMPOL' : grupSec == '14' ? 'BIST:YAPRK' : na
a39 = grupSec == '1' ? 'BIST:ANGEN' : grupSec == '2' ? 'BIST:BEGYO' : grupSec == '3' ? 'BIST:CEMAS' : grupSec == '4' ? 'BIST:DOKTA' : grupSec == '5' ? 'BIST:EUPWR' : grupSec == '6' ? 'BIST:GWIND' : grupSec == '7' ? 'BIST:ISFIN' : grupSec == '8' ? 'BIST:KONTR' : grupSec == '9' ? 'BIST:MANAS' : grupSec == '10' ? 'BIST:ODINE' : grupSec == '11' ? 'BIST:PNSUT' : grupSec == '12' ? 'BIST:SEYKM' : grupSec == '13' ? 'BIST:TMSN' : grupSec == '14' ? 'BIST:YATAS' : na
a40 = grupSec == '1' ? 'BIST:ANHYT' : grupSec == '2' ? 'BIST:BERA' : grupSec == '3' ? 'BIST:CEMTS' : grupSec == '4' ? 'BIST:DURDO' : grupSec == '5' ? 'BIST:EUREN' : grupSec == '6' ? 'BIST:GZNMI' : grupSec == '7' ? 'BIST:ISGSY' : grupSec == '8' ? 'BIST:KONYA' : grupSec == '9' ? 'BIST:MARBL' : grupSec == '10' ? 'BIST:OFSYM' : grupSec == '11' ? 'BIST:POLHO' : grupSec == '12' ? 'BIST:SILVR' : grupSec == '13' ? 'BIST:TNZTP' : grupSec == '14' ? 'BIST:YAYLA' : na
= request.security(a01, per, func())
= request.security(a02, per, func())
= request.security(a03, per, func())
= request.security(a04, per, func())
= request.security(a05, per, func())
= request.security(a06, per, func())
= request.security(a07, per, func())
= request.security(a08, per, func())
= request.security(a09, per, func())
= request.security(a10, per, func())
= request.security(a11, per, func())
= request.security(a12, per, func())
= request.security(a13, per, func())
= request.security(a14, per, func())
= request.security(a15, per, func())
= request.security(a16, per, func())
= request.security(a17, per, func())
= request.security(a18, per, func())
= request.security(a19, per, func())
= request.security(a20, per, func())
= request.security(a21, per, func())
= request.security(a22, per, func())
= request.security(a23, per, func())
= request.security(a24, per, func())
= request.security(a25, per, func())
= request.security(a26, per, func())
= request.security(a27, per, func())
= request.security(a28, per, func())
= request.security(a29, per, func())
= request.security(a30, per, func())
= request.security(a31, per, func())
= request.security(a32, per, func())
= request.security(a33, per, func())
= request.security(a34, per, func())
= request.security(a35, per, func())
= request.security(a36, per, func())
= request.security(a37, per, func())
= request.security(a38, per, func())
= request.security(a39, per, func())
= request.security(a40, per, func())
roundn(x, n) =>
mult = 1
if n != 0
for i = 1 to math.abs(n) by 1
mult *= 10
mult
n >= 0 ? math.round(x * mult) / mult : math.round(x / mult) * mult
scr_label = 'TARAMA '
scr_label := s1 ? scr_label + syminfo.ticker(a01) + ' ' + str.tostring(roundn(v1, 2)) + ' ' : scr_label
scr_label := s2 ? scr_label + syminfo.ticker(a02) + ' ' + str.tostring(roundn(v2, 2)) + ' ' : scr_label
scr_label := s3 ? scr_label + syminfo.ticker(a03) + ' ' + str.tostring(roundn(v3, 2)) + ' ' : scr_label
scr_label := s4 ? scr_label + syminfo.ticker(a04) + ' ' + str.tostring(roundn(v4, 2)) + ' ' : scr_label
scr_label := s5 ? scr_label + syminfo.ticker(a05) + ' ' + str.tostring(roundn(v5, 2)) + ' ' : scr_label
scr_label := s6 ? scr_label + syminfo.ticker(a06) + ' ' + str.tostring(roundn(v6, 2)) + ' ' : scr_label
scr_label := s7 ? scr_label + syminfo.ticker(a07) + ' ' + str.tostring(roundn(v7, 2)) + ' ' : scr_label
scr_label := s8 ? scr_label + syminfo.ticker(a08) + ' ' + str.tostring(roundn(v8, 2)) + ' ' : scr_label
scr_label := s9 ? scr_label + syminfo.ticker(a09) + ' ' + str.tostring(roundn(v9, 2)) + ' ' : scr_label
scr_label := s10 ? scr_label + syminfo.ticker(a10) + ' ' + str.tostring(roundn(v10, 2)) + ' ' : scr_label
scr_label := s11 ? scr_label + syminfo.ticker(a11) + ' ' + str.tostring(roundn(v11, 2)) + ' ' : scr_label
scr_label := s12 ? scr_label + syminfo.ticker(a12) + ' ' + str.tostring(roundn(v12, 2)) + ' ' : scr_label
scr_label := s13 ? scr_label + syminfo.ticker(a13) + ' ' + str.tostring(roundn(v13, 2)) + ' ' : scr_label
scr_label := s14 ? scr_label + syminfo.ticker(a14) + ' ' + str.tostring(roundn(v14, 2)) + ' ' : scr_label
scr_label := s15 ? scr_label + syminfo.ticker(a15) + ' ' + str.tostring(roundn(v15, 2)) + ' ' : scr_label
scr_label := s16 ? scr_label + syminfo.ticker(a16) + ' ' + str.tostring(roundn(v16, 2)) + ' ' : scr_label
scr_label := s17 ? scr_label + syminfo.ticker(a17) + ' ' + str.tostring(roundn(v17, 2)) + ' ' : scr_label
scr_label := s18 ? scr_label + syminfo.ticker(a18) + ' ' + str.tostring(roundn(v18, 2)) + ' ' : scr_label
scr_label := s19 ? scr_label + syminfo.ticker(a19) + ' ' + str.tostring(roundn(v19, 2)) + ' ' : scr_label
scr_label := s20 ? scr_label + syminfo.ticker(a20) + ' ' + str.tostring(roundn(v20, 2)) + ' ' : scr_label
scr_label := s21 ? scr_label + syminfo.ticker(a21) + ' ' + str.tostring(roundn(v21, 2)) + ' ' : scr_label
scr_label := s22 ? scr_label + syminfo.ticker(a22) + ' ' + str.tostring(roundn(v22, 2)) + ' ' : scr_label
scr_label := s23 ? scr_label + syminfo.ticker(a23) + ' ' + str.tostring(roundn(v23, 2)) + ' ' : scr_label
scr_label := s24 ? scr_label + syminfo.ticker(a24) + ' ' + str.tostring(roundn(v24, 2)) + ' ' : scr_label
scr_label := s25 ? scr_label + syminfo.ticker(a25) + ' ' + str.tostring(roundn(v25, 2)) + ' ' : scr_label
scr_label := s26 ? scr_label + syminfo.ticker(a26) + ' ' + str.tostring(roundn(v26, 2)) + ' ' : scr_label
scr_label := s27 ? scr_label + syminfo.ticker(a27) + ' ' + str.tostring(roundn(v27, 2)) + ' ' : scr_label
scr_label := s28 ? scr_label + syminfo.ticker(a28) + ' ' + str.tostring(roundn(v28, 2)) + ' ' : scr_label
scr_label := s29 ? scr_label + syminfo.ticker(a29) + ' ' + str.tostring(roundn(v29, 2)) + ' ' : scr_label
scr_label := s30 ? scr_label + syminfo.ticker(a30) + ' ' + str.tostring(roundn(v30, 2)) + ' ' : scr_label
scr_label := s31 ? scr_label + syminfo.ticker(a31) + ' ' + str.tostring(roundn(v31, 2)) + ' ' : scr_label
scr_label := s32 ? scr_label + syminfo.ticker(a32) + ' ' + str.tostring(roundn(v32, 2)) + ' ' : scr_label
scr_label := s33 ? scr_label + syminfo.ticker(a33) + ' ' + str.tostring(roundn(v33, 2)) + ' ' : scr_label
scr_label := s34 ? scr_label + syminfo.ticker(a34) + ' ' + str.tostring(roundn(v34, 2)) + ' ' : scr_label
scr_label := s35 ? scr_label + syminfo.ticker(a35) + ' ' + str.tostring(roundn(v35, 2)) + ' ' : scr_label
scr_label := s36 ? scr_label + syminfo.ticker(a36) + ' ' + str.tostring(roundn(v36, 2)) + ' ' : scr_label
scr_label := s37 ? scr_label + syminfo.ticker(a37) + ' ' + str.tostring(roundn(v37, 2)) + ' ' : scr_label
scr_label := s38 ? scr_label + syminfo.ticker(a38) + ' ' + str.tostring(roundn(v38, 2)) + ' ' : scr_label
scr_label := s39 ? scr_label + syminfo.ticker(a39) + ' ' + str.tostring(roundn(v39, 2)) + ' ' : scr_label
scr_label := s40 ? scr_label + syminfo.ticker(a40) + ' ' + str.tostring(roundn(v40, 2)) + ' ' : scr_label
var panel =table.new(position = position.top_right,columns = 10,rows=10,bgcolor = color.green,frame_color = color.black,border_color = color.red)
//lab_1 = label.new(bar_index + loc,50, scr_label, color=color.green, textcolor=color.white, style=label.style_label_center)
//label.delete(lab_1 )
if barstate.islast
table.cell(panel,0,0,text = str.tostring(scr_label))
if str.length(scr_label) > 8
alert(scr_label,alert.freq_once_per_bar_close)
//------------------------------------------------------
Dual Relative Strength (Fast & Slow, Single Baseline)Dual-Period RS Setup (Fast + Slow)
1. Fast RS (Early Leadership)
• Indicator: Relative Strength (by modhelius)
• Comparative Symbol: NIFTY
• Period: 26 weeks (~6 months)
• Purpose: Detects early shifts in relative strength before price fully confirms.
⸻
2. Slow RS (Confirmation)
• Add the same indicator again.
• Comparative Symbol: NIFTY
• Period: 52 weeks (1 year)
• Purpose: Confirms sustained leadership. Helps filter noise & false positives.
Dual Relative Strength (vs NIFTY) Nikrun1. Fast RS (Early Leadership)
• Indicator: Relative Strength (by modhelius)
• Comparative Symbol: NIFTY
• Period: 26 weeks (~6 months)
• Purpose: Detects early shifts in relative strength before price fully confirms.
⸻
2. Slow RS (Confirmation)
• Add the same indicator again.
• Comparative Symbol: NIFTY
• Period: 52 weeks (1 year)
• Purpose: Confirms sustained leadership. Helps filter noise & false positives.
⸻
3. Visuals
• Style tip:
• Make RS(26) = blue line (fast, responsive).
• Make RS(52) = thicker black/green line (slow, authority).
• Keep zero line visible so you instantly see outperformance/underperformance.
⸻
Market Opening Time### TradingView Pine Script "Market Opening Time" Explanation
This Pine Script (`@version=5`) is an indicator that visually highlights market trading sessions (Sydney, London, New York, etc.) by changing the chart's background color. It adjusts for U.S. and Australian Daylight Saving Time (DST).
---
#### **1. Overview**
- **Purpose**: Changes the chart's background color based on UTC time zones to highlight market sessions.
- **Features**:
- Automatically adjusts for U.S. DST (2nd Sunday of March to 1st Sunday of November) and Australian DST (1st Sunday of October to 1st Sunday of April).
- Assigns colors to four time zones (00:00, 06:30, 14:00, 21:00).
- **Use Case**: Helps forex/stock traders identify active market sessions.
---
#### **2. Key Logic**
- **DST Detection**:
- `f_isUSDst`: Checks U.S. DST status.
- `f_isAustraliaDst`: Checks Australian DST status.
- **Time Adjustment** (`f_getAdjustedTime`):
- U.S. DST off: Shifts `time3` (14:00) forward by 1 hour.
- Australian DST off: Shifts `time4` (21:00) forward by 1 hour.
- **Time Conversion** (`f_timeToMinutes`): Converts time (e.g., "14:00") to minutes (e.g., 840).
- **Current Time** (`f_currentTimeInMinutes`): Gets UTC time in minutes.
- **Background Color** (`f_getBackgroundColor`):
- Applies colors based on time ranges:
- 00:00–06:30: Orange (Asia)
- 06:30–14:00: Purple (London)
- 14:00–21:00: Blue (New York, DST-adjusted)
- 21:00–00:00: Red (Sydney, DST-adjusted)
- Outside ranges: Gray
---
#### **3. Settings**
- **Time Zones**:
- `time1` = 00:00 (Orange)
- `time2` = 06:30 (Purple)
- `time3` = 14:00 (Blue, DST-adjusted)
- `time4` = 21:00 (Red, DST-adjusted)
- **Colors**: Transparency set to 90 for visibility.
---
#### **4. Example**
- **September 5, 2025, 10:25 PM JST (13:25 UTC)**:
- U.S. DST active, Australian DST inactive.
- 13:25 UTC falls between `time2` (06:30) and `time3` (14:00) → Background is **Purple** (London session).
- **Effect**: Background color changes dynamically to reflect active sessions.
---
#### **5. Customization**
- Modify `time1`–`time4` or colors for different sessions.
- Add time zones for other markets (e.g., Tokyo).
---
#### **6. Notes**
- Uses UTC; ensure chart is set to UTC.
- DST rules are U.S./Australia-specific; verify for other regions.
A simple, visual tool for tracking market sessions.
----
### TradingView Pine Script「Market Opening Time」解説
このPine Script(`@version=5`)は、市場の取引時間帯(シドニー、ロンドン、ニューヨークなど)を背景色で視覚化するインジケーターです。米国とオーストラリアの夏時間(DST)を考慮し、時間帯を調整します。
---
#### **1. 概要**
- **目的**: UTC基準の時間帯に基づき、チャートの背景色を変更して市場セッションを強調。
- **機能**:
- 米国DST(3月第2日曜~11月第1日曜)とオーストラリアDST(10月第1日曜~4月第1日曜)を自動調整。
- 4つの時間帯(00:00、06:30、14:00、21:00)に色を割り当て。
- **用途**: FXや株式トレーダーが市場のアクティブ時間を把握。
---
#### **2. 主要ロジック**
- **DST判定**:
- `f_isUSDst`: 米国DSTを判定。
- `f_isAustraliaDst`: オーストラリアDSTを判定。
- **時間調整** (`f_getAdjustedTime`):
- 米国DST非適用時: `time3`(14:00)を1時間遅延。
- オーストラリアDST非適用時: `time4`(21:00)を1時間遅延。
- **時間変換** (`f_timeToMinutes`): 時間(例: "14:00")を分単位(840)に変換。
- **現在時刻** (`f_currentTimeInMinutes`): UTCの現在時刻を分単位で取得。
- **背景色** (`f_getBackgroundColor`):
- 時間帯に応じた色を適用:
- 00:00~06:30: オレンジ(アジア)
- 06:30~14:00: 紫(ロンドン)
- 14:00~21:00: 青(ニューヨーク、DST調整)
- 21:00~00:00: 赤(シドニー、DST調整)
- 時間外: グレー
---
#### **3. 設定**
- **時間帯**:
- `time1` = 00:00(オレンジ)
- `time2` = 06:30(紫)
- `time3` = 14:00(青、DST調整)
- `time4` = 21:00(赤、DST調整)
- **色**: 透明度90で視認性確保。
---
#### **4. 使用例**
- **2025年9月5日22:25 JST(13:25 UTC)**:
- 米国DST適用、豪DST非適用。
- 13:25は`time2`(06:30)~`time3`(14:00)の間 → 背景色は**紫**(ロンドン)。
- **効果**: 時間帯に応じて背景色が変化し、市場セッションを直感的に把握。
---
#### **5. カスタマイズ**
- 時間帯(`time1`~`time4`)や色を変更可能。
- 他の市場(例: 東京)に対応する時間帯を追加可能。
---
#### **6. 注意点**
- UTC基準のため、チャート設定をUTCに。
- DSTルールは米国・オーストラリア準拠。他地域では要確認。
シンプルで視覚的な市場時間インジケーターです。
HalfTrend Histogram (MTF)This indicator shows the halftrend on a histogram (rather than a line on the chart) and has an option for Multi timeframe (MTF).
It uses the logic of the original halftrend coded by Everget.
The halftrend is a trend-following indicator that uses volatility to to determine change in bias.
Sentinel 5 — OHL daybreak signals [KedArc Quant]Overview
Sentinel 5 plots the first-bar high/low of each trading session and gives clean, rules-based signals in two ways:
1) OHL Setups at the close of the first bar (Open equals/near High for potential short; Open equals/near Low for potential long).
2) Breakout Signals later in the session when price breaks the first-bar High/Low, with optional body/penetration filters.
Basic workflow
1. Wait for the first session bar to finish.
*If O≈H (optionally by proximity) → short setup. •
*If O≈L → long setup. • If neither happens, optionally allow later breakouts.
2. Optional: Act only on breakouts that penetrate a minimum % of that bar’s range/body.
3. Skip the day automatically if the first bar is abnormally large (marubozu-like / extreme ATR / outsized vs yesterday).
Signals & Markers
Markers on the chart:
▲ O=L (exact) / O near L (proximity) – long setup at first-bar close.
▼ O=H (exact) / O near H (proximity) – short setup at first-bar close.
▲ Breakout Long – later bar breaks above first-bar High meeting your penetration rule.
▼ Breakout Short – later bar breaks below first-bar Low meeting your penetration rule.
Martingale Strategy Simulator [BackQuant]Martingale Strategy Simulator
Purpose
This indicator lets you study how a martingale-style position sizing rule interacts with a simple long or short trading signal. It computes an equity curve from bar-to-bar returns, adapts position size after losing streaks, caps exposure at a user limit, and summarizes risk with portfolio metrics. An optional Monte Carlo module projects possible future equity paths from your realized daily returns.
What a martingale is
A martingale sizing rule increases stake after losses and resets after a win. In its classical form from gambling, you double the bet after each loss so that a single win recovers all prior losses plus one unit of profit. In markets there is no fixed “even-money” payout and returns are multiplicative, so an exact recovery guarantee does not exist. The core idea is unchanged:
Lose one leg → increase next position size
Lose again → increase again
Win → reset to the base size
The expectation of your strategy still depends on the signal’s edge. Sizing does not create positive expectancy on its own. A martingale raises variance and tail risk by concentrating more capital as a losing streak develops.
What it plots
Equity – simulated portfolio equity including compounding
Buy & Hold – equity from holding the chart symbol for context
Optional helpers – last trade outcome, current streak length, current allocation fraction
Optional diagnostics – daily portfolio return, rolling drawdown, metrics table
Optional Monte Carlo probability cone – p5, p16, p50, p84, p95 aggregate bands
Model assumptions
Bar-close execution with no slippage or commissions
Shorting allowed and frictionless
No margin interest, borrow fees, or position limits
No intrabar moves or gaps within a bar (returns are close-to-close)
Sizing applies to equity fraction only and is capped by your setting
All results are hypothetical and for education only.
How the simulator applies it
1) Directional signal
You pick a simple directional rule that produces +1 for long or −1 for short each bar. Options include 100 HMA slope, RSI above or below 50, EMA or SMA crosses, CCI and other oscillators, ATR move, BB basis, and more. The stance is evaluated bar by bar. When the stance flips, the current trade ends and the next one starts.
2) Sizing after losses and wins
Position size is a fraction of equity:
Initial allocation – the starting fraction, for example 0.15 means 15 percent of equity
Increase after loss – multiply the next allocation by your factor after a losing leg, for example 2.00 to double
Reset after win – return to the initial allocation
Max allocation cap – hard ceiling to prevent runaway growth
At a high level the size after k consecutive losses is
alloc(k) = min( cap , base × factor^k ) .
In practice the simulator changes size only when a leg ends and its PnL is known.
3) Equity update
Let r_t = close_t / close_{t-1} − 1 be the symbol’s bar return, d_{t−1} ∈ {+1, −1} the prior bar stance, and a_{t−1} the prior bar allocation fraction. The simulator compounds:
eq_t = eq_{t−1} × (1 + a_{t−1} × d_{t−1} × r_t) .
This is bar-based and avoids intrabar lookahead. Costs, slippage, and borrowing costs are not modeled.
Why traders experiment with martingale sizing
Mean-reversion contexts – if the signal often snaps back after a string of losses, adding size near the tail of a move can pull the average entry closer to the turn
Behavioral or microstructure edges – some rules have modest edge but frequent small whipsaws; size escalation may shorten time-to-recovery when the edge manifests
Exploration and stress testing – studying the relationship between streaks, caps, and drawdowns is instructive even if you do not deploy martingale sizing live
Why martingale is dangerous
Martingale concentrates capital when the strategy is performing worst. The main risks are structural, not cosmetic:
Loss streaks are inevitable – even with a 55 percent win rate you should expect multi-loss runs. The probability of at least one k-loss streak in N trades rises quickly with N.
Size explodes geometrically – with factor 2.0 and base 10 percent, the sequence is 10, 20, 40, 80, 100 (capped) after five losses. Without a strict cap, required size becomes infeasible.
No fixed payout – in gambling, one win at even odds resets PnL. In markets, there is no guaranteed bounce nor fixed profit multiple. Trends can extend and gaps can skip levels.
Correlation of losses – losses cluster in trends and in volatility bursts. A martingale tends to be largest just when volatility is highest.
Margin and liquidity constraints – leverage limits, margin calls, position limits, and widening spreads can force liquidation before a mean reversion occurs.
Fat tails and regime shifts – assumptions of independent, Gaussian returns can understate tail risk. Structural breaks can keep the signal wrong for much longer than expected.
The simulator exposes these dynamics in the equity curve, Max Drawdown, VaR and CVaR, and via Monte Carlo sketches of forward uncertainty.
Interpreting losing streaks with numbers
A rough intuition: if your per-trade win probability is p and loss probability is q=1−p , the chance of a specific run of k consecutive losses is q^k . Over many trades, the chance that at least one k-loss run occurs grows with the number of opportunities. As a sanity check:
If p=0.55 , then q=0.45 . A 6-loss run has probability q^6 ≈ 0.008 on any six-trade window. Across hundreds of trades, a 6 to 8-loss run is not rare.
If your size factor is 1.5 and your base is 10 percent, after 8 losses the requested size is 10% × 1.5^8 ≈ 25.6% . With factor 2.0 it would try to be 10% × 2^8 = 256% but your cap will stop it. The equity curve will still wear the compounded drawdown from the sequence that led to the cap.
This is why the cap setting is central. It does not remove tail risk, but it prevents the sizing rule from demanding impossible positions
Note: The p and q math is illustrative. In live data the win rate and distribution can drift over time, so real streaks can be longer or shorter than the simple q^k intuition suggests..
Using the simulator productively
Parameter studies
Start with conservative settings. Increase one element at a time and watch how the equity, Max Drawdown, and CVaR respond.
Initial allocation – lower base reduces volatility and drawdowns across the board
Increase factor – set modestly above 1.0 if you want the effect at all; doubling is aggressive
Max cap – the most important brake; many users keep it between 20 and 50 percent
Signal selection
Keep sizing fixed and rotate signals to see how streak patterns differ. Trend-following signals tend to produce long wrong-way streaks in choppy ranges. Mean-reversion signals do the opposite. Martingale sizing interacts very differently with each.
Diagnostics to watch
Use the built-in metrics to quantify risk:
Max Drawdown – worst peak-to-trough equity loss
Sharpe and Sortino – volatility and downside-adjusted return
VaR 95 percent and CVaR – tail risk measures from the realized distribution
Alpha and Beta – relationship to your chosen benchmark
If you would like to check out the original performance metrics script with multiple assets with a better explanation on all metrics please see
Monte Carlo exploration
When enabled, the forecast draws many synthetic paths from your realized daily returns:
Choose a horizon and a number of runs
Review the bands: p5 to p95 for a wide risk envelope; p16 to p84 for a narrower range; p50 as the median path
Use the table to read the expected return over the horizon and the tail outcomes
Remember it is a sketch based on your recent distribution, not a predictor
Concrete examples
Example A: Modest martingale
Base 10 percent, factor 1.25, cap 40 percent, RSI>50 signal. You will see small escalations on 2 to 4 loss runs and frequent resets. The equity curve usually remains smooth unless the signal enters a prolonged wrong-way regime. Max DD may rise moderately versus fixed sizing.
Example B: Aggressive martingale
Base 15 percent, factor 2.0, cap 60 percent, EMA cross signal. The curve can look stellar during favorable regimes, then a single extended streak pushes allocation to the cap, and a few more losses drive deep drawdown. CVaR and Max DD jump sharply. This is a textbook case of high tail risk.
Strengths
Bar-by-bar, transparent computation of equity from stance and size
Explicit handling of wins, losses, streaks, and caps
Portable signal inputs so you can A–B test ideas quickly
Risk diagnostics and forward uncertainty visualization in one place
Example, Rolling Max Drawdown
Limitations and important notes
Martingale sizing can escalate drawdowns rapidly. The cap limits position size but not the possibility of extended adverse runs.
No commissions, slippage, margin interest, borrow costs, or liquidity limits are modeled.
Signals are evaluated on closes. Real execution and fills will differ.
Monte Carlo assumes independent draws from your recent return distribution. Markets often have serial correlation, fat tails, and regime changes.
All results are hypothetical. Use this as an educational tool, not a production risk engine.
Practical tips
Prefer gentle factors such as 1.1 to 1.3. Doubling is usually excessive outside of toy examples.
Keep a strict cap. Many users cap between 20 and 40 percent of equity per leg.
Stress test with different start dates and subperiods. Long flat or trending regimes are where martingale weaknesses appear.
Compare to an anti-martingale (increase after wins, cut after losses) to understand the other side of the trade-off.
If you deploy sizing live, add external guardrails such as a daily loss cut, volatility filters, and a global max drawdown stop.
Settings recap
Backtest start date and initial capital
Initial allocation, increase-after-loss factor, max allocation cap
Signal source selector
Trading days per year and risk-free rate
Benchmark symbol for Alpha and Beta
UI toggles for equity, buy and hold, labels, metrics, PnL, and drawdown
Monte Carlo controls for enable, runs, horizon, and result table
Final thoughts
A martingale is not a free lunch. It is a way to tilt capital allocation toward losing streaks. If the signal has a real edge and mean reversion is common, careful and capped escalation can reduce time-to-recovery. If the signal lacks edge or regimes shift, the same rule can magnify losses at the worst possible moment. This simulator makes those trade-offs visible so you can calibrate parameters, understand tail risk, and decide whether the approach belongs anywhere in your research workflow.
ADX Tide ZonesADX Tide Zones – Adaptive Momentum & Trend Strength Framework
Overview
ADX Tide Zones – Professional is a dynamic trend-strength visualizer designed for traders who want to interpret momentum with precision and context. By combining the Average Directional Index (ADX) with adaptive threshold logic, the indicator segments price action into distinct “tide zones” that reflect varying levels of market strength: Calm, Rising, Strong, and Falling Tides. These zones transform raw ADX readings into an interpretable framework that highlights when markets are consolidating, building momentum, trending strongly, or losing strength.
Unlike standard ADX readings, which can be difficult to interpret in real time, ADX Tide Zones translate momentum shifts into a continuous, color-coded system that traders can instantly read. Whether applied to scalping, intraday, or swing trading, the indicator offers a consistent methodology for identifying actionable opportunities across assets and timeframes.
How It Works
The foundation of ADX Tide Zones lies in momentum analysis via the ADX. By measuring the strength (not direction) of a trend, ADX provides an objective read on when markets are gaining or losing energy. ADX Tide Zones enhances this by applying threshold logic to classify ADX values into four distinct states:
Calm Tide : Low ADX values indicate sideways or consolidating conditions.
Rising Tide : ADX increases past a threshold, signaling momentum building.
Strong Tide : ADX remains elevated, confirming robust and sustained trend strength.
Falling Tide : ADX declines after strength, hinting at exhaustion or early reversal setups.
These states are displayed on the chart through adaptive visualizations (zones, bar colors, or overlays), offering real-time clarity on when to expect expansion, continuation, or contraction in price action.
Interpretation
Trend Analysis : By mapping transitions between tides, traders can instantly gauge whether markets are in accumulation, expansion, or exhaustion phases. Rising/Strong Tides reinforce trend continuation, while Falling Tides highlight weakening conditions.
Volatility & Risk Assessment : Shifts between Calm → Rising Tide often precede volatility expansions. Falling Tides can signal a period of compression or corrective moves, warning traders to manage risk proactively.
Market Context : The indicator does not dictate direction; instead, it overlays strength on top of price action, allowing traders to combine it with directional tools such as moving averages, order blocks, or liquidity zones for confirmation.
Strategy Integration
ADX Tide Zones adapts seamlessly to a wide range of trading strategies by translating momentum dynamics into actionable frameworks:
Trend Following : Traders can align with dominant flows by entering positions when the indicator confirms a Rising Tide or Strong Tide. These conditions signal persistent directional strength, making them ideal for continuation setups. Combining directional bias with ADX confirmation reduces the risk of trading against prevailing momentum.
Breakout Trading : When the market transitions from Calm Tide into a Rising Tide, it often precedes a volatility expansion. This shift highlights breakout conditions where accumulation gives way to impulsive price movement. Traders can use this transition as a timing tool to catch early entries into new momentum phases.
Exhaustion Reversals : Strong Tide phases don’t last forever—when they begin to fade into Falling Tide, it can mark trend fatigue or liquidity exhaustion. This offers contrarian traders an early edge in spotting overextended moves and positioning for corrective pullbacks or full reversals.
Multi-Timeframe Analysis : By overlaying higher timeframe tide zones on intraday or scalping charts, traders can filter noise and trade in alignment with larger flows. For example, combining a daily Rising Tide bias with a 15-minute breakout confirmation can significantly improve entry precision while reducing exposure to false signals.
Advanced Techniques
For traders seeking an extra edge, ADX Tide Zones can be pushed further with advanced methods:
Volume & Liquidity Confirmation : Pair the tide transitions with volume spikes, order flow, or liquidity sweep tools. When directional strength confirmed by the ADX coincides with institutional activity, it validates setups and increases probability of follow-through.
Cross-Asset Synchronization : Momentum rarely exists in isolation. Monitoring tide shifts across correlated instruments (e.g., majors vs. USD, or indices vs. risk assets) can uncover synchronized volatility events. These correlations help traders identify whether a move is isolated noise or part of a broader systemic trend.
Threshold Optimization : The sensitivity of ADX Tide Zones can be fine-tuned for different trading objectives. Lower thresholds heighten responsiveness, capturing micro-moves suitable for scalpers. Higher thresholds filter minor fluctuations, isolating major structural swings that align with swing or position trading.
Contextual Trade Management : Instead of using static stops or targets, traders can adapt risk management dynamically by tracking tide progression. For example, a trade initiated during Rising Tide may remain valid as long as conditions sustain, but partial profits or tighter stops can be applied once the zone shifts to Calm Tide.
Inputs & Customization
ADX Length : Define the lookback period for ADX calculation.
Threshold Levels : Adjust sensitivity for Calm, Rising, Strong, and Falling Tides.
Zone Visualization : Choose between bar coloring, background shading, or overlays.
Color Customization : Configure bullish, bearish, neutral, and tide-specific colors.
Multi-Timeframe Options : Enable tide readings from higher timeframes for confirmation.
Why Use ADX Tide Zones
ADX Tide Zones turns the complexity of momentum analysis into a visual system that highlights when markets are gearing up for moves, trending with conviction, or running out of steam. By combining adaptive ADX interpretation with customizable thresholds, traders can:
Anticipate breakouts before volatility expands.
Confirm the strength behind price trends.
Spot exhaustion phases early to secure profits or prepare for reversals.
Adapt strategies seamlessly between scalping, intraday, and swing trading.
With its balance of simplicity and depth, ADX Tide Zones provides a structured lens for reading market momentum, equipping traders with the clarity needed to execute with discipline and confidence.
FREE Camel-Style Cycle Projector V2This indicator helps visualize repeating market cycles by detecting pivot lows and projecting when the next cycle low may occur.
How it works
• Pivot detection: Uses left/right bars to confirm swing lows. Filters are included (minimum % move and optional ATR separation) so only significant lows are counted.
• Cycle averaging: The script records the time between past pivot lows. It then calculates the average (and standard deviation) of the last N intervals.
• Projection: A future “Cycle Low ETA” is calculated as:
last pivot low time + average interval.
If that projection is already in the past, the script rolls forward by whole average intervals until it lies strictly in the future.
• Time window: Around the ETA, a shaded projection window is drawn. Traders can choose whether this is based on a multiple of the standard deviation or a percentage of the average.
• Visualization:
• Vertical line = projected cycle low.
• Shaded box = timing window.
• Label = humanized countdown (weeks/days/hours/minutes).
• HUD = status, ETA info, number of intervals used.
• Optional “Camel row” under the chart (triangle • W • 🐪 • cycle length in weeks) to make cycles easier to spot at a glance.
How to use
• Select your timeframe (works on intraday and higher).
• Allow pivots to accumulate; once the HUD shows Status: OK, the script begins projecting cycle lows.
• Use the ETA line and window as context: they do not provide direct buy/sell signals, but rather help estimate when the market is statistically more likely to form a new cycle low.
• Best used together with price structure, liquidity levels, support/resistance, and your own trading strategy.
Notes
• Works with any market supported on TradingView (crypto, stocks, forex, indices).
• Filters can be tuned to reduce noise:
• Increase % move or ATR multiplier to focus on larger, more meaningful lows.
• This tool is designed for cycle timing analysis only. It does not predict exact prices or guarantee market outcomes
Edric TrendThis is a very simple way for Trend by using Ema.
Created by Edric Le Hoang Dung (lehodu) from Vietnam
Options Greeks AnalyzerOptions Greeks Analyzer (Training & Learning Guide)
________________________________________
1. Introduction
Options trading is advanced compared to regular stock trading, and one of the most important aspects is Options Greeks. Greeks are mathematical values that measure how the price of an option will react to changes in various factors such as the underlying asset’s price, volatility, interest rates, and time to expiry.
This Options Greeks Analyzer tool is built using TradingView Pine Script v5. It serves as a real time training and analysis dashboard that helps learners visualize how options greeks behave, how option prices change, and how traders can make informed decisions.
📌 Educational Disclaimer:
This tool is only for training and learning purposes. It is not a financial advice tool nor to be used for live trading decisions. The data shown is theoretical Black Scholes model calculations, which may differ from actual option market prices.
________________________________________
2. How the Tool Works
The Options Greeks Analyzer is divided into different modules. Below is a step by step walkthrough:
________________________________________
Step 1: User Inputs
• Implied Volatility (IV%) — You can manually enter volatility, which is the most important factor in option pricing. Higher IV = higher option premium.
• Expiry Selection — Choose from preset durations like 7D, 14D, 30D etc. Days to expiry directly affect time decay (Theta).
• Strike Price Mode — You can select either:
o ATM (At-the-Money = Current price of stock/index)
o Custom strike (Enter your own strike price)
• Risk-Free Rate (%) — A small interest rate factor (like government bond yield) used for theoretical valuation.
• Table Customization — Choose table size, position, and whether to show price lines for easy visibility.
________________________________________
Step 2: Market Data & Volatility
• The tool takes the current market price (Spot Price) as input.
• It calculates realized volatility from historical price fluctuations (using past 30 bars/log returns).
• Implied Volatility (manual input) is then compared to realized vol:
o If IV > Historical Volatility → Market pricing is “expensive” (HIGH IV RANK).
o If IV < Historical Volatility → Market is “cheap” (LOW IV RANK).
o Otherwise, it’s MEDIUM.
📌 Why it matters?
Traders can decide whether buying or selling options is favorable. Beginners learn that timing entry with volatility is more critical than just looking at market direction.
________________________________________
Step 3: Black-Scholes Formula
The core engine uses the Black-Scholes model, a mathematical formula widely used to compute option fair prices.
It uses the following inputs:
• Current price (Spot)
• Strike Price
• Time to Expiry (T)
• Risk Free Rate (r)
• Implied Volatility (σ)
This produces:
• Call Option Price
• Put Option Price
📌 This teaches learners how premiums are derived theoretically and why the same strike can have different values depending on IV and time.
________________________________________
Step 4: Option Greeks Calculation
The tool computes the first order Greeks:
• Delta → Measures how much the option price changes when the underlying stock moves by 1 point.
(Call Delta ranges 0–1, Put Delta ranges -1 to 0).
• Gamma → Sensitivity of Delta to price change. A measure of volatility risk.
• Theta → Time decay. Shows how much value option loses as each day passes. Calls and Puts have negative Theta (decay).
• Vega → Measures how sensitive option price is to volatility changes.
• Rho → Interest rate sensitivity. Mostly minor in equity options but important for training.
📌 New traders learn how each factor impacts profits/losses. Instead of random guessing, they see mathematical impact in numbers.
________________________________________
Step 5: Dashboard & Visualization
The tool builds a professional dashboard table on the chart.
It shows categories such as:
1. Asset Info — Spot, Strike, DTE (days to expiry), IV%, IV Rank, 1-Day Trend, Moneyness (ATM/OTM/ITM).
2. Option Prices — Call, Put, Break-even levels, Time Value, Expected Move (%), Realized vs Implied Vol.
3. Greeks with Visual Progress Bars — Easily shows Delta, Gamma, Vega, Theta, Rho in intuitive graphical representations.
4. Status Bar — Suggests theoretical bias like:
o HIGH IV → Favor Option Selling
o LOW IV → Favor Option Buying
o MEDIUM → Neutral observation
5. Recommendation Line — Offers training-based suggestions like “Buy Straddles”, “Sell Call Spreads”, etc. These are not signals, but scenarios to learn strategies.
________________________________________
3. How It Helps Beginners
1. Learn Greeks in Action:
Beginners often memorize formulas but never see real-time changes. This dashboard updates every bar to show how Greeks change dynamically.
2. Compare Volatilities:
Traders understand difference between historical vs implied volatility and why option premiums behave differently.
3. Understand Risk Levels:
The tool highlights when Gamma risk is high (danger for sellers) or when Theta is most favorable.
4. Training Mode for Strategies:
Helps beginners experiment by changing IV, strike, expiry and seeing how straddles, spreads, naked options would behave theoretically.
5. Prepares Before Live Trading:
Safe environment to practice option analysis without risking capital.
________________________________________
4. Educational Use Cases
• Scenario 1: Change expiry from 7D to 30D — see how Theta becomes slower for longer expiries.
• Scenario 2: Increase IV from 25% to 80% — watch how option premiums inflate, and recommendation changes from “Buy” to “Sell”.
• Scenario 3: Select OTM vs ITM strikes — check how delta moves from near 0 to near 1.
By running these scenarios, learners understand why professional traders hedge Greeks instead of directional gambling.
________________________________________
5. Disclaimer
This Options Greeks Analyzer is built strictly for educational and training purposes.
• It uses theoretical formulas (Black-Scholes) that may not match actual option market prices.
• The recommendations are for learning strategy logic only, not real-world execution signals.
• Trading in options carries significant risks and may result in capital loss.
📌 Always consult with a financial advisor before applying real strategies.
________________________________________
✅ Summary
This Options Greeks Analyzer:
• Teaches how Greeks, IV, and premiums work.
• Provides a real-time interactive dashboard for training.
• Helps beginners practice option scenarios safely.
• Is meant strictly for learning and not live trading execution.
________________________________________
________________________________________
Disclaimer from aiTrendview
This script and its trading signals are provided for training and educational purposes only. They do not constitute financial advice or a guaranteed trading system. Trading involves substantial risk, and there is the potential to lose all invested capital. Users should perform their own analysis and consult with qualified financial professionals before making any trading decisions. aiTrendview disclaims any liability for losses incurred from using this code or trading based on its signals. Use this tool responsibly, and trade only with risk capital.
COT REPORT by QDEEDCOT Report
Red Line= Commercials
Blue Line= Large Speculators
Green Line= Small Traders (Retail)
Use on the Weekly Chart.
COT INDEX by qdeedCOT Index
Calculation; COT Index = ((Current Net Position – Lowest Value in the Period) / (Highest Value in the Period – Lowest Value in the Period)) * 100
Use on the weekly timeframe.
VWMA CandlesVWMA Candles – Smarter Candle Coloring with Volume Awareness
This indicator enhances your chart candles by showing their relationship to the Volume-Weighted Moving Average (VWMA). It visually integrates the VWMA and price action, making it easier to spot momentum shifts, value zones, and price interaction with volume-weighted levels. I saw this indicator idea from TrendSpider on threads and decided to try and make my own. This is my first publicly shared script so go easy on me!
IN ORDER FOR THE COLOR CODING TO WORK PROPERLY, YOU MUST:
GO TO -> CHART SETTINGS -> SYMBOLS AND DISABLE BODIES, BORDERS, AND WICKS.
How it works:
The VWMA is plotted on your chart with a customizable band around it.
Candles change color depending on their position relative to the VWMA and its band:
Green → Price is above the VWMA (bullish bias).
Orange → Price is near or touching the VWMA/band (potential reaction zone).
Red → Price is below the VWMA (bearish bias).
You can choose between custom candles (full plotcandle styling) or simply recolor your existing chart candles with barcolor.
Customization options:
Select how the band is calculated: by % of VWMA, ATR multiple, or Ticks/Points.
Adjust colors separately for candle body, wick, and border.
Choose to show/hide the VWMA line and the band fill.
Fine-tune transparency for a clean look on any chart background.
Why traders use it:
Quickly spot when price is stretched away from the VWMA (overextended conditions).
Identify when candles are interacting with the VWMA (potential support/resistance).
Add volume-sensitivity to your trend analysis compared to standard moving averages.
Authors Note: The default settings work well with stocks on the weekly timeframe, although this can be used on any timeframe. The settings are highly adjustable for you to tune it to your liking.
POC Migration Velocity (POC-MV) [PhenLabs]📊POC Migration Velocity (POC-MV)
Version: PineScript™v6
📌Description
The POC Migration Velocity indicator revolutionizes market structure analysis by tracking the movement, speed, and acceleration of Point of Control (POC) levels in real-time. This tool combines sophisticated volume distribution estimation with velocity calculations to reveal hidden market dynamics that conventional indicators miss.
POC-MV provides traders with unprecedented insight into volume-based price movement patterns, enabling the early identification of continuation and exhaustion signals before they become apparent to the broader market. By measuring how quickly and consistently the POC migrates across price levels, traders gain early warning signals for significant market shifts and can position themselves advantageously.
The indicator employs advanced algorithms to estimate intra-bar volume distribution without requiring lower timeframe data, making it accessible across all chart timeframes while maintaining sophisticated analytical capabilities.
🚀Points of Innovation
Micro-POC calculation using advanced OHLC-based volume distribution estimation
Real-time velocity and acceleration tracking normalized by ATR for cross-market consistency
Persistence scoring system that quantifies directional consistency over multiple periods
Multi-signal detection combining continuation patterns, exhaustion signals, and gap alerts
Dynamic color-coded visualization system with intensity-based feedback
Comprehensive customization options for resolution, periods, and thresholds
🔧Core Components
POC Calculation Engine: Estimates volume distribution within each bar using configurable price bands and sophisticated weighting algorithms
Velocity Measurement System: Tracks the rate of POC movement over customizable lookback periods with ATR normalization
Acceleration Calculator: Measures the rate of change of velocity to identify momentum shifts in POC migration
Persistence Analyzer: Quantifies how consistently POC moves in the same direction using exponential weighting
Signal Detection Framework: Combines trend analysis, velocity thresholds, and persistence requirements for signal generation
Visual Rendering System: Provides dynamic color-coded lines and heat ribbons based on velocity and price-POC relationships
🔥Key Features
Real-time POC calculation with 10-100 configurable price bands for optimal precision
Velocity tracking with customizable lookback periods from 5 to 50 bars
Acceleration measurement for detecting momentum changes in POC movement
Persistence scoring to validate signal strength and filter false signals
Dynamic visual feedback with blue/orange color scheme indicating bullish/bearish conditions
Comprehensive alert system for continuation patterns, exhaustion signals, and POC gaps
Adjustable information table displaying real-time metrics and current signals
Heat ribbon visualization showing price-POC relationship intensity
Multiple threshold settings for customizing signal sensitivity
Export capability for use with separate panel indicators
🎨Visualization
POC Connecting Lines: Color-coded lines showing POC levels with intensity based on velocity magnitude
Heat Ribbon: Dynamic colored ribbon around price showing POC-price basis intensity
Signal Markers: Clear exhaustion top/bottom signals with labeled shapes
Information Table: Real-time display of POC value, velocity, acceleration, basis, persistence, and current signal status
Color Gradients: Blue gradients for bullish conditions, orange gradients for bearish conditions
📖Usage Guidelines
POC Calculation Settings
POC Resolution (Price Bands): Default 20, Range 10-100. Controls the number of price bands used to estimate volume distribution within each bar
Volume Weight Factor: Default 0.7, Range 0.1-1.0. Adjusts the influence of volume in POC calculation
POC Smoothing: Default 3, Range 1-10. EMA smoothing period applied to the calculated POC to reduce noise
Velocity Settings
Velocity Lookback Period: Default 14, Range 5-50. Number of bars used to calculate POC velocity
Acceleration Period: Default 7, Range 3-20. Period for calculating POC acceleration
Velocity Significance Threshold: Default 0.5, Range 0.1-2.0. Minimum normalized velocity for continuation signals
Persistence Settings
Persistence Lookback: Default 5, Range 3-20. Number of bars examined for persistence score calculation
Persistence Threshold: Default 0.7, Range 0.5-1.0. Minimum persistence score required for continuation signals
Visual Settings
Show POC Connecting Lines: Toggle display of colored lines connecting POC levels
Show Heat Ribbon: Toggle display of colored ribbon showing POC-price relationship
Ribbon Transparency: Default 70, Range 0-100. Controls transparency level of heat ribbon
Alert Settings
Enable Continuation Alerts: Toggle alerts for continuation pattern detection
Enable Exhaustion Alerts: Toggle alerts for exhaustion pattern detection
Enable POC Gap Alerts: Toggle alerts for significant POC gaps
Gap Threshold: Default 2.0 ATR, Range 0.5-5.0. Minimum gap size to trigger alerts
✅Best Use Cases
Identifying trend continuation opportunities when POC velocity aligns with price direction
Spotting potential reversal points through exhaustion pattern detection
Confirming breakout validity by monitoring POC gap behavior
Adding volume-based context to traditional technical analysis
Managing position sizing based on POC-price basis strength
⚠️Limitations
POC calculations are estimations based on OHLC data, not true tick-by-tick volume distribution
Effectiveness may vary in low-volume or highly volatile market conditions
Requires complementary analysis tools for complete trading decisions
Signal frequency may be lower in ranging markets compared to trending conditions
Performance optimization needed for very short timeframes below 1-minute
💡What Makes This Unique
Advanced Estimation Algorithm: Sophisticated method for calculating POC without requiring lower timeframe data
Velocity-Based Analysis: Focus on POC movement dynamics rather than static levels
Comprehensive Signal Framework: Integration of continuation, exhaustion, and gap detection in one indicator
Dynamic Visual Feedback: Intensity-based color coding that adapts to market conditions
Persistence Validation: Unique scoring system to filter signals based on directional consistency
🔬How It Works
Volume Distribution Estimation:
Divides each bar into configurable price bands for volume analysis
Applies sophisticated weighting based on OHLC relationships and proximity to close
Identifies the price level with maximum estimated volume as the POC
Velocity and Acceleration Calculation:
Measures POC rate of change over specified lookback periods
Normalizes values using ATR for consistent cross-market performance
Calculates acceleration as the rate of change of velocity
Signal Generation Process:
Combines trend direction analysis using EMA crossovers
Applies velocity and persistence thresholds to filter signals
Generates continuation, exhaustion, and gap alerts based on specific criteria
💡Note:
This indicator provides estimated POC calculations based on available OHLC data and should be used in conjunction with other analysis methods. The velocity-based approach offers unique insights into market structure dynamics but requires proper risk management and complementary analysis for optimal trading decisions.
Machine Learning-Inspired Supply & Demand Zones [AlgoPoint]This indicator is a Smart Supply & Demand Zone tool, developed with principles inspired by Machine Learning (ML). It intelligently filters out market noise, allowing you to focus only on the most significant zones where institutional order flow is likely present.
💡 How It Works: Why Is This Indicator "Smart"?
Unlike traditional indicators that only measure simple price movements, this script uses an algorithm that asks the same critical questions an experienced market analyst would to qualify a zone:
- 1. Price Imbalance: How fast and aggressively did the price leave the zone? Our algorithm measures the body size of the "departure candle" relative to the current market volatility (ATR). A zone is only considered if it was formed by an explosive move that is statistically significant, indicating a major imbalance between buyers and sellers.
- 2. Volume Confirmation: Did the "smart money" participate in this move? The script checks if the volume on the departure candle was significantly higher than the recent average volume. A spike in volume confirms that the move was backed by institutional interest, adding strength and validity to the zone.
- 3. Valid Pivot Structure: Did the zone originate from a meaningful swing high or low? The algorithm first identifies a valid pivot structure, ensuring that zones are not drawn from insignificant or random price fluctuations.
Only when a potential zone passes these three critical tests—our "quality filter"—is it drawn on your chart.
🚀 Features & How to Use
Using the indicator is straightforward. You will see two primary types of boxes on your chart:
* 🟥 Red Box (Supply Zone): An area of potential resistance where selling pressure is likely to be strong. Look for potential shorting opportunities as the price approaches this zone.
* 🟩 Green Box (Demand Zone): An area of potential support where buying pressure is likely to be strong. Look for potential long opportunities as the price pulls back into this zone.
Dynamic Zone Management
This indicator is not static; it lives and breathes with the market:
- Fresh Zone: A newly formed zone appears in its full, vibrant color. These are the highest-probability zones as they have not yet been re-tested.
- Broken / Flipped Zone: You have full control over what happens when a zone is broken! In the settings, you can choose:
- Delete Zone: The zone will be removed completely when the price closes through it.
- Show as Broken (Flip): When broken, the zone will turn gray, stop extending, and remain on your chart. This is extremely useful for identifying Support/Resistance Flips, where a broken demand zone becomes new resistance, or a broken supply zone becomes new support.
⚙️ Settings & Customization
Fine-tune the indicator to match your personal trading style via the settings menu:
- Breakout Behavior: The most powerful feature. Choose between Delete Zone and Show as Broken (Flip) to customize your chart.
- Zone Finding Logic: Control the indicator's sensitivity.
- Selective: Requires both strong imbalance and high volume. Finds fewer, but higher-quality, zones.
- Moderate: Requires either strong imbalance or high volume. Finds more potential zones.
- Sensitivity Settings: Adjust the ATR Multiplier and Volume Multiplier to make the criteria for a "strong" zone stricter or looser.
BE-Fib Channel 2 Sided Trading█ Overview:
"BE-Fib Channel 2 Sided Trading" indicator is built with the thought of 2 profound setups named "Cup & Handle (C&H)" and "Fibonacci Channel Trading (FCT)" with the context of "day trading" or with a minimum holding period.
█ Similarities, Day Trading Context & Error Patterns:
While the known fact is that both C&H and FCT provide setups with lesser risk with bigger returns, they both share the similar "Base Pattern".
Note: Inverse of the above Image shall switch the setups between long vs short.
Since the indicator is designed for smaller time-frame candles, there may be instances where the "base pattern" does not visually resemble a Cup & Handle (C&H) pattern. However, patterns are validated using pivot points. The points labeled "A" and "C" can be equal or slightly slanted. Settings of the Indicator allows traders a flexibility to control the angle of these points to spot the strategies according to set conditions. Therefore, understanding the nuances of these patterns is crucial for effective decision-making.
█ 2 Sided Edge: FCT suggests to take trade closer to the yellow line to get better RR ratio. this leaves a small chance of doubt as to; what if price is intended to break the Yellow line thereby activating the C&H.
Wait for the confirmation is a Big FOMO with a compromised RR.
Hence, This indicator is designed to handle both the patterns based on the strength, FIFO and pattern occurring delay.
█ How to Use this Indicator:
Step 1: Enable the Show Sample Sensitivity option to understand the angle of yellow line shown in the sample image. By enabling this option, On the last bar you shall see 4 lines being plotted depicting the max angle which is acceptable for both long and short trades.
Note: Angle can be controlled via setting "Sensitivity".
Higher Sensitivity --> Higher Setup identification --> can lead to failed setups due to 2 sided trading.
Lower Sensitivity --> Lower Setup identification --> can increase the changes of being right.
Step 2: Adjust the look back & look forward periods which shall be used for identifying patterns.
Note: Smaller values can lead to more setups being identified but can hamper the performance of the indicator while increasing the chances of failures. larger values identifies more significant setup but leads to more waiting period thereby compromising on the RR.
Step 3: Adjust the Base Range.
Note: Smaller values can lead to more setups being identified but can hamper the performance of the indicator while increasing the chances of failures. larger values identifies more significant setup but leads to more Risk on play.
Step 4: set the Entry level for FCT & Set the SL for Both FCT & C&H and Target Reward ratio for C&H.
█ Features of Indicator & How it works:
1. Patterns are being identified using Pivot Points method.
2. Tracks & validates both the setups simultaneously on every candle and traded one at a time based on FIFO, New setups found in-between, Defined Entry Levels while on wait for the other pattern to get activated.
3. Alerts added for trade events.
4. FCT setups are generally traded with trailed SL level and increasing Target level on every completed bar. while C&H has the standard SL & TP level with no Trail SL option.
DISCLAIMER: No sharing, copying, reselling, modifying, or any other forms of use are authorized for our documents, script / strategy, and the information published with them. This informational planning script / strategy is strictly for individual use and educational purposes only. This is not financial or investment advice. Investments are always made at your own risk and are based on your personal judgement. I am not responsible for any losses you may incur. Please invest wisely.
Happy to receive suggestions and feedback in order to improve the performance of the indicator better.
Ichimoku Cloud Advanced [CongTrader]Ichimoku Cloud Advanced
Overview
Ichimoku Cloud Advanced is a refined version of the classic Ichimoku system. It combines the power of the original Ichimoku framework with practical enhancements, including:
Crypto & Traditional Presets for flexible use in multiple markets.
EMA200 Trend Filter to help reduce false signals and highlight strong market direction.
Signal Table & Labels to visualize entry/exit signals clearly.
Smart Alerts for Tenkan/Kijun crosses and Kumo breakouts.
Designed for traders who want to capture momentum, confirm trends, and manage positions more effectively in crypto, forex, and stocks.
Unique Value
Unlike standard Ichimoku indicators, this tool focuses on:
Adaptability: Ready-made presets for crypto volatility or traditional markets.
Clarity: Built-in labels, status table, and optional signals.
Risk Awareness: Encourages users to filter trades with EMA200, not just raw Ichimoku signals.
This makes it a balanced tool for trend confirmation, swing entries, and scalping setups.
How to Use
Choose a Preset → Traditional (9/26/52) or Crypto (fast/medium) depending on your market.
Enable EMA200 Filter → Use it to avoid trading against major market direction.
Watch Signals → Buy/Sell labels, status table updates, and alerts will guide you.
Set Alerts → Get notified when Tenkan crosses Kijun or when price breaks out of the Kumo cloud.
Quick Guide
Crypto Short-Term: Use fast preset for scalping volatile coins.
Stocks/Forex: Traditional settings align well with daily/weekly analysis.
Trend Filter: Always check EMA200 color and slope for context.
Alerts: Configure them to avoid missing strong trend entries.
Disclaimer
This indicator is a decision-support tool, not a guaranteed profit system. Trading involves risk, and past performance does not guarantee future results. Always:
Manage your risk and position size.
Use stop-loss and take-profit levels.
Consider market context before making decisions.
We do not provide financial advice. Use at your own discretion.
Acknowledgments
Original Ichimoku Kinko Hyo system created by Goichi Hosoda.
Enhanced and adapted by CongTrader for modern markets.
Thank you for using this tool! Your feedback and suggestions are always welcome to make it better.
🚀 Start testing Ichimoku Cloud Advanced today and experience a clearer, smarter way to apply one of the most respected trading systems.
#Ichimoku #IchimokuCloud #Kumo #Tenkan #Kijun #Chikou #CloudBreakout #TKCross #EMA200 #TrendFilter #Momentum #SwingTrading #Scalping #RiskManagement #MultiTimeframe #Alerts #Crypto #Forex #Stocks #Futures #Spot #PriceAction #TechnicalAnalysis #TradingViewIndicator
Morning Gap Reversal ScannerMorning indicator for morning fluctuation. Seeing what starts low and moves up in first 30 minutes