Stash-Magic Indicators Guide
Stash-Magic turns a plain-English description into an indicator on your chart, with no code to write. You can draw lines and histograms, mark specific bars, or paint candles green and red, then save your indicators and use them on any chart.
Quick start
- Go to Research → Stash-Magic Indicators and sign in. Building and saving need an account.
- Describe your indicator, for example
RSI minus its 20-day average, or click an example. - Click Create. You'll see a name, a one-sentence summary and the formula.
- Check that it matches what you asked for, because the AI can misread a request. The test chart draws it straight away.
- Click the symbol on the test chart to try it on other tickers.
- Click Save to My Indicators, Add to my charts, or both.
You can also build from the Build Stash-Magic Indicator bar on the Multi-Chart page. Click Create, check the preview, then click Apply. That bar also sets up layouts, such as 4 charts: NVDA AMD AVGO TSM weekly with RSI.
Writing a good request
- Name the indicator and the number:
50 day SMAworks better thanthe average. - A number becomes the period:
RSI 2means a 2-bar RSI. With no number, RSI and ATR use 14 and most others use 20. - Say how you want to see it: mark, flag or highlight for markers, and paint or color the candles for paint bars.
- Use above or below for a condition that lasts, and crosses for the single bar where it happens.
- Keep it to one idea, under 300 characters.
What an indicator can draw
| Type | What you see | Best for |
|---|---|---|
| Line | A line on the candles, or in its own pane | Averages, bands, oscillators, distances |
| Histogram | Bars in their own pane: green at or above zero, red below | Spreads and momentum around zero |
| Marker | A small triangle under each bar where the condition is true | Events such as crosses and volume spikes |
| Paint bars | Candles turn green where the condition is true and red where it is false | Showing which state the market is in |
Crossovers and paint bars: a cross is true for one bar only. So if you ask for paint bars based on a cross, Stash-Magic paints the state after it: crossover(ema(close, 8), ema(close, 21)) becomes ema(close, 8) > ema(close, 21). If you want a mark on the cross itself, ask to mark it.
Paint bars work on candles, bars and Heikin-Ashi, but not on line or area charts. If several paint indicators are on, the most recently added one wins.
Examples
| You type | Formula | You see |
|---|---|---|
| RSI minus its 20-day average | rsi(close, 14) - sma(rsi(close, 14), 20) | Green and red bars in their own pane |
| Distance from the 20 day average measured in ATRs | (close - sma(close, 20)) / atr(14) | A line in its own pane |
| Percent above the 200 day | (close / sma(close, 200) - 1) * 100 | A line in its own pane |
| 20 day high on the chart | highest(high, 20) | A line on the candles |
| Upper Bollinger band | sma(close, 20) + 2 * stdev(close, 20) | A line on the candles |
| Mark days with volume over twice normal | volume > 2 * sma(volume, 20) | A triangle under each matching bar |
| Mark the day the 8 EMA crosses above the 21 EMA | crossover(ema(close, 8), ema(close, 21)) | A triangle on each cross |
| Mark inside days | high < lag(high, 1) and low > lag(low, 1) | A triangle under each inside day |
| Paint bars green when the 8 EMA is above the 21 EMA and red when below | ema(close, 8) > ema(close, 21) | Candles recolored green and red |
| Color the candles by whether RSI is above 50 | rsi(close, 14) > 50 | Candles recolored green and red |
The AI may word a formula differently from these. What matters is that it calculates what you asked for.
My Indicators
- Saving: click Save to My Indicators on the Stash-Magic page. Anything you Apply from the Multi-Chart bar while signed in is saved too.
- Everywhere you sign in: saved indicators stay with your account, across devices.
- No limit: save as many as you want.
- Reusing: open the Stash-Magic Indicator button on the chart toolbar and pick one. Reusing a saved indicator doesn't count as a new build.
- Editing: click Test, change the formula, and save. This creates a new entry and keeps the old one, so delete the old one if you don't need it.
- Deleting: click Delete, then Confirm. This can't be undone.
Using indicators on charts
- Add as many as you like: use Stash-Magic Indicator for your own, and + Add indicator for built-in ones such as RSI and MACD. Each one that needs a pane gets its own.
- Remove one: click the × next to its name on the chart. Indicators drawn on the candles are listed at the top left, under the price readout.
- Applies to the layout: indicators show on every chart in the layout, so × removes one from all of them.
- Follows the timeframe: a formula uses whichever bars the chart shows.
sma(close, 20)is 20 days on a daily chart and 20 weeks on a weekly chart. - Blank at the start: an indicator stays blank until there are enough bars to calculate it, so a 200-bar average begins 200 bars in.
- Sharing: the Share link on the chart page includes the indicators on those charts.
Resizing and zooming
| To do this | Do this |
|---|---|
| Make charts taller | Drag the grip on a chart’s bottom edge. Double-click it to return to automatic. Charts also grow on their own as you add panes |
| Resize one indicator, or the candle area | Drag the line between two panes. Double-click it to reset |
| Fill the screen | Click the expand icon on a chart, or Fullscreen in the toolbar |
| Zoom in or out | Use the zoom icons on the chart, drag the date axis, or pinch. Turn on Wheel zoom to use the mouse wheel |
| See everything again | Double-click the chart |
Sizes are saved with your layout and apply to all of its charts. The height grip isn't available in mixed-size layouts.
Formula reference
You never have to write a formula, but you can edit one on the Stash-Magic page. The chart redraws as soon as the formula is valid.
Series: open high low close volume
Math: + - * / and parentheses.
Conditions: > < >= <= and or not. There is no ==.
| Function | Meaning |
|---|---|
sma(series, N) | Simple moving average of the last N bars |
ema(series, N) | Exponential moving average |
rsi(series, N) | Relative Strength Index, using Wilder smoothing |
atr(N) | Average True Range. It takes only N |
roc(series, N) | Percent change over N bars. It is already a percent, so don’t multiply by 100 |
stdev(series, N) | Standard deviation of the last N bars |
highest(series, N) | Highest value of the last N bars, including this one |
lowest(series, N) | Lowest value of the last N bars, including this one |
sum(series, N) | Total of the last N bars |
lag(series, N) | The value N bars ago |
macd(series, fast, slow) | MACD line, for example macd(close, 12, 26) |
macd_signal(series, fast, slow, signal) | MACD signal line, for example macd_signal(close, 12, 26, 9) |
abs(series) | Absolute value |
min(a, b) | The smaller of two values on each bar |
max(a, b) | The larger of two values on each bar |
crossover(a, b) | True only on the bar where a moves above b |
crossunder(a, b) | True only on the bar where a moves below b |
barssince(condition) | How many bars since the condition was last true |
- Periods are whole numbers from 1 to 500, and functions can be nested:
sma(rsi(close, 14), 20). - Because
highestincludes the current bar, a breakout above the prior 20 bars isclose > lag(highest(high, 20), 1). - Formulas can only look backward. They can't read future bars.
- Lines and histograms need a number. Markers and paint bars need a condition.
What it can't do
Stash-Magic only sees the price and volume of the chart you're on. When a request needs something else, it should say so instead of guessing. It can't use:
- Other symbols or indexes, including relative strength against SPY. For that, use the built-in vs SPY indicators in + Add indicator
- Earnings, fundamentals, news, sentiment, or options and gamma data
- Minute or hourly bars. Charts use daily and longer bars, based on end-of-day data
- Loops or multi-step logic
- Trade signals with stops, targets or position sizing
- Predictions of future prices
Indicators also can't yet be used in alerts or scans, you can only paint in green and red, and you can't rename a saved indicator.
If you see a message
| Message | What it means |
|---|---|
| Too many requests. Please wait a minute and try again. | You sent more than 5 build requests in a minute. Wait a minute and try again. |
| Custom indicators are paused for today. Please try again tomorrow. | New indicators have reached a site-wide usage limit. Your saved indicators keep working. |
| Couldn’t turn that into a chart. Try wording it differently. | The AI’s answer didn’t pass validation. Name the indicator and period more directly. |
| Sign in again to use AI layouts. | Your login expired. Sign in and try again. |
| The AI service didn’t answer. Please try again. | A temporary connection problem. Try again. |
If an indicator looks wrong, read its formula first. The AI sometimes picks a different period or average than you meant. Rewording usually fixes it, or you can edit the formula directly. Still stuck? Contact support.
FAQ
Do I need to know how to code?
No. Describe what you want in plain English. The formula is there if you want to check or edit it, but you never have to write one.
Is this Pine Script?
No. Stash-Magic uses its own small formula language, and Pine scripts can’t be pasted in. It has no loops, strategies or backtests, which keeps it simple but means it can’t do everything Pine can.
How many indicators can I use?
There is no limit on how many you save or add to a chart. A long stack of panes makes each one thinner, so make the chart taller or remove some if they get hard to read.
Are my indicators private?
Saved indicators belong to your account and aren’t published. If you use Share on the chart page, the link includes the indicators on those charts, so anyone with the link can see their formulas.
Do these indicators predict the market or tell me what to trade?
No. An indicator is a calculation on past prices and volume. These haven’t been backtested, and they aren’t trading advice.
Can I get an alert when an indicator fires?
Not yet. Indicators are drawn on charts only, and can’t be used in alerts or the AI Stock Scan Builder.