FluxGate Daily Swing Strategy Summary in one paragraph
FluxGate treats long and short as different ecosystems. It runs two independent engines so the long side can be bold when the tape rewards upside persistence while the short side can stay selective when downside is messy. The core reads three directional drivers from price geometry then removes overlap before gating with clean path checks. The complementary risk module anchors stop distance to a higher timeframe ATR so a unit means the same thing on SPY and BTC. It can add take profit breakeven and an ATR trail that only activates after the trade earns it. If a stop is hit the strategy can re enter in the same direction on the next bar with a daily retry cap that you control. Add it to a clean chart. Use defaults to see the intended behavior. For conservative workflows evaluate on bar close.
Scope and intent
• Markets. Large cap equities and liquid ETFs major FX pairs US index futures and liquid crypto pairs
• Timeframes. From one minute to daily
• Default demo in this publication. SPY on one day timeframe
• Purpose. Reduce false starts without missing sustained trends by fusing independent drivers and suppressing activity when the path is noisy
• Limits. This is a strategy. Orders are simulated on standard candles. Non standard chart types are not supported for execution
Originality and usefulness
• Unique fusion. FluxGate extracts three drivers that look at price from different angles. Direction measures slope of a smoothed guide and scales by realized volatility so a point of slope does not mean a different thing on different symbols. Persistence looks at short sign agreement to reward series of closes that keep direction. Curvature measures the second difference of a local fit to wake up during convex pushes. These three are then orthonormalized so a strong reading in one does not double count through another.
• Gates that matter. Efficiency ratio prefers direct paths over treadmills. Entropy turns up versus down frequency into an information read. Light fractal cohesion punishes wrinkly paths. Together they slow the system in chop and allow it to open up when the path is clean.
• Separate long and short engines. Threshold tilts adapt to the skew of score excursions. That lets long engage earlier when upside distribution supports it and keeps short cautious where downside surprise and venue frictions are common.
• Practical risk behavior. Stops are ATR anchored on a higher timeframe so the unit is portable. Take profit is expressed in R so two R means the same concept across symbols. Breakeven and trailing only activate after a chosen R so early noise does not squeeze a good entry. Re entry after stop lets the system try again without you babysitting the chart.
• Testability. Every major window and the aggression controls live in Inputs. There is no hidden magic number.
Method overview in plain language
Base measures
• Return basis. Natural log of close over prior close for stability and easy aggregation through time. Realized volatility is the standard deviation of returns over a moving window.
• Range basis for risk. ATR computed on a higher timeframe anchor such as day week or month. That anchor is steady across venues and avoids chasing chart specific quirks.
Components
• Directional intensity. Use an EMA of typical price as a guide. Take the day to day slope as raw direction. Divide by realized volatility to get a unit free measure. Soft clip to keep outliers from dominating.
• Persistence. Encode whether each bar closed up or down. Measure short sign agreement so a string of higher closes scores better than a jittery sequence. This favors push continuity without guessing tops or bottoms.
• Curvature. Fit a short linear regression and compute the second difference of the fitted series. Strong curvature flags acceleration that slope alone may miss.
• Efficiency gate. Compare net move to path length over a gate window. Values near one indicate direct paths. Values near zero indicate treadmill behavior.
• Entropy gate. Convert up versus down frequency into a probability of direction. High entropy means coin toss. The gate narrows there.
• Fractal cohesion. A light read of path wrinkliness relative to span. Lower cohesion reduces the urge to act.
• Phase assist. Map price inside a recent channel to a small signed bias that grows with confidence. This helps entries lean toward the right half of the channel without becoming a breakout rule.
• Shock control. Compare short volatility to long volatility. When short term volatility spikes the shock gate temporarily damps activity so the system waits for pressure to normalize.
Fusion rule
• Normalize the three drivers after removing overlap
• Blend with weights that adapt to your aggression input
• Multiply by the gates to respect path quality
• Smooth just enough to avoid jitter while keeping timing responsive
• Compute an adaptive mean and deviation of the score and set separate long and short thresholds with a small tilt informed by skew sign
• The result is one long score and one short score that can cross their thresholds at different times for the same tape which is a feature not a bug
Signal rule
• A long suggestion appears when the long score crosses above its long threshold while all gates are active
• A short suggestion appears when the short score crosses below its short threshold while all gates are active
• If any required gate is missing the state is wait
• When a position is open the status is in long or in short until the complementary risk engine exits or your entry mode closes and flips
Inputs with guidance
Setup Long
• Base length Long. Master window for the long engine. Typical range twenty four to eighty. Raising it improves selectivity and reduces trade count. Lowering it reacts faster but can increase noise
• Aggression Long. Zero to one. Higher values make thresholds more permissive and shorten smoothing
Setup Short
• Base length Short. Master window for the short engine. Typical range twenty eight to ninety six
• Aggression Short. Zero to one. Lower values keep shorts conservative which is often useful on upward drifting symbols
Entries and UI
• Entry mode. Both or Long only or Short only
Complementary risk engine
• Enable risk engine. Turns on bracket exits while keeping your signal logic untouched
• ATR anchor timeframe. Day Week or Month. This sets the structural unit of stop distance
• ATR length. Default fourteen
• Stop multiple. Default one point five times the anchor ATR
• Use take profit. On by default
• Take profit in R. Default two R
• Breakeven trigger in R. Default one R
Usage recipes
Intraday trend focus
• Entry mode Both
• ATR anchor Week
• Aggression Long zero point five Aggression Short zero point three
• Stop multiple one point five Take profit two R
• Expect fewer trades that stick to directional pushes and skip treadmill noise
Intraday mean reversion focus
• Session windows optional if you add them in your copy
• ATR anchor Day
• Lower aggression both sides
• Breakeven later and trailing later so the first bounce has room
• This favors fade entries that still convert into trends when the path stays clean
Swing continuation
• Signal timeframe four hours or one day
• Confirm timeframe one day if you choose to include bias
• ATR anchor Week or Month
• Larger base windows and a steady two R target
• This accepts fewer entries and aims for larger holds
Properties visible in this publication
• Initial capital 25.000
• Base currency USD
• Default order size percent of equity value three - 3% of the total capital
• Pyramiding zero
• Commission zero point zero three percent - 0.03% of total capital
• Slippage five ticks
• Process orders on close off
• Recalculate after order is filled off
• Calc on every tick off
• Bar magnifier off
• Any request security calls use lookahead off everywhere
Realism and responsible publication
• No performance promises. Past results never guarantee future outcomes
• Fills and slippage vary by venue and feed
• Strategies run on standard candles only
• Shapes can update while a bar is forming and settle on close
• Keep risk per trade sensible. Around one percent is typical for study. Above five to ten percent is rarely sustainable
Honest limitations and failure modes
• Sudden news and thin liquidity can break assumptions behind entropy and cohesion reads
• Gap heavy symbols often behave better with a True Range basis for risk than a simple range
• Very quiet regimes can reduce score contrast. Consider longer windows or higher thresholds when markets sleep
• Session windows follow the exchange time of the chart if you add them
• If stop and target can both be inside a single bar this strategy prefers stop first to keep accounting conservative
Open source reuse and credits
• No reused open source beyond public domain building blocks such as ATR EMA and linear regression concepts
Legal
Education and research only. Not investment advice. You are responsible for your decisions. Test on history and in simulation with realistic costs
Bitcoin (Criptovaluta)
Quantum Flux Universal Strategy Summary in one paragraph
Quantum Flux Universal is a regime switching strategy for stocks, ETFs, index futures, major FX pairs, and liquid crypto on intraday and swing timeframes. It helps you act only when the normalized core signal and its guide agree on direction. It is original because the engine fuses three adaptive drivers into the smoothing gains itself. Directional intensity is measured with binary entropy, path efficiency shapes trend quality, and a volatility squash preserves contrast. Add it to a clean chart, watch the polarity lane and background, and trade from positive or negative alignment. For conservative workflows use on bar close in the alert settings when you add alerts in a later version.
Scope and intent
• Markets. Large cap equities and ETFs. Index futures. Major FX pairs. Liquid crypto
• Timeframes. One minute to daily
• Default demo used in the publication. QQQ on one hour
• Purpose. Provide a robust and portable way to detect when momentum and confirmation align, while dampening chop and preserving turns
• Limits. This is a strategy. Orders are simulated on standard candles only
Originality and usefulness
• Unique concept or fusion. The novelty sits in the gain map. Instead of gating separate indicators, the model mixes three drivers into the adaptive gains that power two one pole filters. Directional entropy measures how one sided recent movement has been. Kaufman style path efficiency scores how direct the path has been. A volatility squash stabilizes step size. The drivers are blended into the gains with visible inputs for strength, windows, and clamps.
• What failure mode it addresses. False starts in chop and whipsaw after fast spikes. Efficiency and the squash reduce over reaction in noise.
• Testability. Every component has an input. You can lengthen or shorten each window and change the normalization mode. The polarity plot and background provide a direct readout of state.
• Portable yardstick. The core is normalized with three options. Z score, percent rank mapped to a symmetric range, and MAD based Z score. Clamp bounds define the effective unit so context transfers across symbols.
Method overview in plain language
The strategy computes two smoothed tracks from the chart price source. The fast track and the slow track use gains that are not fixed. Each gain is modulated by three drivers. A driver for directional intensity, a driver for path efficiency, and a driver for volatility. The difference between the fast and the slow tracks forms the raw flux. A small phase assist reduces lag by subtracting a portion of the delayed value. The flux is then normalized. A guide line is an EMA of a small lead on the flux. When the flux and its guide are both above zero, the polarity is positive. When both are below zero, the polarity is negative. Polarity changes create the trade direction.
Base measures
• Return basis. The step is the change in the chosen price source. Its absolute value feeds the volatility estimate. Mean absolute step over the window gives a stable scale.
• Efficiency basis. The ratio of net move to the sum of absolute step over the window gives a value between zero and one. High values mean trend quality. Low values mean chop.
• Intensity basis. The fraction of up moves over the window plugs into binary entropy. Intensity is one minus entropy, which maps to zero in uncertainty and one in very one sided moves.
Components
• Directional Intensity. Measures how one sided recent bars have been. Smoothed with RMA. More intensity increases the gain and makes the fast and slow tracks react sooner.
• Path Efficiency. Measures the straightness of the price path. A gamma input shapes the curve so you can make trend quality count more or less. Higher efficiency lifts the gain in clean trends.
• Volatility Squash. Normalizes the absolute step with Z score then pushes it through an arctangent squash. This caps the effect of spikes so they do not dominate the response.
• Normalizer. Three modes. Z score for familiar units, percent rank for a robust monotone map to a symmetric range, and MAD based Z for outlier resistance.
• Guide Line. EMA of the flux with a small lead term that counteracts lag without heavy overshoot.
Fusion rule
• Weighted sum of the three drivers with fixed weights visible in the code comments. Intensity has fifty percent weight. Efficiency thirty percent. Volatility twenty percent.
• The blend power input scales the driver mix. Zero means fixed spans. One means full driver control.
• Minimum and maximum gain clamps bound the adaptive gain. This protects stability in quiet or violent regimes.
Signal rule
• Long suggestion appears when flux and guide are both above zero. That sets polarity to plus one.
• Short suggestion appears when flux and guide are both below zero. That sets polarity to minus one.
• When polarity flips from plus to minus, the strategy closes any long and enters a short.
• When flux crosses above the guide, the strategy closes any short.
What you will see on the chart
• White polarity plot around the zero line
• A dotted reference line at zero named Zen
• Green background tint for positive polarity and red background tint for negative polarity
• Strategy long and short markers placed by the TradingView engine at entry and at close conditions
• No table in this version to keep the visual clean and portable
Inputs with guidance
Setup
• Price source. Default ohlc4. Stable for noisy symbols.
• Fast span. Typical range 6 to 24. Raising it slows the fast track and can reduce churn. Lowering it makes entries more reactive.
• Slow span. Typical range 20 to 60. Raising it lengthens the baseline horizon. Lowering it brings the slow track closer to price.
Logic
• Guide span. Typical range 4 to 12. A small guide smooths without eating turns.
• Blend power. Typical range 0.25 to 0.85. Raising it lets the drivers modulate gains more. Lowering it pushes behavior toward fixed EMA style smoothing.
• Vol window. Typical range 20 to 80. Larger values calm the volatility driver. Smaller values adapt faster in intraday work.
• Efficiency window. Typical range 10 to 60. Larger values focus on smoother trends. Smaller values react faster but accept more noise.
• Efficiency gamma. Typical range 0.8 to 2.0. Above one increases contrast between clean trends and chop. Below one flattens the curve.
• Min alpha multiplier. Typical range 0.30 to 0.80. Lower values increase smoothing when the mix is weak.
• Max alpha multiplier. Typical range 1.2 to 3.0. Higher values shorten smoothing when the mix is strong.
• Normalization window. Typical range 100 to 300. Larger values reduce drift in the baseline.
• Normalization mode. Z score, percent rank, or MAD Z. Use MAD Z for outlier heavy symbols.
• Clamp level. Typical range 2.0 to 4.0. Lower clamps reduce the influence of extreme runs.
Filters
• Efficiency filter is implicit in the gain map. Raising efficiency gamma and the efficiency window increases the preference for clean trends.
• Micro versus macro relation is handled by the fast and slow spans. Increase separation for swing, reduce for scalping.
• Location filter is not included in v1.0. If you need distance gates from a reference such as VWAP or a moving mean, add them before publication of a new version.
Alerts
• This version does not include alertcondition lines to keep the core minimal. If you prefer alerts, add names Long Polarity Up, Short Polarity Down, Exit Short on Flux Cross Up in a later version and select on bar close for conservative workflows.
Strategy has been currently adapted for the QQQ asset with 30/60min timeframe.
For other assets may require new optimization
Properties visible in this publication
• Initial capital 25000
• Base currency Default
• Default order size method percent of equity with value 5
• Pyramiding 1
• Commission 0.05 percent
• Slippage 10 ticks
• Process orders on close ON
• Bar magnifier ON
• Recalculate after order is filled OFF
• Calc on every tick OFF
Honest limitations and failure modes
• Past results do not guarantee future outcomes
• Economic releases, circuit breakers, and thin books can break the assumptions behind intensity and efficiency
• Gap heavy symbols may benefit from the MAD Z normalization
• Very quiet regimes can reduce signal contrast. Use longer windows or higher guide span to stabilize context
• Session time is the exchange time of the chart
• If both stop and target can be hit in one bar, tie handling would matter. This strategy has no fixed stops or targets. It uses polarity flips for exits. If you add stops later, declare the preference
Open source reuse and credits
• None beyond public domain building blocks and Pine built ins such as EMA, SMA, standard deviation, RMA, and percent rank
• Method and fusion are original in construction and disclosure
Legal
Education and research only. Not investment advice. You are responsible for your decisions. Test on historical data and in simulation before any live use. Use realistic costs.
Strategy add on block
Strategy notice
Orders are simulated by the TradingView engine on standard candles. No request.security() calls are used.
Entries and exits
• Entry logic. Enter long when both the normalized flux and its guide line are above zero. Enter short when both are below zero
• Exit logic. When polarity flips from plus to minus, close any long and open a short. When the flux crosses above the guide line, close any short
• Risk model. No initial stop or target in v1.0. The model is a regime flipper. You can add a stop or trail in later versions if needed
• Tie handling. Not applicable in this version because there are no fixed stops or targets
Position sizing
• Percent of equity in the Properties panel. Five percent is the default for examples. Risk per trade should not exceed five to ten percent of equity. One to two percent is a common choice
Properties used on the published chart
• Initial capital 25000
• Base currency Default
• Default order size percent of equity with value 5
• Pyramiding 1
• Commission 0.05 percent
• Slippage 10 ticks
• Process orders on close ON
• Bar magnifier ON
• Recalculate after order is filled OFF
• Calc on every tick OFF
Dataset and sample size
• Test window Jan 2, 2014 to Oct 16, 2025 on QQQ one hour
• Trade count in sample 324 on the example chart
Release notes template for future updates
Version 1.1.
• Add alertcondition lines for long, short, and exit short
• Add optional table with component readouts
• Add optional stop model with a distance unit expressed as ATR or a percent of price
Notes. Backward compatibility Yes. Inputs migrated Yes.
Universal Regime Alpha Thermocline StrategyCurrents settings adapted for BTCUSD Daily timeframe
This description is written to comply with TradingView House Rules and Script Publishing Rules. It is self contained, in English first, free of advertising, and explains originality, method, use, defaults, and limitations. No external links are included. Nothing here is investment advice.
0. Publication mode and rationale
This script is published as Protected . Anyone can add and test it from the Public Library, yet the source code is not visible.
Why Protected
The engine combines three independent lenses into one regime score and then uses an adaptive centering layer and a thermo risk unit that share a common AAR measure. The exact mapping and interactions are the result of original research and extensive validation. Keeping the implementation protected preserves that work and avoids low effort clones that would fragment feedback and confuse users.
Protection supports a single maintained build for users. It reduces accidental misuse of internal functions outside their intended context which might lead to misleading results.
1. What the strategy does in one paragraph
Universal Regime Alpha Thermocline builds a single number between zero and one that answers a practical question for any market and timeframe. How aligned is current price action with a persistent directional regime right now. To answer this the script fuses three views of the tape. Directional entropy of up versus down closes to measure unanimity.
Convexity drift that rewards true geometric compounding and penalizes drag that comes from chop where arithmetic pace is high but growth is poor.
Tail imbalance that counts decisive bursts in one direction relative to typical bar amplitude. The three channels are blended, optionally confirmed by a higher timeframe, and then adaptively centered to remove local bias. Entries fire when the score clears an entry gate. Exits occur when the score mean reverts below an exit gate or when thermo stops remove risk. Position size can scale with the certainty of the signal.
2. Why it is original and useful
It mixes orthogonal evidence instead of leaning on a single family of tools. Many regime filters depend on moving averages or volatility compression. Here we add an information view from entropy, a growth view from geometric drift, and a structural view from tail imbalance.
The drift channel separates growth from speed. Arithmetic pace can look strong in whipsaw, yet geometric growth stays weak. The engine measures both and subtracts drag so that only sequences with compounding quality rise.
Tail counting is anchored to AAR which is the average absolute return of bars in the window. This makes the threshold self scaling and portable across symbols and timeframes without hand tuned constants.
Adaptive centering prevents the score from living above or below neutral for long stretches on assets with strong skew. It recovers neutrality while still allowing persistent regimes to dominate once evidence accumulates.
The same AAR unit used in the signal also sets stop distance and trail distance. Signal and risk speak the same language which makes the method portable and easier to reason about.
3. Plain language overview of the math
Log returns . The base series is r equal to the natural log of close divided by the previous close. Log return allows clean aggregation and makes growth comparisons natural.
Directional entropy . Inside the lookback we compute the proportion p of bars where r is positive. Binary entropy of p is high when the mix of up and down closes is balanced and low when one direction dominates. Intensity is one minus entropy. Directional sign is two times p minus one. The trend channel is zero point five plus one half times sign times intensity. It lives between zero and one and grows stronger as unanimity increases.
Convexity drift with drag . Arithmetic mean of r measures pace. Geometric mean of the price ratio over the window measures compounding. Drag is the positive part of arithmetic minus geometric. Drift raw equals geometric minus drag multiplier times drag. We then map drift through an arctangent normalizer scaled by AAR and a nonlinearity parameter so the result is stable and remains between zero and one.
Tail imbalance . AAR equals the average of the absolute value of r in the window. We count up tails where r is greater than aar_mult times AAR and down tails where r is less than minus aar_mult times AAR. The imbalance is their difference over their total, mapped to zero to one. This detects directional impulse flow.
Fusion and centering . A weighted average of the three channels yields the raw score. If a higher timeframe is requested, the same function is executed on that timeframe with lookahead off and blended with a weight. Finally we subtract a fraction of the rolling mean of the score to recover neutrality. The result is clipped to the zero to one band.
4. Entries, exits, and position sizing
Enter long when score is strictly greater than the entry gate. Enter short when score is strictly less than one minus the entry gate unless direction is restricted in inputs.
Exit a long when score falls below the exit gate. Exit a short when score rises above one minus the exit gate.
Thermo stops are expressed in AAR units. A long uses the maximum of an initial stop sized by the entry price and AAR and a trail stop that references the running high since entry with a separate multiple. Shorts mirror this with the running low. If the trail is disabled the initial stop is active.
Cooldown is a simple bar counter that begins when the position returns to flat. It prevents immediate re entry in churn.
Dynamic position size is optional. When enabled the order percent of equity scales between a floor and a cap as the score rises above the gate for longs or below the symmetric gate for shorts.
5. Inputs quick guide with recommended ranges
Every input has a tooltip in the script. The same guidance appears here for fast reading.
Core window . Shared lookback for entropy, drift, and tails. Start near 80 on daily charts. Try 60 to 120 on intraday and 80 to 200 for swing.
Entry threshold . Typical range 0.55 to 0.65 for trend following. Faster entries 0.50 to 0.55.
Exit threshold . Typical range 0.35 to 0.50. Lower holds longer yet gives back more.
Weight directional entropy . Starting value 0.40. Raise on markets with clean persistence.
Weight convexity drift . Starting value 0.40. Raise when compounding quality is critical.
Weight tail imbalance . Starting value 0.20. Raise on breakout prone markets.
Tail threshold vs AAR . Typical range 1.0 to 1.5 to count decisive bursts.
Drag penalty . Typical range 0.25 to 0.75. Higher punishes chop more.
Nonlinearity scale . Typical range 0.8 to 2.0. Larger compresses extremes.
AAR floor in percent . Typical range 0.0005 to 0.002 for liquid instruments. This stabilizes the math during quiet regimes.
Adaptive centering . Keep on for most symbols. Center strength 0.40 to 0.70.
Confirm timeframe optional . Leave empty to disable. If used, try a multiple between three and five of the chart timeframe with a blend weight near 0.20.
Dynamic position size . Enable if you want size to reflect certainty. Floor and cap define the percent of equity band. A practical band for many accounts is 0.5 to 2.
Cooldown bars after exit . Start at 3 on daily or slightly higher on shorter charts.
Thermo stop multiple . Start between 1.5 and 3.0 on daily. Adjust to your tolerance and symbol behavior.
Thermo trailing stop and Trail multiple . Trail on locks gains earlier. A trail multiple near 1.0 to 2.0 is common. You can keep trail off and let the exit gate handle exits.
Background heat opacity . Cosmetic. Set to taste. Zero disables it.
6. Properties used on the published chart
The example publication uses BTCUSD on the daily timeframe. The following Properties and inputs are used so everyone can reproduce the same results.
Initial capital 100000
Base currency USD
Order size 2 percent of equity coming from our risk management inputs.
Pyramiding 0
Commission 0.05 percent
Slippage 10 ticks in the publication for clarity. Users should introduce slippage in their own research.
Recalculate after order is filled off. On every tick off.
Using bar magnifier on. On bar close on.
Risk inputs on the published chart. Dynamic position size on. Size floor percent 2. Size cap percent 2. Cooldown bars after exit 3. Thermo stop multiple 2.5. Thermo trailing stop off. Trail multiple 1.
7. Visual elements and alerts
The score is painted as a subtle dot rail near the bottom. A background heat map runs from red to green to convey regime strength at a glance. A compact HUD at the top right shows current score, the three component channels, the active AAR, and the remaining cooldown. Four alerts are included. Long Setup and Short Setup on entry gates. Exit Long by Score and Exit Short by Score on exit gates. You can disable trading and use alerts only if you want the score as a risk switch inside a discretionary plan.
8. How to reproduce the example
Open a BTCUSD daily chart with regular candles.
Add the strategy and load the defaults that match the values above.
Set Properties as listed in section 6.(they are set by default) Confirm that bar magnifier is on and process on bar close is on.
Run the Strategy Tester. Confirm that the trade count is reasonable for the sample. If the count is too low, slightly lower the entry threshold or extend history. If the count is excessively high, raise the threshold or add a small cooldown.
9. Practical tuning recipes
Trend following focus . Raise the entry threshold toward 0.60. Raise the trend weight to 0.50 and reduce tail weight to 0.15. Keep drift near 0.35 to retain the growth filter. Consider leaving the trail off and let the exit threshold manage positions.
Breakout focus . Keep entry near 0.55. Raise tail weight to 0.35. Keep aar_mult near 1.3 so only decisive bursts count. A modest cooldown near 5 can reduce immediate false flips after the first burst bar.
Chop defense . Raise drag multiplier to 0.70. Raise exit threshold toward 0.48 to recycle capital earlier. Consider a higher cooldown, for example 8 to 12 on intraday.
Higher timeframe blend . On a daily chart try a weekly confirm with a blend near 0.20. On a five minute chart try a fifteen minute confirm. This moderates transitions.
Sizing discipline . If you want constant position size, set floor equal to cap. If you want certainty scaling, set a band like 0.5 to 2 and monitor drawdown behavior before widening it.
10. Strengths and limitations
Strengths
Self scaling unit through AAR makes the tool portable across markets and timeframes.
Blends evidence that target different failure modes. Unanimity, growth quality, and impulse flow rarely agree by chance which raises confidence when they align.
Adaptive centering reduces structural bias at the score level which helps during regime flips.
Limitations
In very quiet regimes AAR becomes small even with a floor. If your symbol is thin or gap prone, raise the floor a little to keep stops and drift mapping stable.
Adaptive centering can delay early breakout acceptance. If you miss starts, lower center strength or temporarily disable centering while you evaluate.
Tail counting uses a fixed multiple of AAR. If a market alternates between very calm and very violent weeks, a single aar_mult may not capture both extremes. Sweep this parameter in research.
The engine reacts to realized structure. It does not anticipate scheduled news or liquidity shocks. Use event awareness if you trade around releases.
11. Realism and responsible publication
No promises or projections of performance are made. Past results never guarantee future outcomes.
Commission is set to 0.05 percent per round which is realistic for many crypto venues. Adjust to your own broker or exchange.
Slippage is set at 10 in the publication . Introduce slippage in your own tests or use a percent model.
Position size should respect sustainable risk envelopes. Risking more than five to ten percent per trade is rarely viable. The example uses a fixed two percent position size.
Security calls use lookahead off. Standard candles only. Non standard chart types like Heikin Ashi or Renko are not supported for strategies that submit orders.
12. Suggested research workflow
Begin with the balanced defaults. Confirm that the trade count is sensible for your timeframe and symbol. As a rough guide, aim for at least one hundred trades across a wide sample for statistical comfort. If your timeframe cannot produce that count, complement with multiple symbols or run longer history.
Sweep entry and exit thresholds on a small grid and observe stability. Stability across windows matters more than the single best value.
Try one higher timeframe blend with a modest weight. Large weights can drown the signal.
Vary aar_mult and drag_mult together. This tunes the aggression of breakouts versus defense in chop.
Evaluate whether dynamic size improves risk adjusted results for your style. If not, set floor equal to cap for constancy.
Walk forward through disjoint segments and inspect results by regime. Bootstrapping or segmented evaluation can reveal sensitivity to specific periods.
13. How to read the HUD and heat map
The HUD presents a compact view. Score is the current fused value. Trend is the directional entropy channel. Drift is the compounding quality channel. Tail is the burst flow channel. AAR is the current unit that scales stops and the drift map. CD is the cooldown counter. The background heat is a visual aid only. It can be disabled in inputs. Green zones near the upper band show alignment among the channels. Muted colors near the mid band show uncertainty.
14. Frequently asked questions
Can I use this as a pure indicator . Yes. Disable entries by restricting direction to one side you will not trade and use the alerts as a regime switch.
Will it work on intraday charts . Yes. The AAR unit scales with bar size. You will likely reduce the core window and increase cooldown slightly.
Should I enable the adaptive trail . If you wish to lock gains sooner and accept more exits, enable it. If you prefer to let the exit gate do the heavy lifting, keep it off.
Why do I sometimes see a green background without a position . Heat expresses the score. A position also depends on threshold comparisons, direction mode, and cooldown.
Why is Order size set to one hundred percent if dynamic size is on . The script passes an explicit quantity percent on each entry. That explicit quantity overrides the property. The property is kept at one hundred percent to avoid confusion when users later disable dynamic sizing.
Can I combine this with other tools on my chart . You can, yet for publication the chart is kept clean so users and moderators can see the output clearly. In your private workspace feel free to add other context.
15. Concepts glossary
AAR . Average absolute return across the lookback. Serves as a unit for tails, drift scaling, and stops.
Directional entropy . A measure of uncertainty of up versus down closes. Low entropy paired with a directional sign signals unanimity.
Geometric mean growth . Rate that preserves the effect of compounding over many bars.
Drag . The positive difference between arithmetic pace and geometric growth. Larger drag often signals churn that looks active but fails to compound.
Thermo stops . Stops expressed in the same AAR unit as the signal. They adapt with volatility and keep risk and signal on a common scale.
Adaptive centering . A bias correction that recenters the fused score around neutral so the meter does not drift due to persistent skew.
16. Educational notice and risk statement
Markets involve risk. This publication is for education and research. It does not provide financial advice and it is not a recommendation to buy or sell any instrument. Use realistic costs. Validate ideas with out of sample testing and with conservative position sizing. Past performance never guarantees future results.
17. Final notes for readers and moderators
The goal of this strategy is clarity and portability. Clarity comes from a single score that reflects three independent features of the tape. Portability comes from self scaling units that respect structure across assets and timeframes. The publication keeps the chart clean, explains the math plainly, lists defaults and Properties used, and includes warnings where care is required. The code is protected so the implementation remains consistent for the community while the description remains complete enough for users to understand its purpose and for moderators to evaluate originality and usefulness. If you explore variants, keep them self contained, explain exactly what they contribute, publish in English first, and treat others with respect in the comments.
Load the strategy on BTCUSD daily with the defaults listed above and study how the score transitions across regimes. Then adjust one lever at a time. Observe how the trend channel, the drift channel, and the tail channel interact during starts, pauses, and reversals. Use the alerts as a risk switch inside your own process or let the built in entries and exits run if you prefer an automated study. The intent is not to promise outcomes. The intent is to give you a robust meter for regime strength that travels well across markets and helps you structure decisions with more confidence.
Thank you for your time to read all of this
PulseGrid Universal Scalper - Adaptive Pulse and Symmetric SpansInstrument agnostic. Works on any symbol and timeframe supported by TradingView.
Message or hit me up in chat for full access .
Purpose and scope
PulseGrid is a short timeframe strategy designed to read intrabar structure and recent path so that entries align with actionable momentum and context. The strategy is private. The description below provides all the information needed to understand how it behaves, how it sizes risk, how to tune it responsibly, and how to evaluate results without making unrealistic claims. The design is instrument agnostic. It runs on any asset class that prints open high low close bars on TradingView. That includes commodities such as Gold and WTI, currencies, crypto, equity indices, and single stocks. Performance will always depend on the symbol’s liquidity, spread, slippage, and session structure, which is why the description focuses on principles and safe parameter ranges instead of hard promises.
What the strategy does at a glance
It builds a composite entry signal named Pulse from five normalized bar features that reflect short term pressure and follow through.
It applies regime guards that keep the strategy inactive when the tape is either too quiet, too bursty, or too directionally random.
It optionally uses a directional filter where a fast and a slow exponential average must agree and their gap must be material relative to recent true range.
When a signal is allowed, risk is sized using symmetric spans that come from nearby untraded price distances above and below the market. The strategy sets a single stop and a single take profit from those spans.
Lines for entry, stop, and take profit are drawn on the chart. A compact on chart table shows trade counts, win rate, average R per trade, and profit factor for all trades, longs only, and shorts only.
This combination yields entries that are reactive but not chaotic, and risk lines that respect the market’s recent path instead of generic pip or point targets.
Why the design is original and useful
The core originality is the union of a composite entry that adapts to volatility and a geometry based risk model. The entry uses five different viewpoints on the same bar space instead of relying on a single technical indicator. The risk model uses spans that come from actual untraded distance rather than fixed multipliers of a generic volatility measure. The result is a framework that is simple to read on a chart and simple to evaluate, yet it avoids the traps of curve fitting to one symbol or one month of data. Because everything is normalized locally, the same logic translates across asset classes with only modest tuning.
The Pulse composite in detail
Pulse is a weighted blend of the following normalized features.
Impulse imbalance. The script sums upward and downward impulses over a short window. An upward impulse is the extension of highs relative to the prior bar. A downward impulse is the extension of lows relative to the prior bar. The net imbalance, scaled by the local range, captures whether extension pressure is building or fading.
Wick and close location. Inside each bar, the distance between the close and the extremes carries information about rejection or acceptance. A bar that closes near the high with relatively heavier lower wick suggests upward acceptance. A bar that closes near the low with heavier upper wick suggests downward acceptance. A weight controls the contribution of wick skew versus close location so that users can favor reversal or momentum behaviour.
Shock touches. Within the recent range window, touches that occur very near the top decile or bottom decile are marked. A short sliding window counts recent shocks. Frequent top shocks in a rising context suggest supply tests. Frequent bottom shocks in a declining context suggest demand tests. The count is normalized by window length.
Breakout ledger. The script compares current extremes to lagged extremes and keeps a simple count of recent upside and downside breakouts. The difference behaves as a short term polarity meter.
Curvature. A simple second difference in closing price acts as a curvature term. It is normalized by the recent maximum of absolute one bar returns so that the value remains bounded and comparable to other terms.
Pulse is smoothed over a fraction of the main signal length. Smoothing removes impulse spikes without destroying the quick reaction that scalpers need. The absolute value of smoothed Pulse can be used with an adaptive gate so that only the top percentile of energy for the recent environment is eligible for entries. A small floor prevents accidental entries during very quiet periods.
Regime guards that keep the strategy selective
Three guards must all pass before any entry can occur.
Auction Balance Factor. This is the proportion of closes that land inside a mid band of the prior bar’s high to low range. High values indicate balanced chop where breakouts tend to fail. Low values indicate directional conditions. The strategy requires ABF to sit below a user chosen maximum.
Dispersion via a Gini style measure on absolute returns. Very low dispersion means bars are small and uniform. Very high dispersion means a few outsized bars dominate and slippage risk can be elevated. The strategy allows the user to require the dispersion measure to remain inside a band that reflects healthy activity.
Binary entropy of direction. Over the core window, the proportion of up closes is used to compute a simple entropy. Values near one indicate coin flip behaviour. Values near zero indicate one sided sequences. The guard requires entropy below a ceiling so that random directionality does not produce noise entries.
An optional directional filter asks that a fast and a slow exponential average agree on direction and that their gap, when divided by an average true range, exceed a threshold. This filter can be enabled on symbols that trend cleanly and disabled when the composite entry is already selective enough.
Risk sizing with symmetric spans
Instead of fixed points or a pure ATR multiplier, the strategy sizes stops and targets from a pair of spans. The upward span reflects recent untraded distance above the market. The downward span reflects recent untraded distance below the market. Each span is floored by a fallback that comes from the maximum of a short simple range average and a standard average true range. A tick based floor prevents microscopic stops on instruments with high tick precision. An asymmetry cap prevents one span from becoming many times larger than the other. For long entries the stop is a multiple of the downward span and the target is a multiple of the upward span. For short entries the stop is a multiple of the upward span and the target is a multiple of the downward span. This creates a risk box that is symmetric by construction yet adaptive to recent voids and gaps.
Execution, ties, and housekeeping
Entries evaluate at bar close. Exits are tested from the next bar forward. If both stop and target are hit within the same bar, the outcome can be resolved in a consistent way that favors the stop or the target according to a single user setting. A short cooldown in bars prevents flip flops. Users can restrict entries to specific sessions such as London and New York. The chart renders entry, stop, and target lines for each trade so that every action is visible. The table in the top right shows trade counts, take profit and stop counts, win rate, average R per trade, and profit factor for the whole set and by direction.
Defaults and responsible backtesting
The default properties in the script use a realistic initial capital and commission value. Users should also set slippage in the strategy properties to reflect their broker and symbol. Small timeframe trading is sensitive to friction and the strategy description does not claim immunity to that reality. The strategy is intended to be tested on a dataset that produces a meaningful sample of trades. A sample in the range of a hundred trades or more is preferred because variance in short samples can be large. On thin symbols or periods with little regular trading, users should either change timeframe, change sessions, or use more selective thresholds so that the sample contains only liquid scenarios.
Universal usage across markets
The strategy is universal by design. It will run and produce lines on any open high low close series on TradingView. The composite entry is made of normalized parts. The regime guards use proportions and bounded measures. The spans use untraded distance and range floors measured in the local price scale. This allows the same logic to function on a currency pair, a commodity, an index future, a stock, or a crypto pair. What changes is calibration.
A safe approach for universal use is as follows.
Start with the default signal length and wick weight.
If the chart prints many weak signals, enable the directional filter and raise the normalized gap threshold slightly.
If the chart is too quiet, lower the adaptive percentile or, with adaptive off, lower the fixed pulse threshold by a small amount.
If stops are too tight in quiet regimes, raise the fallback span multiplier or raise the minimum tick floor in ticks.
If you observe long one sided days, lower the maximum entropy slightly so that entries only occur when directionality is genuine rather than alternating.
Because the logic is bounded and local, these simple steps carry over across symbols. That is why the strategy can be used literally on any asset that you can load on a TradingView chart. The code does not depend on a specific tick size or a specific exchange calendar. It will still remain true that symbols with higher spread or fewer regular trading hours demand stricter thresholds and larger floors.
Suggested parameter ranges for common cases
These ranges are guidelines for one to five minute bars. They are not promises of performance. They reflect the balance between having enough signals to learn from and keeping noise controlled.
Signal length between 18 and 34 for liquid commodities and large capitalization equities.
Wick weight between 0.30 and 0.50 depending on whether you want reversal recognition or close momentum.
Adaptive gate percentile between 85 and 93 when adaptive is enabled. Fixed threshold between 0.10 and 0.18 when adaptive is disabled. Use a non zero floor so very quiet periods still require some energy.
Auction Balance Factor maximum near 0.70 for symbols with clear session bursts. Slightly higher if you prefer to include more balanced prints.
Dispersion band with a lower bound near 0.18 and an upper bound near 0.68 for most session instruments. Tighten the band if you want to skip very bursty days or very flat days.
Entropy maximum near 0.90 so coin flip phases are filtered. Lower the ceiling slightly if the symbol whipsaws frequently.
Stop multiplier near one and take profit multiplier between two and three for a single target approach. Larger target multipliers reduce hit rate and lengthen holding time.
These are safe starting points across commodities, currencies, indices, equities, and crypto. From there, small increments are preferred over dramatic changes.
How to evaluate responsibly
A clean chart and a direct test process help avoid confusion. Use standard candles for signals and exits. If you use a non standard chart type such as Heikin Ashi or Renko, do so only for visualization and not for the strategy’s signal computation, as those chart types can produce unrealistic fills. Turn off other indicators on the published chart unless they are needed to demonstrate a specific property of this strategy. When you post results or discuss outcomes, include the symbol, timeframe, commission and slippage settings, and the session settings used. This makes the context clear and avoids misleading readers.
When you look at results, consider the following.
The distribution of R per trade. A positive average R with a moderate profit factor suggests that exits are sized appropriately for the symbol.
The balance between long and short sides. The HUD table separates the two so you can see if one side carries the edge for that symbol.
The sensitivity to the tie preference. If many bars hit both stop and take profit, the market is chopping inside the risk box and you may need larger floors or stricter regime guards.
The session effect. Session hours matter for many instruments. Align your session filter with where liquidity and volatility concentrate.
Known limitations and honest warnings
PulseGrid is not a guarantee of future profit. It is a systematic way to read short term structure and to size risk in a way that reflects recent path. It assumes that the data feed reflects the exchange reality. It assumes that slippage and spread are non zero and uses explicit commission and user provided slippage to approximate that. It does not place multiple targets. It does not trail stops. It is not a high frequency system and does not attempt to model queue priority or microsecond fills. On illiquid symbols or very short timeframes outside regular hours, signals will be less reliable. Users are responsible for choosing realistic settings and for evaluating whether the symbol’s conditions are suitable.
First use checklist
Load the symbol and timeframe you care about.
If the instrument has clear sessions, turn on the session filter and select realistic London and New York hours or other sessions relevant to the instrument.
Set commission and slippage in the strategy properties to values that match your broker or exchange.
Run the strategy with defaults. Look at the HUD summary and the lines.
Decide whether to enable the directional filter. If you see frequent reversals around the entry line, enable it and raise the normalized gap threshold slightly.
Adjust the adaptive gate. If the chart floods, raise the percentile. If the chart starves, lower it or use a slightly lower fixed threshold.
Adjust the fallback span multiplier and tick floor so that stops are never microscopic.
Review per session performance. If one session underperforms, restrict entries to the better one.
This simple process takes minutes and transfers to any other symbol.
Why this script is private
The source remains private so that the underlying method and its implementation details are not copied or republished. The description here is complete and self contained so that users can understand the purpose, originality, usage, and limitations without needing to inspect the source. Privacy does not change the strategy’s on chart behavior. It only protects the specific coding details.
Guarantee and compliance statements
This description does not contain advertising, solicitations, links, or contact information. It does not make performance promises. It explains how the script is original and how it works. It also warns about limitations and the need for realistic assumptions. The strategy is not investment advice and is not created only for qualified investors. It can be tested and used for educational and research purposes. Users should read TradingView’s documentation on script properties and backtesting. Users should avoid non standard chart types for signal computation because those produce unrealistic results. Users should select realistic account sizes and friction settings. Users should not post claims without showing the settings used.
Closing summary
PulseGrid is a compact framework for short timeframe trading that combines a composite entry built from multiple normalized bar features with a symmetric span model for risk. The entry adapts to volatility. The regime guards keep the strategy inactive when the tape is either too quiet or too erratic. The risk geometry respects recent untraded spans instead of arbitrary distances. The entire design is instrument agnostic. It will run on any symbol that TradingView supports and it will behave consistently across asset classes with modest tuning. Use it with a clean chart, realistic friction, and enough trades to make your evaluation meaningful. Use sessions if the instrument concentrates activity in specific hours. Adjust one control at a time and prefer small increments. The goal is not to find a magic parameter. The goal is to maintain a stable rule set that reads market structure in a way you can trust and audit.
AlphaZ-Score - Bitcoin Market Cycle IndicatorWHAT IS ALPHAZ-SCORE?
AlphaZ-Score is a Bitcoin-specific market cycle indicator that identifies extreme market conditions (tops and bottoms) by aggregating up to 7 independent on-chain and market metrics into a single normalized z-score. Unlike traditional oscillators that analyze only price action, AlphaZ-Score incorporates blockchain fundamentals, investor profitability metrics, and capital flow data to determine where Bitcoin sits within its long-term market cycle.
The output ranges from -3 (extreme oversold/cycle bottom) to +3 (extreme overbought/cycle top), with readings beyond ±2 indicating high-probability reversal zones.
METHODOLOGY - THE 7-COMPONENT SYSTEM
Each component analyzes Bitcoin's market state from a unique perspective, then gets z-scored (statistical normalization) so all metrics can be compared on equal footing. The final score is a weighted average of all enabled indicators.
Default Configuration (3 indicators enabled):
Stablecoin Supply Ratio (SSRO)
MVRV Z-Score
SOPR Z-Score
Optional Advanced Components (4 indicators disabled by default):
Days Higher Streak Valuation (DHSV)
High Probability OB/OS (HPOB)
Risk Index Z-Score
Comprehensive On-chain Z-Score
COMPONENT BREAKDOWN
1. STABLECOIN SUPPLY RATIO OSCILLATOR (SSRO) - ENABLED BY DEFAULT
What it measures: Ratio of Bitcoin market cap to total stablecoin supply (USDT + USDC)
Data sources:
CRYPTOCAP:BTC - Bitcoin market cap
CRYPTOCAP:USDT - Tether market cap
CRYPTOCAP:USDC - USD Coin market cap
Logic:
SSR = BTC Market Cap / (USDT + USDC Supply)
Z-Score = Standardized SSR over 200 periods
Interpretation:
High SSR (positive z-score): Bitcoin overvalued relative to available stablecoin buying power → Overbought
Low SSR (negative z-score): Massive stablecoin reserves relative to BTC value → Potential bottom (dry powder)
Why it works: Stablecoins represent "dry powder" - capital waiting to enter crypto. When stablecoin supply is high relative to BTC value, it signals accumulation potential. When low, it suggests exhausted buying power.
2. MVRV Z-SCORE - ENABLED BY DEFAULT
What it measures: Market Value to Realized Value ratio, z-scored over 520 periods
Data source: INTOTHEBLOCK:BTC_MVRV
Logic:
MVRV = Market Cap / Realized Cap
Z-Score = (MVRV - Mean) / Std Dev
Interpretation:
High MVRV (positive z-score): Average holder in significant profit → Distribution phase
Low MVRV (negative z-score): Average holder near breakeven/loss → Accumulation phase
Why it works: MVRV compares Bitcoin's market price to its "fair value" (realized price = average cost basis of all coins). Extreme deviations historically mark cycle tops (MVRV > 3.5) and bottoms (MVRV < 1.0).
Historical significance:
2017 top: MVRV z-score ~7
2018 bottom: MVRV z-score ~-1.5
2021 top: MVRV z-score ~6
2022 bottom: MVRV z-score ~-1.0
3. SOPR Z-SCORE - ENABLED BY DEFAULT
What it measures: Spent Output Profit Ratio, smoothed and z-scored
Data source: GLASSNODE:BTC_SOPR
Logic:
SOPR = Value of spent outputs / Value at creation
SOPR EMA = 7-period exponential moving average
Z-Score = Standardized SOPR EMA over 180 periods
Interpretation:
SOPR > 1 (positive z-score): Coins being spent at profit → Potential distribution
SOPR < 1 (negative z-score): Coins being spent at loss → Capitulation/bottom
Why it works: SOPR measures aggregate profitability of spent coins. When holders are forced to sell at losses (SOPR < 1), it indicates capitulation and potential bottoms. When everyone sells at profit (SOPR >> 1), it signals euphoria and potential tops.
4. DAYS HIGHER STREAK VALUATION (DHSV) - DISABLED BY DEFAULT
What it measures: Number of historical bars with prices higher than current level
Logic:
For last N bars, count how many had close > current close
Apply streak decay logic based on price threshold
Z-Score result over lookback period
Interpretation:
Few days higher (negative z-score): Price near all-time highs → Potential overbought
Many days higher (positive z-score): Price deep below historical levels → Oversold
Why it works: Measures how "expensive" current price is relative to history. When 90%+ of historical bars are higher, you're near cycle bottoms.
Settings:
Historical Bars (1000): How far back to look
Threshold & Decay: Sensitivity adjustments
5. HIGH PROBABILITY OVERBOUGHT/OVERSOLD (HPOB) - DISABLED BY DEFAULT
What it measures: Volume-weighted price momentum divergence
Logic:
Volume-weighted Hull MA vs Standard Hull MA
Difference normalized by 100-period SMA
Result inverted and scaled to match z-score range
Interpretation:
Positive score: Volume-weighted momentum diverging up → Overbought
Negative score: Volume-weighted momentum diverging down → Oversold
Why it works: When volume-weighted price movement diverges from standard price movement, it reveals institutional vs retail behavior mismatches.
Settings:
SVWHMA Length (50): Volume-weighted smoothing
HMA Length (50): Standard momentum baseline
Smooth Length (50): Final output smoothing
6. RISK INDEX Z-SCORE - DISABLED BY DEFAULT
What it measures: Modified Puell Multiple approach using realized cap
Data sources:
COINMETRICS:BTC_MARKETCAPREAL - Realized market cap
GLASSNODE:BTC_MARKETCAP - Current market cap
Logic:
Delta = Risk Multiplier × Realized Cap - Historical Realized Cap
Risk Index = (Delta / Market Cap × 100) / 24
Z-Score = Standardized Risk Index over 1500 periods
Interpretation:
High risk (positive z-score): Realized cap growth outpacing market cap → Overextended
Low risk (negative z-score): Market cap collapsed relative to realized cap → Undervalued
Why it works: Compares the rate of realized cap change to market cap. Rapid realized cap growth during low market cap periods signals accumulation.
7. COMPREHENSIVE ON-CHAIN Z-SCORE - DISABLED BY DEFAULT
What it measures: Average of three on-chain metrics: NUPL, SOPR, and MVRV
Data sources:
GLASSNODE:BTC_MARKETCAP - Current market cap
COINMETRICS:BTC_MARKETCAPREAL - Realized cap
GLASSNODE:BTC_SOPR - SOPR data
Logic:
NUPL = (Market Cap - Realized Cap) / Market Cap × 100
SOPR Z-Score = (SOPR - Mean) / Std Dev with EMA smoothing
MVRV = Market Cap / Realized Cap
Final Score = Average of all three z-scores
Interpretation:
Combines profitability (NUPL), spending behavior (SOPR), and valuation (MVRV) into single comprehensive on-chain metric.
AGGREGATION METHODOLOGY
Scoring System:
Each enabled indicator produces a z-score (typically -3 to +3 range)
Scores are weighted equally (weight = 1.0 for all)
Final output = Weighted average of all enabled indicators
Why Equal Weighting:
Each metric analyzes fundamentally different aspects of Bitcoin's market state. Equal weighting prevents any single data source from dominating and ensures diversification.
Customization:
Users can enable/disable indicators to:
Simplify analysis (3 core metrics)
Increase complexity (all 7 metrics)
Focus on specific aspects (only on-chain, only market-based, etc.)
INTERPRETATION GUIDE
Z-Score Ranges:
+3.0 and above - EXTREME OVERBOUGHT
Historical cycle tops
Maximum euphoria
High-probability distribution zone
Consider taking profits
+2.0 to +3.0 - OVERBOUGHT
Late bull market phase
Elevated risk
Cautious positioning recommended
-2.0 to +2.0 - NEUTRAL
Normal market conditions
Trend-following strategies appropriate
-2.0 to -3.0 - OVERSOLD
Early accumulation phase
Fear/capitulation stage
Begin DCA strategies
-3.0 and below - EXTREME OVERSOLD
Historical cycle bottoms
Maximum fear
High-probability accumulation zone
Prime buying opportunity
VISUAL COMPONENTS
1. Main Z-Score Line:
Dynamic color gradient based on value
Green shades: Oversold (buying opportunity)
Red shades: Overbought (distribution zone)
White: Neutral
2. Reference Lines:
0: Neutral baseline
±2: Overbought/Oversold thresholds
±3: Extreme zones (highest probability reversals)
3. Background Shading:
Light green: Oversold (-2 to -3)
Bright green: Extreme oversold (< -3)
Light red: Overbought (+2 to +3)
Bright red: Extreme overbought (> +3)
4. Bar Coloring:
Cyan bars: Oversold conditions
Red bars: Overbought conditions
Default: Neutral
5. Summary Table (Top Right):
Market State: Current condition (Extreme OB/OS, Overbought/Oversold, Neutral)
Z-Score Value: Precise numeric reading
HOW TO USE
For Long-Term Investors (DCA Strategy):
Aggressive accumulation: Z-score < -2 (especially < -3)
Regular accumulation: Z-score between -2 and 0
Hold: Z-score between 0 and +2
Take profits: Z-score > +2 (especially > +3)
For Cycle Traders:
Buy zone: Wait for z-score to drop below -2
Hold through: Ignore noise between -2 and +2
Sell zone: Start distributing when z-score exceeds +2
Exit: Complete exit if z-score reaches +3
Risk Management:
Never buy in extreme overbought (>+3) - Historically always preceded major crashes
Scale into positions - Don't go all-in at any single reading
Use with price action - Confirm with support/resistance levels
Best Timeframes:
1D (Daily): Primary timeframe for cycle analysis
1W (Weekly): Macro cycle perspective
Lower timeframes not recommended (designed for long-term cycles)
SETTINGS CONFIGURATION
General Settings:
Toggle each of 7 indicators on/off
Default: 3 indicators enabled (SSRO, MVRV, SOPR)
Advanced: Enable all 7 for maximum sensitivity
Individual Indicator Settings:
Each indicator has dedicated parameter groups:
DHSV: Historical lookback, threshold decay
HPOB: HMA and VWMA lengths, smoothing
SSRO: Z-score calculation period (200)
MVRV: Z-score length (520)
Risk: Multiplier and z-score length
SOPR: EMA smoothing (7), z-score period (180)
On-chain: Separate lengths for NUPL, SOPR, MVRV components
DATA REQUIREMENTS
Required External Data Sources:
Default configuration (3 indicators):
CRYPTOCAP:BTC - Bitcoin market cap
CRYPTOCAP:USDT - Tether supply
CRYPTOCAP:USDC - USD Coin supply
INTOTHEBLOCK:BTC_MVRV - MVRV ratio
GLASSNODE:BTC_SOPR - SOPR data
Optional indicators require:
GLASSNODE:BTC_MARKETCAP - Market cap (on-chain)
COINMETRICS:BTC_MARKETCAPREAL - Realized cap
Additional Glassnode metrics
Important: This indicator requires TradingView data subscriptions for on-chain metrics. Some data sources may not be available on all accounts.
HISTORICAL PERFORMANCE
Major Cycle Tops Identified:
November 2021: Z-score peaked at ~+2.8 before -50% crash
December 2017: Z-score exceeded +3.0 before -84% bear market
April 2013: Z-score hit extreme overbought before correction
Major Cycle Bottoms Identified:
November 2022: Z-score reached -2.5 before +100% rally
December 2018: Z-score dropped to -2.8 before +300% bull run
January 2015: Z-score hit -3.2 before multi-year bull market
Key Insight: Extreme readings (beyond ±2.5) have preceded major market reversals with high accuracy. The indicator is designed for cycle identification, not short-term trading.
ORIGINALITY - WHY THIS IS UNIQUE
Traditional Cycle Indicators:
Use single metrics (MVRV only, SOPR only, etc.)
No normalization - hard to compare metrics
Fixed thresholds that don't adapt to market evolution
Often proprietary black boxes
AlphaZ-Score Advantages:
Multi-Metric Aggregation: Combines on-chain fundamentals, market structure, and capital flows into single score
Statistical Normalization: Z-scoring allows fair comparison of completely different metrics (market cap ratios vs profitability metrics)
Modular Design: Enable only the metrics you trust or have data access to
Transparent Calculations: All formulas visible in open-source code
Bitcoin-Specific Optimization: Tuned specifically for Bitcoin's 4-year halving cycle and on-chain characteristics
Customizable Weighting: Advanced users can modify weights for different market regimes
Visual Clarity: Single line that clearly shows cycle position, unlike juggling multiple indicators
LIMITATIONS
Requires on-chain data subscriptions - Some metrics need premium TradingView data
Lagging indicator - Identifies cycles after they begin, not predictive
Bitcoin-specific - Not designed for altcoins or traditional markets
Long-term focus - Not suitable for day trading or short-term speculation
Data availability - Historical on-chain data only goes back to ~2010
External dependencies - Relies on Glassnode, CoinMetrics data accuracy
ALERTS
No built-in alerts (indicator designed for visual analysis of long-term cycles). Users can create custom alerts based on z-score thresholds.
BEST PRACTICES
✅ Use on daily or weekly timeframe only
✅ Combine with long-term moving averages (200 MA, 200 WMA)
✅ Wait for extreme readings (beyond ±2) before major decisions
✅ Scale positions - don't go all-in at any single reading
✅ Verify on-chain data sources are updating properly
❌ Don't use for short-term trading (minutes/hours)
❌ Don't ignore price action - confirm with chart patterns
❌ Don't expect perfect timing - cycles can extend beyond extremes
❌ Don't trade solely on this indicator - use as confluence
Not financial advice. This indicator identifies market cycles based on historical patterns and on-chain data. Past performance does not guarantee future results. Always use proper risk management and position sizing.
AlphaBTC - Long Term Trend Probability Indicator on BitcoinWHAT IS ALPHABTC?
AlphaBTC is a consensus-based long-term trend probability indicator designed specifically for Bitcoin and cryptocurrency markets. It combines 9 independent trend detection methodologies into a single probabilistic score ranging from -1 (strong bearish) to +1 (strong bullish). Unlike single-indicator systems that can produce frequent false signals, AlphaBTC requires agreement across multiple analytical frameworks before generating directional signals.
METHODOLOGY - THE 9-INDICATOR CONSENSUS MODEL
Each indicator analyzes trend from a different mathematical perspective, providing a binary vote: +1 (bullish), -1 (bearish), or 0 (neutral). The average of all 9 votes creates the final probability score.
1. AADTREND (Average Absolute Deviation Trend)
Method: Calculates average absolute deviation from a moving average using 7 different MA types (SMA, EMA, HMA, DEMA, TEMA, RMA, FRAMA)
Logic: Price crossovers above/below AAD-adjusted bands signal trend changes
Purpose: Adapts to varying market volatility conditions
2. GAUSSIAN SMOOTH TREND (GST)
Method: Multi-stage smoothing using DEMA → Gaussian Filter → SMMA → Standard Deviation bands
Logic: Long when price > (SMMA + SDmultiplier), Short when price < (SMMA - SDmultiplier)
Purpose: Removes high-frequency noise while preserving trend structure
3. RTI (RELATIVE TREND INDEX)
Method: Percentile-based ranking system comparing current price to historical upper/lower trend boundaries
Logic: Generates 0-100 index score; >80 = bullish, <20 = bearish
Purpose: Identifies price position within statistical distribution
4. HIGHEST-LOWEST DEVIATIONS TREND
Method: Dual moving average system (100/50 periods) with dynamic standard deviation bands
Logic: Compares highest and lowest boundaries from both MAs to determine trend extremes
Purpose: Identifies breakouts from multi-timeframe volatility envelopes
5. 25-75 PERCENTILE SUPERTREND
Method: Modified SuperTrend using 25th and 75th percentile bands instead of simple highs/lows
Logic: ATR-based trailing stop system anchored to percentile boundaries
Purpose: More stable trend following by filtering outlier price spikes
6. TS VOLATILITY-ADJUSTED EWMA
Method: Exponentially Weighted Moving Average with dynamic period adjustment based on ATR
Logic: Speeds up during high volatility, slows during low volatility
Purpose: Adaptive responsiveness to changing market conditions
7. NORMALIZED KAMA OSCILLATOR
Method: Kaufman Adaptive Moving Average normalized to 0-centered oscillator
Logic: Uses Efficiency Ratio to adjust smoothing constant; >0 = bullish, <0 = bearish
Purpose: Adapts to both trending and ranging markets automatically
8. EHLERS MESA ADAPTIVE MOVING AVERAGE (EMAMA)
Method: John Ehlers' MAMA/FAMA system using Hilbert Transform for cycle period detection
Logic: MAMA crossover FAMA = bullish, crossunder = bearish
Purpose: Advanced DSP-based trend detection with phase-based adaptation
9. EMA Z-SCORE
Method: Statistical z-score applied to EMA values over lookback period
Logic: >1.0 standard deviation = bullish, <0.0 = bearish
Purpose: Identifies statistically significant trend deviations
AGGREGATION METHODOLOGY
Scoring System:
Each indicator produces: +1 (bullish), -1 (bearish), or 0 (neutral)
Total score = sum of all 9 indicators (-9 to +9)
Average score = total / 9 (displayed as -1.00 to +1.00)
Signal Interpretation:
+0.50 to +1.00: STRONG BULLISH (majority consensus)
+0.30 to +0.50: MODERATE BULLISH
-0.30 to +0.30: WEAK/NEUTRAL (mixed signals)
-0.50 to -0.30: MODERATE BEARISH
-1.00 to -0.50: STRONG BEARISH (majority consensus)
Bar Coloring:
Cyan bars: Bullish consensus (score > 0)
Magenta bars: Bearish consensus (score < 0)
WHY THIS APPROACH WORKS
Traditional Single-Indicator Problems:
Overfitting to specific market conditions
High false signal rates during consolidation
No mechanism for confidence measurement
AlphaBTC Multi-Consensus Solution:
Diversification: 9 uncorrelated methodologies reduce individual indicator bias
Robustness: Requires majority agreement before signaling (prevents whipsaws)
Adaptability: Mix of momentum, volatility, and statistical indicators captures multiple market regimes
Confidence Measurement: Score magnitude indicates signal strength
Why These 9 Specific Indicators:
AADTrend - Volatility adaptation
GST - Noise filtering
RTI - Statistical positioning
HL Deviations - Multi-timeframe breakouts
Percentile ST - Robust trend following
Volatility EWMA - Dynamic responsiveness
KAMA - Efficiency-based adaptation
EMAMA - Cycle-period awareness
EMA Z-Score - Statistical confirmation
This combination covers:
Trend following (ST, EWMA, KAMA, EMAMA)
Volatility adaptation (AAD, GST, HL Dev, EWMA)
Statistical validation (RTI, Z-Score)
Adaptive smoothing (KAMA, EMAMA, Gaussian)
No single indicator covers all these bases. The ensemble approach creates a more reliable system.
VISUAL COMPONENTS
1. Score Table (Bottom Right):
Shows all 9 individual indicator scores
Color-coded: Green (bullish), Red (bearish), Gray (neutral)
Individual signals visible for transparency
2. Main Score Display (Bottom Center):
LTPI SCORE: The averaged consensus (-1.00 to +1.00)
SIGNAL: Current directional bias (LONG/SHORT)
STRENGTH: Signal confidence (STRONG/MODERATE/WEAK)
3. Bar Coloring:
Visual trend indication directly on price bars
Cyan = bullish consensus
Magenta = bearish consensus
HOW TO USE
For Long-Term Position Trading (Recommended):
Wait for average score to cross above 0 for long entries
Exit when score crosses below 0 or reverses to negative territory
Use STRENGTH indicator - only trade STRONG or MODERATE signals
For Trend Confirmation:
Use AlphaBTC as confluence with your existing strategy
Enter trades only when AlphaBTC agrees with your analysis
Avoid counter-trend trades when consensus is strong (|score| > 0.5)
Risk Management:
STRONG signals (|score| > 0.5): Full position size
MODERATE signals (0.3-0.5): Reduced position size
WEAK signals (< 0.3): Avoid trading or use for exits only
Best Timeframes:
1D chart: Primary trend identification for swing/position trading
4H chart: Intermediate trend for multi-day holds
1H chart: Short-term trend for active trading
Not Recommended:
Scalping (too many indicators create lag)
Timeframes < 1H (designed for longer-term trends)
SETTINGS EXPLAINED
Each of the 9 indicators has customizable parameters in its dedicated settings group:
AadTrend Settings:
Average Length (48): Base period for deviation calculation
AAD Multiplier (1.35): Band width adjustment
Average Type: Choose from 7 different MA types
GST Settings:
DEMA Length (9), Gaussian Length (4), SMMA Length (13)
SD Length (66): Standard deviation lookback
Multipliers for upper/lower bands
RTI Settings:
Trend Length (75): Historical data points for boundary calculation
Sensitivity (88%): Percentile threshold
Long/Short Thresholds (80/20): Entry trigger levels
HL Deviations Settings:
Dual MA system (100/50 periods)
Separate deviation coefficients for upper/lower bands
25-75 Percentile ST Settings:
SuperTrend Length (100)
Multiplier (2.35)
Percentile Length (50)
EWMA Settings:
Length (81), ATR Lookback (14)
Volatility Factor (1.0) for dynamic adjustment
KAMA Settings:
Fast/Slow Periods (50/100)
Efficiency Ratio Period (8)
Normalization Lookback (53)
EMAMA Settings:
Fast/Slow Limits (0.08/0.01) for cycle adaptation
EMA Z-Score Settings:
EMA Length (50)
Lookback Period (25)
Threshold levels for long/short signals
ALERTS
Four alert conditions available:
LTPI Long Signal: When average score crosses above 0
LTPI Short Signal: When average score crosses below 0
LTPI Long: Any bar with bullish consensus
LTPI Short: Any bar with bearish consensus
IMPORTANT NOTES
This is a CONSENSUS indicator - it shows probability, not prediction
Designed for Bitcoin
Best for long-term trend identification (days to weeks, not minutes to hours)
Lagging by design - prioritizes accuracy over speed
Not a standalone strategy - use with proper risk management and position sizing
Requires minimum 100+ bars of historical data for proper indicator calculation
Daytrade Forex Scalper TwinPulse Auction Timer IndicatorWhat this indicator is
TwinPulse Auction Timer is a multi component execution aid designed for liquid markets. It looks for two families of opportunities
Breakouts that leave a compression area after a fresh sweep
Reversals that trigger after a sweep with strong wick polarity
It does not try to predict future prices. It measures present auction conditions with transparent rules and shows you when those conditions align. You get a simple table that says LONG SHORT or WAIT, optional session shading, clean entry and exit level visuals, and alerts you can wire to your workflow.
Why it is different
Most tools show a single signal. TwinPulse combines several independent signals into an Edge Score that you can tune. The components are
• Pulse. A signed measure of wick asymmetry with candle body direction
• Compression. Current true range compared with an average range
• Sweep timer. Bars elapsed since the most recent sweep of a prior high or low
• Bias. Direction of a higher timeframe candle
• Regime. Efficiency ratio and the relation of micro to macro volatility
• Location. Distance from the daily anchored VWAP
• Session. London and New York filter by time windows
Each component is visible in the inputs and in the table so you can understand why a suggestion appears. The script uses request.security() with lookahead off in all calls so it does not peek into the future. Shapes may move while a bar is open since price is still forming. They stop moving when the bar closes.
What you will see on the chart
• L and S shapes on entry bars
• An Exit shape at the price where a stop or the runner target would have been hit
• Four horizontal lines while a trade is active
Entry
Stop
TP1 at one R
TP2 at the runner target expressed in R
• Labels anchored to each line so you can instantly read Entry SL TP1 and TP2 with current values
• Optional shading during your session windows
• Optional daily VWAP line
The table in the top right shows
Action LONG SHORT IN LONG IN SHORT or WAIT
Session ON or OFF
Bias UP DOWN or FLAT
Pulse value
Compression value
Edge L percent and Edge S percent
How it works in detail
Pulse
For each bar the script measures up wick minus down wick divided by range and multiplies that by the sign of the candle body. The result is averaged with pulse_len. Positive numbers indicate aggressive buying. Negative numbers indicate aggressive selling. You control the minimum absolute value with pulse_thr.
Compression
Compression is the ratio of current range to an average range. You can choose the range basis. HL SMA uses simple high minus low smoothed by range_len. ATR uses classic True Range smoothed by atr_len. Values below comp_thr indicate a coil.
Sweeps and the timer
A sweep occurs when price trades beyond the highest high or lowest low seen in the previous sweep_len bars. A strict sweep requires a close back inside that prior range. The timer measures how many bars have elapsed since the last sweep. Breakout setups require the timer to exceed timer_thr.
Bias on a confirmation timeframe
A higher timeframe candle is read with confirm_tf. If close is above open bias is UP. If close is below open bias is DOWN. This keeps breakouts aligned with the prevailing drift.
Regime filters
Efficiency ratio measures the straight line change over the sum of absolute bar to bar changes over er_len. It rises in trendy conditions and falls in noise. Minimum efficiency is controlled by er_min.
Micro to macro volatility ratio compares a short lookback average range with a longer lookback average range using your chosen basis. For breakouts you usually want micro volatility to be near or above macro hence mvr_min. For reversals you often want micro volatility that is not overheated relative to macro hence mvr_max_rev.
VWAP distance gate
Daily anchored VWAP is rebuilt from the open of each session. The script computes the absolute distance from VWAP in units of your average range and requires that distance to exceed vwap_dist_thr when use_vwap_gate is true. This keeps entries away from the mean.
Edge Score
Each gate contributes a weight that you control. The script sums weights of the satisfied gates and divides by the sum of all weights to produce an Edge percent for long and an Edge percent for short. You can then require a minimum Edge percent using edge_min_pct. This turns the indicator into a step by step checklist that you can tune to your taste.
Using the indicator step by step
Choose markets and timeframes
The logic is designed for liquid instruments. Major currency pairs, index futures and cash index CFDs, and the most liquid crypto pairs work well. On intraday use one to fifteen minutes for signals and fifteen to sixty minutes for confirmation. On swing use one hour to one day for signals and one day for confirmation.
Decide on entry mode
Breakouts require a compression area and a sweep timer. Reversals require a strict sweep and a strong pulse. If you are unsure leave the default which allows both.
Pick a range basis
For FX and crypto HL SMA is often stable. For indices and single name equities with gaps ATR can adapt better. If results look too reactive increase the window. If results are too slow reduce it.
Tune regime filters
If you trade trend continuation raise er_min and mvr_min. If you trade counter rotation lower them and rely on the reversal path with the strict sweep condition.
Set the VWAP gate
Enabling it helps you avoid entries at the mean. Push the threshold higher on range bound days. Reduce it in strong trend days.
Table driven decision
Watch Action and the Edge percents. If the script says WAIT you can read Pulse and Compression to see what is missing. Often the best trades appear when both Edge percents are well separated and your session switch is ON.
Use the visuals
When a suggestion triggers you will see entry stop and targets. You can mirror the levels in your own workflow or use alerts.
Consider bar close
Signals are computed in real time. For a strict process you can wait until the bar closes to reduce noise.
Inputs explained with quick guidance
Setup
Signal TF chooses where the logic is computed. Leave blank to use the chart.
Confirm TF sets the higher timeframe for bias.
Session filter restricts signals to the London and New York windows you specify.
Invert flips long and short. It is useful on inverse instruments.
Logic options
Entry mode allows Breakouts Reversals or Both.
Average range basis selects HL SMA or ATR.
ATR length is used when ATR is selected.
Pulse source can be Regular OHLC or Heikin Ashi. Heikin Ashi smooths noisy series, but the script still runs on regular bars and you should publish and use it on standard candles to respect the platform guidance.
Core numeric settings
Sweep lookback controls the size of the liquidity pool targeted by the sweep condition.
Pulse window smooths the wick polarity measure.
Average range window controls your base range when you use HL SMA.
Pulse threshold sets the minimum polarity required.
Compression threshold sets the maximum current range relative to average to consider the market coiled.
Expansion timer bars sets how much time has passed since the last sweep before you allow a breakout.
Regime filters
Efficiency ratio length and minimum value keep you out of aimless drift.
Micro and Macro range lengths feed the micro to macro ratio.
Minimum micro to macro for breakouts and maximum micro to macro for reversals steer the two entry families.
VWAP gate and distance threshold keep you away from the mean.
Levels and trade management visuals
Runner target in R sets TP2 as a multiple of initial risk.
Stop distance as average range multiple sets initial risk size for the visuals.
Move stop to entry after one R touch turns on break even logic once price has traveled one risk unit.
Trail buffer as R fraction uses the last sweep as an anchor and keeps a dynamic stop at a chosen fraction of R beyond it.
Cooldown after exit prevents immediate re entries.
Edge Score
Weights for pulse compression timer bias efficiency ratio micro to macro VWAP gate and session let you align the checklist with your style.
Minimum Edge percent to suggest applies a final filter to LONG or SHORT suggestions.
UI
Table and markers switch the compact dashboard and the shapes.
TP and SL lines and labels draw and name each level.
TP1 partial label percent is printed in the TP1 label for clarity.
Session shading helps with focus.
Daily VWAP line is optional.
Alerts
The script provides alerts for Long Short Exit and for Edge percent crossing the threshold on either side. Use them to drive notifications or to sync with webhooks and your broker integration. Alerts trigger in real time and will repaint during a bar. For conservative use trigger on bar close.
Recommended presets
Intraday trend continuation
Confirm TF fifteen minutes
Entry mode Breakouts
Range basis HL SMA
Pulse threshold near 0.10
Compression threshold near 0.60
Timer around 18
Minimum efficiency ratio near 0.20
Minimum micro to macro near 1.00
VWAP gate enabled with distance near 0.35
Edge minimum 50 or higher
Intraday mean reversion at sweeps
Entry mode Reversals
Pulse source Regular OHLC
Compression threshold can be a little higher
Maximum micro to macro near 1.60
Efficiency ratio minimum lower near 0.12
VWAP gate enabled
Edge minimum 40 to 60
Swing trend continuation
Signal TF one hour
Confirm TF one day
Range basis ATR
ATR length around 14
Average range window 20 to 30
Efficiency ratio minimum near 0.18
Micro to macro windows 12 and 60
Edge minimum 50 to 70
These are starting points only. Your instrument and timeframe will require small adjustments.
Limitations and honest warnings
No indicator is perfect. TwinPulse will mark attractive conditions that do not always lead to profitable trades. During economic releases or very thin liquidity the assumptions behind compression and sweeps may fail. In strong gap environments the HL SMA basis may lag while ATR may overreact. Heikin Ashi pulse can help in choppy markets but it will lag during sharp reversals. Session times use the exchange time of your chart. If you switch symbol or exchange verify the windows.
Edge percent is not a probability of profit. It is the fraction of satisfied gates with your chosen weights. Two traders can set different weights and see different Edge readings on the same bar. That is the design. The score is a guide that helps you act with discipline.
This indicator does not place orders or manage real risk. The lines and labels show a model entry a model stop and two model targets built from the average range at entry and from recent swing points. Use them as references and not as hard rules. Always test on historical data and demo first. Past results do not guarantee anything in the future.
Credits and originality
All code in this publication is original and written for this indicator. The concept of the efficiency ratio originates from Perry Kaufman. The use of a daily anchored volume weighted average price is a standard industry tool. The specific combination of pulse from wick polarity strict sweep timing compression and the tunable Edge Score is unique to this script at the time of publication. If you reuse parts of the open source code in your own work remember to credit the author and contribute meaningful improvements.
How to read the table at a glance
Action reflects your current state.
IN LONG or IN SHORT appears while a trade is active.
LONG or SHORT appears when conditions for entry are met and the Edge threshold is satisfied.
WAIT appears when at least one gate is missing.
Session shows ON during your chosen windows.
Bias shows the color of the confirmation candle.
Pulse is the smoothed polarity number.
Comp shows current range divided by the average range. Values below one mean compression.
Edge L percent and Edge S percent show the long and short checklists as percents.
Final thoughts
Markets move because orders accumulate at certain prices and at certain times. The indicator tries to measure two things that often matter at those turning points. One is the existence of a hidden imbalance revealed by wick polarity and by sweeps of prior extremes. The other is the presence of energy stored in a coil that can release in the direction of a drift. Neither force guarantees profit. Together they can improve your selection and your timing.
Use the defaults for a few days so you learn the personality of the signals. After that adjust one group at a time. Start with the session filter and the Edge threshold. Then tune compression and the timer. Finally adjust the regime filters. Keep notes. You will learn which weights matter for your market and timeframe. The result is a process you can apply with consistency.
Disclaimer
This script and description are for education and analysis. They are not investment advice and they do not promise future results. Use at your own risk. Test thoroughly on historical data and in simulation before considering any live use.
50% Fib Trend Cloud + ATR BandsThis indicator plots two structural 50% fibonacci midpoints from recent confirmed 'left/right' swings that form a *cloud* of equilibrium, then adds a rolling 50% fibonacci range midpoint based on a lookback window that's wrapped in ATR bands. Importantly, it solves a specific trading problem:
Structural midpoints (macro context) are powerful but can lag when price escapes prior ranges. Enter rolling 50% fib + ATR ➡️ which restores real-time balance & tolerance (micro context). Together they show where price is balanced structurally, where it’s balanced right now, and how much volatility to tolerate before acting.
➖➖➖
🔑 Why this is different
Most tools either draw a single midpoint (ex., daily 50%) or ATR bands around a moving average. This script fuses dual swing-based 50% midpoints (structure) + a rolling 50% with ATR (flow), so you don’t lose context when price escapes prior ranges. The cloud tells you who’s in control (fast vs. slow structure). The rolling 50% + ATR tells you how far is “too far” now.
➖➖➖
🧠 What it does (at a glance)
🔸Structural Equilibrium × 2 (Fib1/Fib2)
Two independent 50% midpoints formed from swing pivots (configurable Left/Right bars + optional smoothing). Their gap is the Midpoint Cloud = structural “fair value” zone.
🔸Rolling 50% + ATR Bands
A rolling highest/lowest window computes an always-current 50% rolling midpoint plot; ±ATR × length envelopes define a soft value area and over-stretch boundaries.
🔸Actionable Visuals
Optional fill between Fib1/Fib2, labels, and candle-overlay modes to instantly read regime (above both / below both / between).
🔸Smart Defaults
Timeframe-aware presets for L/R pivots & smoothing; full manual overrides available.
➖➖➖
⚙️ Calculations (plain-English)
🔸Pivot midpoints (Fib1 & Fib2):
1) Detect a swing using `Left/Right` bars
2) Take the swing’s high/low → compute 50%
3) (Optional) Smooth the line (SMA) to stabilize on noisy TFs
4) Repeat with a different sensitivity to get two distinct midpoints
🔸Rolling midpoint:
Highest High / Lowest Low over the last *N* bars → (HH + LL) / 2
🔸ATR levels:
`Upper = Rolling50 + ATR × Mult`, `Lower = Rolling50 − ATR × Mult`
(Typical: ATR length 14–21; Multipliers 2.236 for L1, 5.382 for L2)
➖➖➖
🤖 Auto-Configured Presets (with Manual Override)
💡Goal: make the midpoints “just work” on common timeframes while still letting you dial them in.
💡How Auto Presets work
When Auto Presets = ON, the script picks sensible L/R/S (Left bars / Right bars / Smoothing) for Fib Trend 1 and Fib Trend 2 based on chart timeframe.
🔸Fib 1 (fast) emphasizes *micro-structure* for quicker bias shifts.
🔸Fib 2 (slow) emphasizes *macro-structure* for anchor/bias context.
These defaults keep Fib 1 responsive without jitter and Fib 2 stable without lag.
➡️ Turn Auto Presets = OFF to take full control with the manual inputs described below.
➖➖➖
🛠 Manual Fib Midpoint Settings (when Auto = OFF)
💡Each midpoint uses three knobs:
🔸Pivot Left (L): bars to the left that must be lower/higher to qualify a swing
🔸Pivot Right (R): bars to the right that must be lower/higher to confirm the swing
🔸Smoothing (S): SMA period applied to the raw 50% midpoint (stabilizes noise)
5-Minute optimized defaults
🔸Fib Trend 1: `L21 / R5 / S55` → responsive local structure (entries/exits, re-balancing zones)
🔸Fib Trend 2: `L55 / R13 / S89` → broader structure (trend context, anchors/stops)
Timeframe guidance
🔸1m–3m: may feel a touch laggy → consider ~`L13 / R3 / S34`
🔸15m–1h: defaults remain strong → optionally ~`L34 / R8 / S89`
🔸4h+ : increase span for stability → `L89–144 / R13–21 / S144–233`
➡️ Rule of thumb: shorter L/R = faster detection, longer S = smoother line. Tune until Fib 1 captures the “active swing” and Fib 2 captures the “dominant swing” without whipsaw.
➖➖➖
🎛 Inputs (quick reference)
🔸Fib Trend 1/2: Source (High/Low/Close), Left/Right bars, Smoothing length, Show/Hide, Cloud fill toggle
🔸Rolling 50%: Lookback length, Price basis (Wicks/Close/HLC3/OHLC4), Plot scope (Full / Last N / None)
🔸ATR Bands: ATR length, Multipliers (L1/L2), Plot scope, Line width/colors
🔸Overlay & Labels: Candle overlay mode, Label padding/size, 50% centerline toggle, Plot widths
➖➖➖
🖍️ Candle Coloring & Overlay Modes
💡Purpose: make trend instantly visible on the candles and ATR levels.
1) Color Logic (dropdown)
🔸 Fib Midpoints — Colors by position of price vs. Fib 1 & Fib 2
🔸ATR Zones — Colors by which ATR zone price is in relative to the Rolling 50%
➡️ Price Reference: Choose the input used for the decision (Close, HL2, OHLC3, OHLC4).
➡️Tip: Close is crisp; HL2/OHLC variants are smoother.
2) Overlay Style (dropdown)
🔸 None — No visual change to candles
🔸 Bar Color — Uses `barcolor()` to tint built-in candles (this takes into account your Trading View settings, for instance if you have wicks set to white, they will show up as white with this setting)
🔸 PlotCandles — Draws unified custom candles (body, wick, border) with the same color for maximum clarity
💡Practical use
🔸 Pick Fib Midpoints to read structural bias at a glance (above/below/between the cloud).
🔸 Pick ATR Zones to read value vs. stretch around the Rolling 50% (mean-reversion vs. trend extension).
➖➖➖
📘 How to use
A) Trend confirmation
- Strong bullish bias when price holds above both structural mids; strong bearish when below both.
- Use the Rolling 50% + ATR as a dynamic re-entry zone: pullbacks that respect ATR(L1) often continue the prevailing trend.
B) Transition / mean reversion
- Inside the Cloud (between Fib1 & Fib2) treat behavior as neutralization/re-balancing; range tactics tend to outperform momentum plays.
- In ranges, fades near ±ATR around the rolling 50% can mark short-term edges.
C) Breakout context
- When price leaves the Cloud, the Rolling 50% keeps you anchored so price never feels “floating.” A clean hold outside ATR(L1/L2) suggests regime strength; quick re-entries hint at traps.
➖➖➖
🖼 Chart examples
➡️ Each snapshot shows how the Cloud (structure) and the Rolling 50% + ATR (flow) work together.
1) 1-Minute Downtrend – Cloud as Dynamic Ceiling
- The Cloud slopes down; pullbacks repeatedly fail under the Cloud’s underside.
- Rolling 50% (dashed mid) + ATR(L1) act as a reversion band: rallies stall near upper ATR and rotate lower.
2) 15-Minute Persistent Drift – Structure Guides, Flow Times Entries
- Long drift lower with Cloud overhead.
- Consolidations near the rolling mid resolve in the trend direction; ATR bands frame risk on each attempt.
3) 15-Minute Uptrend (BTC) – From Cloud Escape to Value Stair-Step
- After escaping the prior Cloud, rolling 50% + ATR establish a new higher value area.
- Pullbacks into ATR(L1) produce orderly stair-steps; Cloud remains supportive on deeper dips
4) 5-Minute BTC – Pullback to Value then Rotate
- Strong leg up; retrace tags lower ATR band and rotates back toward the rolling mid.
- Labels (Fib1/Fib2) make the structural context explicit for decision-making.
➖➖➖
🧪 Starter presets
- Intraday (5–15m): Fib1 ~ L21/R5 (smooth 5), Fib2 ~ L55/R13 (smooth 9) • Rolling = 55 • ATR = 14 • L1 = 2.5x, L2 = 5.0x
- Scalping: Shorten lookbacks & smoothing; keep ATR multipliers similar, or tighten L1.
- Swing: Lengthen all lookbacks; consider ATR length 21–28.
➖➖➖
🏁Final Word
This script is not just a visual tool, it’s a complete trend and structure framework. Whether you're looking for clean trend alignment, dynamic support/resistance, or early warning signs of a reversal, this system is tuned to help you react with confidence — not hindsight.
Rembember, no single indicator should be used in isolation. For best results, combine it with price action analysis, higher-timeframe context, and complementary tools like trendlines, moving averages etc Use it as part of a well-rounded trading approach to confirm setups — not to define them alone.
---
💡Turn logic into clarity. Structure into trades. And uncertainty into confidence.
Bitcoin Cycle History Visualization [SwissAlgo]BTC 4-Year Cycle Tops & Bottoms
Historical visualization of Bitcoin's market cycles from 2010 to present, with projections based on weighted averages of past performance.
-----------------------------------------------------------------
CALCULATION METHODOLOGY
Why Bottom-to-Bottom Cycle Measurement?
This indicator defines cycles as bottom-to-bottom periods. This is one of several valid approaches to Bitcoin cycle analysis:
- Focuses on market behavior (price bottoms) rather than supply schedule events (halving-to-halving)
- Bottoms may offer good reference points for some analytical purposes
- Tops tend to be extended periods that are harder to define precisely
- Aligns with how some traditional asset cycles are measured and the timing observed in the broader "risk-on" assets category
- Halving events are shown separately (yellow backgrounds) for reference
- Neither halving-based nor bottom-based measurement is inherently superior
Different analysts prefer different cycle definitions based on their analytical goals. This approach prioritizes observable market turning points.
Cycle Date Definitions
- Approximate monthly ranges used for each event (e.g., Nov 2022 bottom = Nov 1-30, 2022)
- Cycle 1: Jul 2010 bottom → Jun 2011 top → Nov 2011 bottom
- Cycle 2: Nov 2011 bottom → Dec 2013 top → Jan 2015 bottom
- Cycle 3: Jan 2015 bottom → Dec 2017 top → Dec 2018 bottom
- Cycle 4: Dec 2018 bottom → Nov 2021 top → Nov 2022 bottom
- Future cycles will be added as new top/bottom dates become firm
Duration Calculations
- Days = timestamp difference converted to days (milliseconds ÷ 86,400,000)
- Bottom → Top: days from cycle bottom to peak
- Top → Bottom: days from peak to next cycle bottom
- Bottom → Bottom: full cycle duration (sum of above)
Price Change Calculations
- % Change = ((New Price - Old Price) / Old Price) × 100
- Example: $200 → $19,700 = ((19,700 - 200) / 200) × 100 = 9,750% gain
- Approximate historical prices used (rounded to significant figures)
Weighted Average Formula
Recent cycles weighted more heavily to reflect the evolved market structure:
- Cycle 1 (2010-2011): EXCLUDED (too early-stage, tiny market cap)
- Cycle 2 (2011-2015): Weight = 1x
- Cycle 3 (2015-2018): Weight = 3x
- Cycle 4 (2018-2022): Weight = 5x
Formula: Weighted Avg = (C2×1 + C3×3 + C4×5) / (1+3+5)
Example for Bottom→Top days: (761×1 + 1065×3 + 1066×5) / 9 = 1,032 days
Projection Method
- Projected Top Date = Nov 2022 bottom + weighted avg Bottom→Top days
- Projected Bottom Date = Nov 2022 bottom + weighted avg Bottom→Bottom days
- Current days elapsed compared to weighted averages
- Warning symbol (⚠) shown when the current cycle exceeds the historical average
Technical Implementation
- Historical cycle dates are hardcoded (not algorithmically detected)
- Dates represent approximate monthly ranges for each event
- The indicator will be updated as the Cycle 5 top and bottom dates become confirmed
- Updates require manual code maintenance - not automatic
- Users should verify they're using the latest version for current cycle data
-----------------------------------------------------------------
FEATURES
- Background highlights for historical tops (red), bottoms (green), and halving events (yellow)
- Data table showing cycle durations and price changes
- Visual cycle boundary boxes with subtle coloring
- Projected timeframes displayed as dashed vertical lines
- Toggle on/off for each visual element
- Customizable background colors
-----------------------------------------------------------------
DISPLAY SETTINGS
- Show/hide cycle tops, bottoms, halvings, data table, and cycle boxes
- Customizable background colors for each event type
- Clean, institutional-grade visual design suitable for analysis
UPDATES & MAINTENANCE
This indicator is maintained as new cycle events occur. When Cycle 5's top and bottom are confirmed with sufficient time elapsed, the code and projections will be updated accordingly. Check for the latest version periodically.
OPEN SOURCE
Code available for review, modification, and improvement. Educational transparency is prioritized.
-----------------------------------------------------------------
IMPORTANT LIMITATIONS
⚠ EXTREMELY SMALL SAMPLE SIZE
Based on only 4 complete cycles (2011-2022). In statistical analysis, this is insufficient for reliable predictions.
⚠ CHANGED MARKET STRUCTURE
Bitcoin's market has fundamentally evolved since early cycles:
- 2010-2015: Tiny market cap, retail-only, unregulated
- 2024-2025: Institutional adoption, spot ETFs, regulatory frameworks, macro correlation
The environment that created past patterns no longer exists in the same form.
⚠ NO PREDICTIVE GUARANTEE
Historical patterns can and do break. Market cycles are not laws of physics. Past performance does not guarantee future results. The next cycle may not follow historical averages.
⚠ LENGTHENING CYCLE THEORY
Some analysts believe cycles are extending over time (diminishing returns, maturing market). If true, simple averaging underestimates future cycle lengths.
⚠ SELF-FULFILLING PROPHECY RISK
The halving narrative may be partially circular - it works because people believe it works. Sufficient changes in market structure or participant behavior can invalidate the pattern.
⚠ APPROXIMATE DATA
Historical prices rounded to significant figures. Exact bottom/top dates vary by exchange. Month-long ranges are used for simplicity.
EDUCATIONAL USE ONLY
This indicator is designed for historical analysis and understanding Bitcoin's past behavior. It is NOT:
- Trading advice or financial recommendations
- A guarantee or prediction of future price movements
- Suitable as a sole basis for investment decisions
- A replacement for fundamental or technical analysis
The projections show "what if the pattern continues exactly" - not "what will happen."
Always conduct independent research, understand the risks, and consult qualified financial advisors before making investment decisions. Only invest what you can afford to lose.
BTC Time CycleThis indicator helps track Bitcoin's historical four-year cycles by dividing time from market bottoms into Fibonacci-based segments, providing clear visual cues for potential bullish and bearish phases.
How It Works: This indicator overlays repeating Fibonacci-based time cycles onto weekly BTC charts , plotting vertical lines at key Fib ratios (0, 0.25, 0.382, 0.5, 0.618, 0.75, 1.0) to track cycle progress. Each cycle concludes at 1.0 and seamlessly resets as the next cycle's 0, capturing historical trough-to-trough intervals like those observed from 2018 to 2022. The week preceding the 0.75 Fibonacci ratio typically signals the cycle peak and bear market onset, transitioning through the final phase until 1.0 initiates a new cycle.
Disclaimer: This pattern has consistently repeated in past cycles, but financial markets are inherently unpredictable—it is not guaranteed to persist and remains valid only until disproven. Treat it as an analytical aid, not a predictive certainty.
This is merely a curiosity and is: True until it isn't™
Cycle Indicator CS7This indicator visualizes cyclical structures (including inverse cycles) for financial instruments.
It is highly customizable and comes with a default configuration optimized for cryptocurrencies on a 45-minute timeframe, highlighting the following cycles:
• T-3: Daily cycles
• T-2: Approximately 2-day cycles
• T+1: Bi-weekly cycles
• T-1: Approximately 4-day cycles
• T: Weekly cycles
The same setup can also be applied effectively on a 24-hour timeframe, highlighting the following longer-term cycles:
• T+2: Monthly cycles
• T+3: Quarterly cycles
• T+4: Semi-annual cycles
• T+5: Annual cycles
• T+6: Bi-annual cycles
Users can customize the configurations to suit the specific characteristics of any financial instrument.
Additionally, the indicator includes a prediction system that approximates future cycles, marking them with a “?”.
Trend Pro V2 [CRYPTIK1]Introduction: What is Trend Pro V2?
Welcome to Trend Pro V2! This analysis tool give you at-a-glance understanding of the market's direction. In a noisy market, the single most important factor is the dominant trend. Trend Pro V2 filters out this noise by focusing on one core principle: trading with the primary momentum.
Instead of cluttering your chart with confusing signals, this indicator provides a clean, visual representation of the trend, helping you make more confident and informed trading decisions.
The dashboard provides a simple, color-coded view of the trend across multiple timeframes.
The Core Concept: The Power of Confluence
The strength of any trading decision comes from confluence—when multiple factors align. Trend Pro V2 is built on this idea. It uses a long-term moving average (200-period EMA by default) to define the primary trend on your current chart and then pulls in data from three higher timeframes to confirm whether the broader market agrees.
When your current timeframe and the higher timeframes are all aligned, you have a state of "confluence," which represents a higher-probability environment for trend-following trades.
Key Features
1. The Dynamic Trend MA:
The main moving average on your chart acts as your primary guide. Its color dynamically changes to give you an instant read on the market.
Teal MA: The price is in a confirmed uptrend (trading above the MA).
Pink MA: The price is in a confirmed downtrend (trading below the MA).
The moving average changes color to instantly show you if the trend is bullish (teal) or bearish (pink).
2. The Multi-Timeframe (MTF) Trend Dashboard:
Located discreetly in the bottom-right corner, this dashboard is your window into the broader market sentiment. It shows you the trend status on three customizable higher timeframes.
Teal Box: The trend is UP on that timeframe.
Pink Box: The trend is DOWN on that timeframe.
Gray Box: The price is neutral or at the MA on that timeframe.
How to Use Trend Pro V2: A Simple Framework
Step 1: Identify the Primary Trend
Look at the color of the MA on your chart. This is your starting point. If it's teal, you should generally be looking for long opportunities. If it's pink, you should be looking for short opportunities.
Step 2: Check for Confluence
Glance at the MTF Trend Dashboard.
Strong Confluence (High-Probability): If your main chart shows an uptrend (Teal MA) and the dashboard shows all teal boxes, the market is in a strong, unified uptrend. This is a high-probability environment to be a buyer on dips.
Weak or No Confluence (Caution Zone): If your main chart shows an uptrend, but the dashboard shows pink or gray boxes, it signals disagreement among the timeframes. This is a sign of market indecision and a lower-probability environment. It's often best to wait for alignment.
Here, the daily trend is down, but the MTF dashboard shows the weekly trend is still up—a classic sign of weak confluence and a reason for caution.
Best Practices & Settings
Timeframe Synergy: For best results, use Trend Pro on a lower timeframe and set your dashboard to higher timeframes. For example, if you trade on the 1-hour chart, set your MTF dashboard to the 4-hour, 1-day, and 1-week.
Use as a Confirmation Tool: Trend Pro V2 is designed as a foundational layer for your analysis. First, confirm the trend, then use your preferred entry method (e.g., support/resistance, chart patterns) to time your trade.
This is a tool for the community, so feel free to explore the open-source code, adapt it, and build upon it. Happy trading!
For your consideration @TradingView
BTC Lead(v3.32)Summary
A 15-minute, BTC-focused lead/divergence indicator designed for simple execution: when a ▲/▼ appears, start scaling in with small clips; when a ■ (black square) prints, it means the indicator’s edge has weakened (not that the market trend is over). Real-time expected move label and alert templates included. Do not fade the signal—if you must try the opposite side, wait until a ■ appears.
How to read the signals
▲ Green → Long bias increased
▼ Pink → Short bias increased
■ Black → Edge weakened; consider taking profits/standing aside
Multiple level markers on the same bar (L2/L3/L4) = stronger setup
Live label (top of chart)
A single line shows the Expected Move (%) with arrow and color-coded background (↑ green / ↓ pink) for instant direction clarity.
Tip: Use Replay to watch label → ▲/▼ → ■ sequences on past data.
Confidence filter (important)
|Expected Move| < 1% → treat as noise / ignore
If considering the opposite direction, wait for a ■ first (edge reduced).
Scope
Internal calculations are fixed to 15-minute resolution.
Built for BTC 15m. It may display on other crypto symbols/timeframes, but performance is not guaranteed.
Alerts
Ready-made conditions: ENTRY LONG / ENTRY SHORT / EXIT LONG / EXIT SHORT. Add an alert on this indicator and choose the condition you want.
Risk note
For research/education only. Past behavior doesn’t guarantee future results. Predefine position sizing, stops, and profit-taking, and execute consistently.
BTC Lead(v3.31)Summary
A 15-minute, BTC-focused lead/divergence indicator designed for simple execution: when a ▲/▼ appears, start scaling in with small clips; when a ■ (black square) prints, it means the indicator’s edge has weakened (not that the market trend is over). Real-time expected move label and alert templates included. Do not fade the signal—if you must try the opposite side, wait until a ■ appears.
How to read the signals
▲ Green → Long bias increased
▼ Pink → Short bias increased
■ Black → Edge weakened; consider taking profits/standing aside
Multiple level markers on the same bar (L2/L3/L4) = stronger setup
Live label (top of chart)
A single line shows the Expected Move (%) with arrow and color-coded background (↑ green / ↓ pink) for instant direction clarity.
Tip: Use Replay to watch label → ▲/▼ → ■ sequences on past data.
Confidence filter (important)
|Expected Move| < 1% → treat as noise / ignore
If considering the opposite direction, wait for a ■ first (edge reduced).
Scope
Internal calculations are fixed to 15-minute resolution.
Built for BTC 15m. It may display on other crypto symbols/timeframes, but performance is not guaranteed.
Alerts
Ready-made conditions: ENTRY LONG / ENTRY SHORT / EXIT LONG / EXIT SHORT. Add an alert on this indicator and choose the condition you want.
Risk note
For research/education only. Past behavior doesn’t guarantee future results. Predefine position sizing, stops, and profit-taking, and execute consistently.
Dynamic EMA Stack Support & ResistanceEvery trader needs reliable support and resistance — but static zones and lagging indicators won't cut it in fast-moving markets. This script combines a Fibonacci-based 5-EMA stacking system and left/right pivots that create dynamic support & resistance logic to uncover real-time structural shifts & momentum zones that actually adapt to price action. This isn’t just a mashup — it’s a complete built-from-the-ground-up support & resistance engine designed for scalpers, intraday traders, and trend followers alike.
🧠 🧠 🧠What It Does🧠 🧠 🧠
This script uses two powerful engines working in sync:
1️⃣ EMA Stack (5-EMA Framework)
Built on Fibonacci-based lengths: 5, 8, 13, 21, 34, (configurable) this stack identifies:
🔹 Bullish Stack: EMAs aligned from fastest to slowest (uptrend confirmation)
🔹 Bearish Stack: EMAs aligned inversely (downtrend confirmation)
🟡 Narrowing Zones: When EMAs compress within ATR thresholds → possible breakout or reversal zone
🎯 Labels identify key transitions like:
✅"Begin Bear Trend?"
✅"Uptrend SPRT"
✅"RES?" (resistance test)
2️⃣ Pivot-Based Projection Engine
Using classic Left/Right Bar pivot logic, the script:
📌 Detects early-stage swing highs/lows before full confirmation
📈 Projects horizontal S/R lines that adapt to market structure
🔁 Keeps lines active until a new pivot replaces them
🧩 Syncs beautifully with EMA stack for confluence zones
🎯🎯🎯Key Features for Traders🎯🎯🎯
✅ Trend Detection
→ EMA order reveals real-time bias (bullish, bearish, compression)
✅ Dynamic S/R Zones
→ Historical support/resistance levels auto-draw and extend
✅ Smart Labeling
→ “SPRT”, “RES”, and “Trend?” labels for live context + testing logic
✅ Custom Candle Coloring
→ Choose from Bar Color or Full Candle Overlay modes
✅ Scalper & Swing Compatible
→ Use fast confirmations for scalping or stack consistency for longer trends
⚙️⚙️⚙️How to Use⚙️⚙️⚙️
✅Use Top/Bottom (trend state) Line Colors to quickly read trend conditions.
✅Use Pivot-based support/resistance projections to anticipate where price might pause or reverse.
✅Watch for yellow/blue zones to prepare for volatility shifts/reversals.
✅Combine with volume or momentum indicators for added confirmation.
📐📐📐Customization Options📐📐📐
✅EMA lengths (5, 8, 13, 21, 34) — fully configurable - try 21,34,55, 89, 144 for longer term trend states
✅Left/Right bar pivot settings (default: 21/5)
✅Label size, visibility, and color themes
✅Toggle line and label visibility for clean layouts
✅“Max Bars Back” to control how deep history is scanned safely
🛠🛠🛠Built-In Safeguards🛠🛠🛠
✅ATR-based filters to stabilize compression logic
✅Guarded lookback (max_bars_back) to avoid runtime errors
✅Works on any asset, any timeframe
🏁🏁🏁Final Word🏁🏁🏁
This script is not just a visual tool, it’s a complete trend and structure framework. Whether you're looking for clean trend alignment, dynamic support/resistance, or early warning labels, this system is tuned to help you react with confidence — not hindsight.
Rembember, no single indicator should be used in isolation. For best results, combine it with price action analysis, higher-timeframe context, and complementary tools like trendlines, moving averages etc Use it as part of a well-rounded trading approach to confirm setups — not to define them alone.
💡💡💡Turn logic into clarity. Structure into trades. And uncertainty into confidence.💡💡💡
Heikin Ashi Overlay SuiteHeikin Ashi Overlay Suite is designed to give traders more control and clarity when working with Heikin Ashi candles — whether you're analyzing trend strength, reducing chart noise, or simply improving your visual read of market momentum. It works by layering multiple types of HA overlays and color systems on top of your standard candlestick chart — without switching chart types. With dynamic gradient coloring, smoothing options, and a predictive line tool, this script helps you see not just what the current trend is, but how strong it is, and what it would take to reverse it.
Heikin Ashi candles help reduce noise but this script goes further by:
➡️adding color intelligence that shows trend strength using a streak counter
➡️uses smoothing logic to clean up chop and whipsaws
➡️introduces a predictive close line — a subtle but powerful guide for anticipating trend flips before they happen
Everything is configurable: colors, candle sources, overlays, predictive tools, and line styles. It’s built for traders who want visual speed, but don’t want to sacrifice signal quality.
At its core, the script offers two powerful dropdown controls:
💥HA Color Scheme (Colors Regular Candles) — Applies Heikin Ashi-derived coloring to your regular candles based on trend direction or streak strength. This gives you instant visual context without switching to a separate chart type.
💥HA Candle Overlay Mode — Overlays actual Heikin Ashi-style candles directly on top of your chart, using your preferred source:
➡️Custom HA candles using internal formula logic
➡️TradingView’s built-in Heikin Ashi source with your own colors
➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖
🎨 Custom + Gradient HA Coloring🎨
See trend strength at a glance:
➡️1–4 bar streaks → lighter tone
➡️5–8 bars → medium tone
➡️9+ bars → bold tone, ideal for momentum-based entries, exits, or scaling strategies
→ Choose from:
➡️Your own custom color set
➡️A simple 2-color base mode
➡️Or a 3-level gradient for progressive trend analysis (using the streak counter)
🏛️ TradingView Official Heikin Ashi Overlay
Prefer native HA candles but want your own colors?
This mode plots TradingView's Heikin Ashi source, with your personal bullish/bearish color scheme.
➡️Ensures consistency with built-in charts while still leveraging your visual style.
🌊 Smoothed Heikin Ashi Candles — Clarity in Chaos🌊
These aren’t your standard HA candles. Smoothed Heikin Ashi uses a two-step EMA process to transform chaotic price action into a cleaner, slower-moving trend structure:
🔹 First, it smooths the raw OHLC data using EMA — filtering out minor price fluctuations.
🔹 Then, it applies the Heikin Ashi transformation on top of the smoothed data.
🔹 Finally, it applies a second EMA smoothing pass to the HA values — creating ultra-smooth candles.
📈 What You See:
Trends appear more fluid and consistent.
Choppy ranges and fakeouts are visually suppressed.
Minor pullbacks within a trend are de-emphasized, helping you avoid premature exits.
🎯 Best For:
Swing traders looking to stay in positions longer.
Intraday traders dealing with volatile or noisy instruments.
Anyone who wants a "trend map" overlay without the distractions of raw price action.
✅ Reduces whipsaws
✅ Delivers high-contrast trend zones
✅ Makes reversals more visually apparent (but with a slight lag)
📍 Predictive Close Line📍
Shows where the real close must land to flip the current HA candle's color.
✅ Use it like predictive support/resistance
✅ Know if the trend is actually at risk
✅Visualize potential fakeouts or confirmation
Color-coded based on current HA direction (bullish, bearish, or neutral).
📈 Tick by tick & bar-to-bar Plots📈
Provides 2 plot types:
1)1 plot that tracks a bar tick by tick
2)another plot that tracks the close from bar to bar
For the bar to bar plot, you can choose between 2 options:
✅Full Plot — continuous line colored by HA trend
✅Recent Segments — color just the last few bars (configurable) to reduce chart clutter
✅ Customize width, number of bars, and visibility
➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖
📘 How to Use this script📘
Imagine you're watching a choppy 15-minute chart on a volatile crypto pair — price action is messy, and it’s hard to tell if a trend is forming or just noise.
Here’s how to cut through the chaos using Heikin Ashi Overlay Suite:
🔹 Step 1: Enable "Smoothed HA Candles"
Start by turning on the smoothed candles. You’ll immediately notice the noise fades, and broader directional moves become easier to follow. It's like switching from static to clean trend zones.
🧠 Why: Smoothed HA uses a double EMA process that filters out small reversals and lets larger moves stand out. Perfect for sideways or jittery charts.
🔹 Step 2: Watch the Color Gradient Build
As the smoothed candles begin to align in one direction, the gradient coloring (1–4, 5–8, 9+ streaks) gives you an at-a-glance visual of how strong the trend is.
✅ If you see 9+ same-colored candles? You’re likely in a mature trend.
✅ If it resets often? You’re in chop — consider staying out.
🔹 Step 3: Use the Predictive Close Line for Anticipation
Now here’s the edge — this line tells you where the candle would have to close to flip colors.
📉 If price is hovering just above it during a bullish run — momentum may be weakening.
📈 If price bounces off it — the trend may be strengthening.
This is excellent for confirming entries, exits, or spotting early warning signs.
🔹 Step 4: Switch Between Candle Modes as Needed
You can flip between:
✅ Custom HA: Gradient candles with your colors
✅ TradingView HA: The official source with your styling
✅ None: Just color regular candles using the HA logic
Use what fits your style — everything is modular.
🔹 Step 5: Tune It to Your Chart
Lastly, tweak streak thresholds (currently only can do this within the source code), smoothing lengths, and line styles to match your timeframe and strategy.
🎯 Tailor The Settings to Fit Your Trading Style🎯
🔹 🧪 Scalper (1–5 min charts)
If you’re trading fast intraday moves, you want quicker responsiveness and less lag.
Try these settings:
🔸Smoothing Lengths: Use lower values (e.g. len = 3, len2 = 5)
🔸Candle Mode: Use Custom HA or TV’s HA for real-time color flips
🔸Predictive Close Line: Great for ultra-fast anticipation of color reversals
🔸Line Mode: Use Recent Segments mode to track short bursts of trend
🔸Colors: Use high-contrast, opaque colors for clarity
✅ These settings help you catch micro-trends and flip signals faster, while still filtering out the worst of the noise.
🔹 🧪 Swing Trader (30m–4h charts and beyond)
If you’re looking for multi-hour or multi-day trend confirmation, prioritize clarity and staying in moves longer.
Recommended setup:
🔸Smoothing Lengths: Medium to high values (e.g. len = 8, len2 = 21)
🔸Candle Mode: Use Smoothed HA Candles to block out intrabar chop
🔸Gradient Colors: Enable to visualize trend maturity and strength
🔸Predictive Close Line: Helps confirm trend continuation or spot early reversals
🔸Line Mode: Use Full Plot Line for clean HA-based trend tracking
✅ These settings give you a calm, clean view of the bigger picture — ideal for holding positions longer and avoiding early exits.
🔧 This script isn’t just a chart overlay — it’s a visual trend engine.🔧
Ideal For:
🔶 Trend-followers who want clean, color-coded confirmation
🔶 Reversal traders spotting exhaustion via predictive flips
🔶 Scalpers filtering noise with lighter smoothing
🔶 Swing traders using smoothed visuals to hold longer
📌 Final Note
Heikin Ashi Overlay Pro is designed to help you see momentum, trend shifts, and market structure with greater clarity — not to predict price on its own. For best results:
✔️ Combine with support/resistance, moving averages, or price action patterns
✔️ Use Predictive Close as a confirmation tool, not a signal generator
✔️ Pair gradient colors with structure to gauge trend maturity
✔️ Always zoom out and check higher timeframes for context
🧠 Use this as part of a layered approach — not a standalone system.
🙏 Credits🙏
⚡HA logic based on SimpleCryptoLife
⚡Smoothed HA concept adapted from a script by Jackvmk
💡💡💡Turn logic into clarity. Structure into trades. And uncertainty into confidence.💡💡💡
Bitcoin vs. Gold correlation with lagBTC vs Gold (Lag) + Correlation — multi-timeframe, publication notes
What it does
Plots Gold on the same chart as Bitcoin, with a configurable lead/lag.
Lets you choose how the series is displayed:
Gold shifted forward (+lag on chart) — shows gold ahead of BTC on the time axis (visual offset).
Gold aligned to BTC (gold lag) — standard alignment; gold is lagged for calculation and plotted in place.
BTC 200D Lag (BTC shifted forward) — visualizes BTC shifted forward (like popular “BTC 200D Lag” charts).
Computes Pearson correlations between BTC (no lag) and Gold (with lag) over multiple lookback windows equivalent to:
30d, 60d, 90d, 180d, 365d, 2y (730d), 3y (1095d), 5y (1825d).
Shows a table with the correlation values, automatically scaled to the current timeframe.
Why this is useful
A common macro claim is that BTC tends to follow Gold with a delay (e.g., ~200 trading days). This tool lets you:
Visually advance Gold (or BTC) to see that lead-lag relationship on the chart.
Quantify the relationship with rolling correlations.
Switch timeframes (D/W/M/…): everything automatically stays in sync.
Quick start
Open a BTC chart (any exchange).
Add the indicator.
Set Gold symbol (default TVC:GOLD; alternatives: OANDA:XAUUSD, COMEX:GC1!, etc.).
Choose Lag value and Lag unit (Days/Weeks/Months/Years/Bars).
Pick Visual Mode:
To mirror those “BTC 200D Lag” posts: choose “BTC 200D Lag (BTC shifted forward)” with 200 Days.
To view Gold 200D ahead of BTC: select “Gold shifted forward (+lag on chart)” with 200 Days.
Keep Rebase to 100 ON for an apples-to-apples visual scale. (You can move the study to the left price scale if needed.)
Inputs
Gold symbol: external series to pair with BTC.
Lag value: numeric value.
Lag unit: Days, Weeks, Months (≈30d), Years (≈365d), or direct Bars.
Visual mode:
Gold shifted forward (+lag on chart) → gold is offset to the right by the lag (visual only).
Gold aligned to BTC (gold lag) → standard plot (no visual offset); correlations still use lagged gold.
BTC 200D Lag (BTC shifted forward) → BTC is offset to the right by the lag (visual only).
Rebase to 100 (visual): rescales each series to 100 on its first valid bar for clearer comparison.
Show gold without lag (debug): optional reference line.
Show price tag for gold (lag): toggles the track price label.
Timeframe handling
The study uses the current chart timeframe for both BTC and Gold (timeframe.period).
Lag in time units (Days/Weeks/Months/Years) is internally converted to an integer number of bars of the active timeframe (using timeframe.in_seconds).
Example: on W (weekly), 200 days ≈ 29 bars.
On intraday timeframes, days are converted proportionally.
Correlation math
Correlation = ta.correlation(BTC, Gold_lagged, length_in_bars)
Lookback lengths are the bar-equivalents of 30/60/90/180/365/730/1095/1825 days in the active timeframe.
Important: correlations are computed on prices (not returns). If you prefer returns-based correlation (often more statistically robust), duplicate the script and replace price inputs with change(close) or ta.roc(close, 1).
Reading the table
Window: nominal day label (e.g., 30d, 1y, 5y).
Bars (TF): how many bars that window equals on the current timeframe.
Correlation: Pearson coefficient . Background tint shows intensity and sign.
Tips & caveats
Visual offsets (offset=) move series on screen only; they don’t affect the math. The math always uses BTC (no lag) × Gold (lagged).
With large lags on high timeframes, early bars will be na (normal). Scroll forward / reduce lag.
If your Gold feed doesn’t load, try an alternative symbol that your plan supports.
Rebase to 100 helps visibility when BTC ($100k) and Gold ($2k) share a scale.
Months/Years use 30/365-day approximations. For exact control, use Days or Bars.
Correlations on very short lengths or sparse data can be unstable; consider the longer windows for sturdier signals.
This is a visual/analytical tool, not a trading signal. Always apply independent risk management.
Suggested setups
Replicate “BTC 200D Lag” charts:
Visual Mode: BTC 200D Lag (BTC shifted forward)
Lag: 200 Days
Rebase: ON
Gold leads BTC (Gold ahead):
Visual Mode: Gold shifted forward (+lag on chart)
Lag: 200 Days
Rebase: ON
Compatibility: Pine v6, overlay study.
Best with: BTCUSD (any exchange) + a reliable Gold feed.
Author’s note: Lead-lag relationships are not stable over time; treat correlations as descriptive, not predictive.
Adaptive Trend Following Suite [Alpha Extract]A sophisticated multi-filter trend analysis system that combines advanced noise reduction, adaptive moving averages, and intelligent market structure detection to deliver institutional-grade trend following signals. Utilizing cutting-edge mathematical algorithms and dynamic channel adaptation, this indicator provides crystal-clear directional guidance with real-time confidence scoring and market mode classification for professional trading execution.
🔶 Advanced Noise Reduction
Filter Eliminates market noise using sophisticated Gaussian filtering with configurable sigma values and period optimization. The system applies mathematical weight distribution across price data to ensure clean signal generation while preserving critical trend information, automatically adjusting filter strength based on volatility conditions.
advancedNoiseFilter(sourceData, filterLength, sigmaParam) =>
weightSum = 0.0
valueSum = 0.0
centerPoint = (filterLength - 1) / 2
for index = 0 to filterLength - 1
gaussianWeight = math.exp(-0.5 * math.pow((index - centerPoint) / sigmaParam, 2))
weightSum += gaussianWeight
valueSum += sourceData * gaussianWeight
valueSum / weightSum
🔶 Adaptive Moving Average Core Engine
Features revolutionary volatility-responsive averaging that automatically adjusts smoothing parameters based on real-time market conditions. The engine calculates adaptive power factors using logarithmic scaling and bandwidth optimization, ensuring optimal responsiveness during trending markets while maintaining stability during consolidation phases.
// Calculate adaptive parameters
adaptiveLength = (periodLength - 1) / 2
logFactor = math.max(math.log(math.sqrt(adaptiveLength)) / math.log(2) + 2, 0)
powerFactor = math.max(logFactor - 2, 0.5)
relativeVol = avgVolatility != 0 ? volatilityMeasure / avgVolatility : 0
adaptivePower = math.pow(relativeVol, powerFactor)
bandwidthFactor = math.sqrt(adaptiveLength) * logFactor
🔶 Intelligent Market Structure Analysis
Employs fractal dimension calculations to classify market conditions as trending or ranging with mathematical precision. The system analyzes price path complexity using normalized data arrays and geometric path length calculations, providing quantitative market mode identification with configurable threshold sensitivity.
🔶 Multi-Component Momentum Analysis
Integrates RSI and CCI oscillators with advanced Z-score normalization for statistical significance testing. Each momentum component receives independent analysis with customizable periods and significance levels, creating a robust consensus system that filters false signals while maintaining sensitivity to genuine momentum shifts.
// Z-score momentum analysis
rsiAverage = ta.sma(rsiComponent, zAnalysisPeriod)
rsiDeviation = ta.stdev(rsiComponent, zAnalysisPeriod)
rsiZScore = (rsiComponent - rsiAverage) / rsiDeviation
if math.abs(rsiZScore) > zSignificanceLevel
rsiMomentumSignal := rsiComponent > 50 ? 1 : rsiComponent < 50 ? -1 : rsiMomentumSignal
❓How It Works
🔶 Dynamic Channel Configuration
Calculates adaptive channel boundaries using three distinct methodologies: ATR-based volatility, Standard Deviation, and advanced Gaussian Deviation analysis. The system automatically adjusts channel multipliers based on market structure classification, applying tighter channels during trending conditions and wider boundaries during ranging markets for optimal signal accuracy.
dynamicChannelEngine(baselineData, channelLength, methodType) =>
switch methodType
"ATR" => ta.atr(channelLength)
"Standard Deviation" => ta.stdev(baselineData, channelLength)
"Gaussian Deviation" =>
weightArray = array.new_float()
totalWeight = 0.0
for i = 0 to channelLength - 1
gaussWeight = math.exp(-math.pow((i / channelLength) / 2, 2))
weightedVariance += math.pow(deviation, 2) * array.get(weightArray, i)
math.sqrt(weightedVariance / totalWeight)
🔶 Signal Processing Pipeline
Executes a sophisticated 10-step signal generation process including noise filtering, trend reference calculation, structure analysis, momentum component processing, channel boundary determination, trend direction assessment, consensus calculation, confidence scoring, and final signal generation with quality control validation.
🔶 Confidence Transformation System
Applies sigmoid transformation functions to raw confidence scores, providing 0-1 normalized confidence ratings with configurable threshold controls. The system uses steepness parameters and center point adjustments to fine-tune signal sensitivity while maintaining statistical robustness across different market conditions.
🔶 Enhanced Visual Presentation
Features dynamic color-coded trend lines with adaptive channel fills, enhanced candlestick visualization, and intelligent price-trend relationship mapping. The system provides real-time visual feedback through gradient fills and transparency adjustments that immediately communicate trend strength and direction changes.
🔶 Real-Time Information Dashboard
Displays critical trading metrics including market mode classification (Trending/Ranging), structure complexity values, confidence scores, and current signal status. The dashboard updates in real-time with color-coded indicators and numerical precision for instant market condition assessment.
🔶 Intelligent Alert System
Generates three distinct alert types: Bullish Signal alerts for uptrend confirmations, Bearish Signal alerts for downtrend confirmations, and Mode Change alerts for market structure transitions. Each alert includes detailed messaging and timestamp information for comprehensive trade management integration.
🔶 Performance Optimization
Utilizes efficient array management and conditional processing to maintain smooth operation across all timeframes. The system employs strategic variable caching, optimized loop structures, and intelligent update mechanisms to ensure consistent performance even during high-volatility market conditions.
This indicator delivers institutional-grade trend analysis through sophisticated mathematical modelling and multi-stage signal processing. By combining advanced noise reduction, adaptive averaging, intelligent structure analysis, and robust momentum confirmation with dynamic channel adaptation, it provides traders with unparalleled trend following precision. The comprehensive confidence scoring system and real-time market mode classification make it an essential tool for professional traders seeking consistent, high-probability trend following opportunities with mathematical certainty and visual clarity.
BTC Power Law Valuation BandsBTC Power Law Rainbow
A long-term valuation framework for Bitcoin based on Power Law growth — designed to help identify macro accumulation and distribution zones, aligned with long-term investor behavior.
🔍 What Is a Power Law?
A Power Law is a mathematical relationship where one quantity varies as a power of another. In this model:
Price ≈ a × (Time)^b
It captures the non-linear, exponentially slowing growth of Bitcoin over time. Rather than using linear or cyclical models, this approach aligns with how complex systems, such as networks or monetary adoption curves, often grow — rapidly at first, and then more slowly, but persistently.
🧠 Why Power Law for BTC?
Bitcoin:
Has finite supply and increasing adoption.
Operates as a monetary network , where Metcalfe’s Law and power laws naturally emerge.
Exhibits exponential growth over logarithmic time when viewed on a log-log chart .
This makes it uniquely well-suited for power law modeling.
🌈 How to Use the Valuation Bands
The central white line represents the modeled fair value according to the power law.
Colored bands represent deviations from the model in logarithmic space, acting as macro zones:
🔵 Lower Bands: Deep value / Accumulation zones.
🟡 Mid Bands: Fair value.
🔴 Upper Bands: Euphoria / Risk of macro tops.
📐 Smart Money Concepts (SMC) Alignment
Accumulation: Occurs when price consolidates near lower bands — often aligning with institutional positioning.
Markup: As price re-enters or ascends the bands, we often see breakout behavior and trend expansion.
Distribution: When price extends above upper bands, potential for exit liquidity creation and distribution events.
Reversion: Historically, price mean-reverts toward the model — rarely staying outside the bands for long.
This makes the model useful for:
Cycle timing
Long-term DCA strategy zones
Identifying value dislocations
Filtering short-term noise
⚠️ Disclaimer
This tool is for educational and informational purposes only . It is not financial advice. The power law model is a non-predictive, mathematical framework and does not guarantee future price movements .
Always use additional tools, risk management, and your own judgment before making trading or investment decisions.
Mutanabby_AI | ATR+ | Trend-Following StrategyThis document presents the Mutanabby_AI | ATR+ Pine Script strategy, a systematic approach designed for trend identification and risk-managed position entry in financial markets. The strategy is engineered for long-only positions and integrates volatility-adjusted components to enhance signal robustness and trade management.
Strategic Design and Methodological Basis
The Mutanabby_AI | ATR+ strategy is constructed upon a foundation of established technical analysis principles, with a focus on objective signal generation and realistic trade execution.
Heikin Ashi for Trend Filtering: The core price data is processed via Heikin Ashi (HA) methodology to mitigate transient market noise and accentuate underlying trend direction. The script offers three distinct HA calculation modes, allowing for comparative analysis and validation:
Manual Calculation: Provides a transparent and deterministic computation of HA values.
ticker.heikinashi(): Utilizes TradingView's built-in function, employing confirmed historical bars to prevent repainting artifacts.
Regular Candles: Allows for direct comparison with standard OHLC price action.
This multi-methodological approach to trend smoothing is critical for robust signal generation.
Adaptive ATR Trailing Stop: A key component is the Average True Range (ATR)-based trailing stop. ATR serves as a dynamic measure of market volatility. The strategy incorporates user-defined parameters (
Key Value and ATR Period) to calibrate the sensitivity of this trailing stop, enabling adaptation to varying market volatility regimes. This mechanism is designed to provide a dynamic exit point, preserving capital and locking in gains as a trend progresses.
EMA Crossover for Signal Generation: Entry and exit signals are derived from the interaction between the Heikin Ashi derived price source and an Exponential Moving Average (EMA). A crossover event between these two components is utilized to objectively identify shifts in momentum, signaling potential long entry or exit points.
Rigorous Stop Loss Implementation: A critical feature for risk mitigation, the strategy includes an optional stop loss. This stop loss can be configured as a percentage or fixed point deviation from the entry price. Importantly, stop loss execution is based on real market prices, not the synthetic Heikin Ashi values. This design choice ensures that risk management is grounded in actual market liquidity and price levels, providing a more accurate representation of potential drawdowns during backtesting and live operation.
Backtesting Protocol: The strategy is configured for realistic backtesting, employing fill_orders_on_standard_ohlc=true to simulate order execution at standard OHLC prices. A configurable Date Filter is included to define specific historical periods for performance evaluation.
Data Visualization and Metrics: The script provides on-chart visual overlays for buy/sell signals, the ATR trailing stop, and the stop loss level. An integrated information table displays real-time strategy parameters, current position status, trend direction, and key price levels, facilitating immediate quantitative assessment.
Applicability
The Mutanabby_AI | ATR+ strategy is particularly suited for:
Cryptocurrency Markets: The inherent volatility of assets such as #Bitcoin and #Ethereum makes the ATR-based trailing stop a relevant tool for dynamic risk management.
Systematic Trend Following: Individuals employing systematic methodologies for trend capture will find the objective signal generation and rule-based execution aligned with their approach.
Pine Script Developers and Quants: The transparent code structure and emphasis on realistic backtesting provide a valuable framework for further analysis, modification, and integration into broader quantitative models.
Automated Trading Systems: The clear, deterministic entry and exit conditions facilitate integration into automated trading environments.
Implementation and Evaluation
To evaluate the Mutanabby_AI | ATR+ strategy, apply the script to your chosen chart on TradingView. Adjust the input parameters (Key Value, ATR Period, Heikin Ashi Method, Stop Loss Settings) to observe performance across various asset classes and timeframes. Comprehensive backtesting is recommended to assess the strategy's historical performance characteristics, including profitability, drawdown, and risk-adjusted returns.
I'd love to hear your thoughts, feedback, and any optimizations you discover! Drop a comment below, give it a like if you find it useful, and share your results.
Adaptive MVRV & RSI Strategy V6 (Dynamic Thresholds)Strategy Explanation
This is an advanced Dollar-Cost Averaging (DCA) strategy for Bitcoin that aims to adapt to long-term market cycles and changing volatility. Instead of relying on fixed buy/sell signals, it uses a dynamic, weighted approach based on a combination of on-chain data and classic momentum.
Core Components:
Dual-Indicator Signal: The strategy combines two powerful indicators for a more robust signal:
MVRV Ratio: An on-chain metric to identify when Bitcoin is fundamentally over or undervalued relative to its historical cost basis.
Weekly RSI: A classic momentum indicator to gauge long-term market strength and identify overbought/oversold conditions.
Dynamic, Self-Adjusting Thresholds: The core innovation of this strategy is that it avoids fixed thresholds (e.g., "sell when RSI is 70"). Instead, the buy and sell zones are dynamically calculated based on a long-term (2-year) moving average and standard deviation of each indicator. This allows the strategy to automatically adapt to Bitcoin's decreasing volatility and changing market structure over time.
Weighted DCA (Scaling In & Out): The strategy doesn't just buy or sell a fixed amount. The size of its trades is scaled based on conviction:
Buying: As the MVRV and RSI fall deeper into their "undervalued" zones, the percentage of available cash used for each purchase increases.
Selling: As the indicators rise further into "overvalued" territory, the percentage of the current position sold also increases.
This creates an adaptive system that systematically accumulates during periods of fear and distributes during periods of euphoria, with the intensity of its actions directly tied to the extremity of market conditions.
Pi Cycle Top Indicator - mychaelgoPlots the original Pi Cycle Top moving averages and marks bars where the 111DMA is rising and crosses above the 350DMA×2, often coinciding with Bitcoin cycle peaks. Includes a label with the signal price.
Bitcoin Expectile Model [LuxAlgo]The Bitcoin Expectile Model is a novel approach to forecasting Bitcoin, inspired by the popular Bitcoin Quantile Model by PlanC. By fitting multiple Expectile regressions to the price, we highlight zones of corrections or accumulations throughout the Bitcoin price evolution.
While we strongly recommend using this model with the Bitcoin All Time History Index INDEX:BTCUSD on the 3 days or weekly timeframe using a logarithmic scale, this model can be applied to any asset using the daily timeframe or superior.
Please note that here on TradingView, this model was solely designed to be used on the Bitcoin 1W chart, however, it can be experimented on other assets or timeframes if of interest.
🔶 USAGE
The Bitcoin Expectile Model can be applied similarly to models used for Bitcoin, highlighting lower areas of possible accumulation (support) and higher areas that allow for the anticipation of potential corrections (resistance).
By default, this model fits 7 individual Expectiles Log-Log Regressions to the price, each with their respective expectile ( tau ) values (here multiplied by 100 for the user's convenience). Higher tau values will return a fit closer to the higher highs made by the price of the asset, while lower ones will return fits closer to the lower prices observed over time.
Each zone is color-coded and has a specific interpretation. The green zone is a buy zone for long-term investing, purple is an anomaly zone for market bottoms that over-extend, while red is considered the distribution zone.
The fits can be extrapolated, helping to chart a course for the possible evolution of Bitcoin prices. Users can select the end of the forecast as a date using the "Forecast End" setting.
While the model is made for Bitcoin using a log scale, other assets showing a tendency to have a trend evolving in a single direction can be used. See the chart above on QQQ weekly using a linear scale as an example.
The Start Date can also allow fitting the model more locally, rather than over a large range of prices. This can be useful to identify potential shorter-term support/resistance areas.
🔶 DETAILS
🔹 On Quantile and Expectile Regressions
Quantile and Expectile regressions are similar; both return extremities that can be used to locate and predict prices where tops/bottoms could be more likely to occur.
The main difference lies in what we are trying to minimize, which, for Quantile regression, is commonly known as Quantile loss (or pinball loss), and for Expectile regression, simply Expectile loss.
You may refer to external material to go more in-depth about these loss functions; however, while they are similar and involve weighting specific prices more than others relative to our parameter tau, Quantile regression involves minimizing a weighted mean absolute error, while Expectile regression minimizes a weighted squared error.
The squared error here allows us to compute Expectile regression more easily compared to Quantile regression, using Iteratively reweighted least squares. For Quantile regression, a more elaborate method is needed.
In terms of comparison, Quantile regression is more robust, and easier to interpret, with quantiles being related to specific probabilities involving the underlying cumulative distribution function of the dataset; on the other expectiles are harder to interpret.
🔹 Trimming & Alterations
It is common to observe certain models ignoring very early Bitcoin price ranges. By default, we start our fit at the date 2010-07-16 to align with existing models.
By default, the model uses the number of time units (days, weeks...etc) elapsed since the beginning of history + 1 (to avoid NaN with log) as independent variable, however the Bitcoin All Time History Index INDEX:BTCUSD do not include the genesis block, as such users can correct for this by enabling the "Correct for Genesis block" setting, which will add the amount of missed bars from the Genesis block to the start oh the chart history.
🔶 SETTINGS
Start Date: Starting interval of the dataset used for the fit.
Correct for genesis block: When enabled, offset the X axis by the number of bars between the Bitcoin genesis block time and the chart starting time.
🔹 Expectiles
Toggle: Enable fit for the specified expectile. Disabling one fit will make the script faster to compute.
Expectile: Expectile (tau) value multiplied by 100 used for the fit. Higher values will produce fits that are located near price tops.
🔹 Forecast
Forecast End: Time at which the forecast stops.
🔹 Model Fit
Iterations Number: Number of iterations performed during the reweighted least squares process, with lower values leading to less accurate fits, while higher values will take more time to compute.