OPEN-SOURCE SCRIPT
Buy Zone Planner [Rider Algo]

Buy Zone Planner turns "I like this asset, but at what price should I buy it?" into a plan. It draws three buy zones under the price, shows the chance that price gets down to each one within the time you can wait, and shows how buying in each zone worked on this same chart before. Think of it as the price history of a product you want: it tells you when this asset has been on sale, how deep the sale usually goes, and how often it comes.
═══════════════════════════════════════════════════════════════════════════
HOW IT WORKS
"Cheap" is never a fixed percentage here. Every asset is measured against its own history:
- Distance from its 4-year average. The indicator compares price with its 200-week average and ranks that distance against the last 8 years (416 weeks) of the same chart.
- Three zones from that ranking. Zone 1 - Good price starts where price was this cheap only 30% of the time. Zone 2 - Great price starts at 15%. Zone 3 - Rare price starts at 5% and ends at 1% (below that, it still counts as Zone 3).
- Short histories. While a chart has less than about 6 years of weekly data, the 104-week average is used, and the zones move to the 4-year average gradually over a year, so they do not jump.
- Chance to get there. For stocks, ETFs, commodities and forex: how often price fell that far within the chosen time in this chart's own history, measured in units of its weekly volatility. For crypto: a volatility (random-walk) model built from the last 52 weeks, which was the more accurate of the two on crypto when the rules were tested.
- Track record. Every week the price traded in a zone counts as a buy at the zone's price, and it is judged 52 weeks later.
The rules were tested on stocks, ETFs, crypto, gold, silver and forex before publishing. Results differ by asset, and that is exactly why every chart shows its own record instead of a promise.
═══════════════════════════════════════════════════════════════════════════
WHAT YOU SEE ON THE CHART
The three zones
They are drawn on past candles, so you can see how price behaved inside them before, and as clouds to the right of the last candle. Each cloud has a label with the price range and three facts in the same order:
- Distance: how far the zone starts from the current price (a distance, not a chance).
- Chance in 6 months: the chance that price gets down to the top of the zone within the time you chose.
- If bought: up 1y: how many of the weeks bought in that zone were higher one year later.
A deeper zone means a better price and a lower chance. Zone 3 may show a low chance and a strong record at the same time: it rarely happens, but when it did, it was usually a good buy.
YOU ARE HERE
When the price is already inside a zone, that zone lights up and its label says so. The zone you are in is the one to watch first.
The table
- Price - distance, Chance in 6 months and If bought: up 1y for each zone.
- A verdict per zone, judged on this chart only: RELIABLE (60%+ of the weeks bought were higher a year later), MIXED (45%+), NOT RELIABLE (below 45%) or NOT ENOUGH DATA (fewer than 3 separate visits to the zone).
- Now: where the price is and what a planner would consider. If the current zone has a weak record on this chart, it shows Caution: weak past. This matters most for assets in a long decline, where buying the dips did not work. If Zone 1 has less than a 10% chance within your waiting time, it shows Expensive now: the asset is far above its zones today. The zones may still be good when they come; they are just far away, and the zones rise with time if price holds.
- Plan: split your budget between the zones (50/30/20 by default) and the table shows how much of it is likely to be invested within your waiting time, and how much is likely to stay in cash. It makes the cost of waiting for a better price visible before you place the orders.
═══════════════════════════════════════════════════════════════════════════
HOW TO USE IT
1. Open the 1W or 1D chart of the asset you want to own and choose how long you can wait in Settings (3 months, 6 months or 1 year).
2. Check the Now row and the verdict column first. Expensive now means the asset is far above its zones today. RELIABLE means buying in these zones worked on this asset before; NOT RELIABLE means it did not, and smaller steps or more patience may be worth considering.
3. Plan your orders in steps at the top of each zone, set your budget split, and read the Plan row to see how much is likely to be invested and how much may stay in cash.
4. Review the orders once a week: the zones move on the weekly close. Use the alerts to know when price reaches a zone.
═══════════════════════════════════════════════════════════════════════════
INPUTS
1 - Plan
- I can wait up to: 3 months, 6 months (default) or 1 year. All chances on the chart and in the table use this time.
- Chance model: Auto (default: crypto uses the volatility model, everything else uses the chart's own history), This chart's history, or Volatility only.
- Budget split (%): how you would split your money between Zone 1, 2 and 3 (default 50/30/20). It does not need to add up to 100.
2 - Chart
- Show zones on past candles: the zones as they were each week.
- Show zones ahead with prices and chances: the clouds and labels to the right of the last candle.
- Show the 4-year average: the average the zones are measured against (off by default).
- Zone colors: one color per zone.
3 - Table
- Show table, Position and Size.
- Visits needed for a verdict: separate visits a zone needs before it gets a verdict (default 3).
- RELIABLE from and MIXED from: the cut-offs of the verdict (default 60% and 45%).
═══════════════════════════════════════════════════════════════════════════
BUILT-IN ALERTS
- Price reached Zone 1, Zone 2 or Zone 3: the price touched the top of that zone.
- Price reached a buy zone: any of the three.
═══════════════════════════════════════════════════════════════════════════
TECHNICAL NOTES
- Non-repainting. Zones, chances and the record are calculated from closed weekly candles. They stay fixed during the week and show the same values on 1D and 1W.
- History needed. About 4 years of weekly candles for the first zones (2-year average plus 2 years to rank it), and about 6 years for the full 4-year average. A 1D chart may load less history than a 1W chart.
- Visits. A visit starts when price enters a zone and ends when a week closes back at the asset's normal level (the middle of its 8-year ranking). Weeks inside one visit move together, which is why the verdict counts visits.
- Chances are measured from the last weekly close to the top of each zone, as if the order were placed today and left in place.
- Timeframes. Designed for 1D and 1W. On intraday or monthly charts the table shows a warning.
- Pine Script v6.
═══════════════════════════════════════════════════════════════════════════
PART OF THE RIDER ALGO ECOSYSTEM
- Use with Macro BTC - for Holders [Rider Algo] or Macro ADA - for Holders [Rider Algo] to add take-profit steps at the top of the cycle to the buying plan.
- Use with Probability Clouds + Entry Level [Rider Algo] on 1D to time the exact limit order once price is close to a zone.
- Use with Strategy #2 [Rider Algo] to wait for a confirmed bounce inside a zone instead of buying the first touch.
- Use with Rider Algo #4: Oscillators to see whether momentum is still falling when price enters a zone.
═══════════════════════════════════════════════════════════════════════════
DISCLAIMER
This indicator is a technical analysis tool designed to help plan long-term purchases by showing price zones, the historical chance of reaching them, and how buying in them worked on the same chart. It does NOT provide buy or sell signals, and it does NOT constitute financial, investment, or trading advice of any kind. Past performance does not guarantee future market behavior. Always conduct your own analysis and consult with a qualified financial advisor before making any trading decisions. Use this tool at your own risk. The author is not responsible for any financial losses incurred from the use of this indicator.
═══════════════════════════════════════════════════════════════════════════
HOW IT WORKS
"Cheap" is never a fixed percentage here. Every asset is measured against its own history:
- Distance from its 4-year average. The indicator compares price with its 200-week average and ranks that distance against the last 8 years (416 weeks) of the same chart.
- Three zones from that ranking. Zone 1 - Good price starts where price was this cheap only 30% of the time. Zone 2 - Great price starts at 15%. Zone 3 - Rare price starts at 5% and ends at 1% (below that, it still counts as Zone 3).
- Short histories. While a chart has less than about 6 years of weekly data, the 104-week average is used, and the zones move to the 4-year average gradually over a year, so they do not jump.
- Chance to get there. For stocks, ETFs, commodities and forex: how often price fell that far within the chosen time in this chart's own history, measured in units of its weekly volatility. For crypto: a volatility (random-walk) model built from the last 52 weeks, which was the more accurate of the two on crypto when the rules were tested.
- Track record. Every week the price traded in a zone counts as a buy at the zone's price, and it is judged 52 weeks later.
The rules were tested on stocks, ETFs, crypto, gold, silver and forex before publishing. Results differ by asset, and that is exactly why every chart shows its own record instead of a promise.
═══════════════════════════════════════════════════════════════════════════
WHAT YOU SEE ON THE CHART
The three zones
They are drawn on past candles, so you can see how price behaved inside them before, and as clouds to the right of the last candle. Each cloud has a label with the price range and three facts in the same order:
- Distance: how far the zone starts from the current price (a distance, not a chance).
- Chance in 6 months: the chance that price gets down to the top of the zone within the time you chose.
- If bought: up 1y: how many of the weeks bought in that zone were higher one year later.
A deeper zone means a better price and a lower chance. Zone 3 may show a low chance and a strong record at the same time: it rarely happens, but when it did, it was usually a good buy.
YOU ARE HERE
When the price is already inside a zone, that zone lights up and its label says so. The zone you are in is the one to watch first.
The table
- Price - distance, Chance in 6 months and If bought: up 1y for each zone.
- A verdict per zone, judged on this chart only: RELIABLE (60%+ of the weeks bought were higher a year later), MIXED (45%+), NOT RELIABLE (below 45%) or NOT ENOUGH DATA (fewer than 3 separate visits to the zone).
- Now: where the price is and what a planner would consider. If the current zone has a weak record on this chart, it shows Caution: weak past. This matters most for assets in a long decline, where buying the dips did not work. If Zone 1 has less than a 10% chance within your waiting time, it shows Expensive now: the asset is far above its zones today. The zones may still be good when they come; they are just far away, and the zones rise with time if price holds.
- Plan: split your budget between the zones (50/30/20 by default) and the table shows how much of it is likely to be invested within your waiting time, and how much is likely to stay in cash. It makes the cost of waiting for a better price visible before you place the orders.
═══════════════════════════════════════════════════════════════════════════
HOW TO USE IT
1. Open the 1W or 1D chart of the asset you want to own and choose how long you can wait in Settings (3 months, 6 months or 1 year).
2. Check the Now row and the verdict column first. Expensive now means the asset is far above its zones today. RELIABLE means buying in these zones worked on this asset before; NOT RELIABLE means it did not, and smaller steps or more patience may be worth considering.
3. Plan your orders in steps at the top of each zone, set your budget split, and read the Plan row to see how much is likely to be invested and how much may stay in cash.
4. Review the orders once a week: the zones move on the weekly close. Use the alerts to know when price reaches a zone.
═══════════════════════════════════════════════════════════════════════════
INPUTS
1 - Plan
- I can wait up to: 3 months, 6 months (default) or 1 year. All chances on the chart and in the table use this time.
- Chance model: Auto (default: crypto uses the volatility model, everything else uses the chart's own history), This chart's history, or Volatility only.
- Budget split (%): how you would split your money between Zone 1, 2 and 3 (default 50/30/20). It does not need to add up to 100.
2 - Chart
- Show zones on past candles: the zones as they were each week.
- Show zones ahead with prices and chances: the clouds and labels to the right of the last candle.
- Show the 4-year average: the average the zones are measured against (off by default).
- Zone colors: one color per zone.
3 - Table
- Show table, Position and Size.
- Visits needed for a verdict: separate visits a zone needs before it gets a verdict (default 3).
- RELIABLE from and MIXED from: the cut-offs of the verdict (default 60% and 45%).
═══════════════════════════════════════════════════════════════════════════
BUILT-IN ALERTS
- Price reached Zone 1, Zone 2 or Zone 3: the price touched the top of that zone.
- Price reached a buy zone: any of the three.
═══════════════════════════════════════════════════════════════════════════
TECHNICAL NOTES
- Non-repainting. Zones, chances and the record are calculated from closed weekly candles. They stay fixed during the week and show the same values on 1D and 1W.
- History needed. About 4 years of weekly candles for the first zones (2-year average plus 2 years to rank it), and about 6 years for the full 4-year average. A 1D chart may load less history than a 1W chart.
- Visits. A visit starts when price enters a zone and ends when a week closes back at the asset's normal level (the middle of its 8-year ranking). Weeks inside one visit move together, which is why the verdict counts visits.
- Chances are measured from the last weekly close to the top of each zone, as if the order were placed today and left in place.
- Timeframes. Designed for 1D and 1W. On intraday or monthly charts the table shows a warning.
- Pine Script v6.
═══════════════════════════════════════════════════════════════════════════
PART OF THE RIDER ALGO ECOSYSTEM
- Use with Macro BTC - for Holders [Rider Algo] or Macro ADA - for Holders [Rider Algo] to add take-profit steps at the top of the cycle to the buying plan.
- Use with Probability Clouds + Entry Level [Rider Algo] on 1D to time the exact limit order once price is close to a zone.
- Use with Strategy #2 [Rider Algo] to wait for a confirmed bounce inside a zone instead of buying the first touch.
- Use with Rider Algo #4: Oscillators to see whether momentum is still falling when price enters a zone.
═══════════════════════════════════════════════════════════════════════════
DISCLAIMER
This indicator is a technical analysis tool designed to help plan long-term purchases by showing price zones, the historical chance of reaching them, and how buying in them worked on the same chart. It does NOT provide buy or sell signals, and it does NOT constitute financial, investment, or trading advice of any kind. Past performance does not guarantee future market behavior. Always conduct your own analysis and consult with a qualified financial advisor before making any trading decisions. Use this tool at your own risk. The author is not responsible for any financial losses incurred from the use of this indicator.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
Trend first. No fear, no FOMO: just a plan and execution.
— Trend Rider, creator of Rider Algo indicators (Scripts tab on my profile)
Not financial advice.
— Trend Rider, creator of Rider Algo indicators (Scripts tab on my profile)
Not financial advice.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
Trend first. No fear, no FOMO: just a plan and execution.
— Trend Rider, creator of Rider Algo indicators (Scripts tab on my profile)
Not financial advice.
— Trend Rider, creator of Rider Algo indicators (Scripts tab on my profile)
Not financial advice.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.