OPEN-SOURCE SCRIPT

VIKING + AXE & SHIELD

262
## VIKING + AXE & SHIELD — What This Indicator Does

**VIKING + AXE & SHIELD was built so you only need one TradingView indicator on your chart.**

Instead of stacking separate indicators for moving averages, RSI, Accumulation/Distribution, OBV, CMF, ADX, relative volume, relative strength, support/resistance and other context, this script combines them into **one overlay indicator and one compact information panel**. The goal is to keep the chart clean while still showing trend, momentum, volume, money flow, relative strength and important price levels in one place.

The indicator automatically works from the **timeframe you are currently viewing**. For example, if the chart is on 1H, the RSI and A/D calculations are based on hourly bars. On Daily, they use daily bars. On Weekly, they use weekly bars.

### Moving averages

VIKING plots four commonly used trend averages directly on the price chart:

* **9 EMA**
* **21 EMA**
* **50 SMA**
* **200 SMA**

The 9 and 21 EMAs are intended to show shorter-term trend and momentum, while the 50 and 200 SMAs provide broader trend structure. Their current prices are also printed beside the averages so you can immediately see where they are without moving the cursor over them.

Internally, the script also examines the relationship between these moving averages and price. It can recognize conditions such as bullish or bearish MA stacking, price reclaiming or losing moving averages, golden/death-cross conditions, and developing trend structures. Those calculations are kept in the script even though they are not all printed in the VIKING panel.

### AXE & SHIELD support and resistance

AXE & SHIELD is the support/resistance part of the system.

Rather than simply drawing every recent high and low, it detects pivot-based price zones and tracks how those zones behave after they are created. Zone width is adjusted using ATR, and nearby pivots can be merged into the same area rather than creating a cluttered chart full of almost-identical levels.

The script evaluates support and resistance using several ideas, including:

* how well price closes relative to the zone,
* how deeply price penetrates it,
* how strongly price reacts away from it,
* how many times the zone has already been tested,
* and whether the zone has actually broken.

This creates an internal **zone survival score** rather than assuming every support or resistance level has equal strength. The score itself is intentionally kept internal so the chart remains simple.

Support levels are shown in the selected support color and resistance in the selected resistance color. Provisional/unconfirmed levels can be shown with a dotted appearance, and the script can mark zones that have been swept.

The nearest support and nearest resistance are also exported to TradingView's data window/status line if enabled.

---

# The VIKING information panel

The panel condenses several indicators into a small area instead of requiring separate lower chart panes. It includes:

**ADX / 52W High**
**P-RVOL / RS**
**OBV / ADR%**
**CMF / Average Volume**
**RSI full readout**
**A/D Pressure full readout**

The panel position and text size are adjustable. Strong, caution and weak/broken conditions are color coded so the information can be scanned quickly.

## ADX — trend strength

ADX answers a simple question:

**How strong is the current trend?**

The script uses a 14-period DMI/ADX calculation.

* Above **25** = Strong
* Below **20** = Choppy
* Between 20 and 25 = Building

It also compares ADX with three bars ago and adds arrows to show whether trend strength is increasing or decreasing.

Example:

`ADX 30.6 Strong ↑`

means a relatively strong trend whose strength is still increasing.

Important: **ADX does not tell you whether the trend is bullish or bearish.** It measures the strength of the trend.

## 52W Hi — distance from the 52-week high

The panel calculates the highest price over approximately 252 bars and shows how far the current price is from that high as a percentage.

Example:

`52W Hi -8.2%`

means price is currently about 8.2% below its 52-week high.

This provides quick context about whether a stock is trading near leadership territory or well below previous highs.

## P-RVOL — projected relative volume

P-RVOL is more sophisticated than simply comparing today's volume with yesterday's volume.

The script builds a historical intraday volume curve using previous sessions. By default, it uses:

* the previous **20 sessions**,
* a **15-minute calculation timeframe**,
* and regular NYSE hours of **9:30 AM–4:00 PM New York time**.

It looks at how much volume normally occurs by the current point in the trading session and projects what the full day's volume may look like.

Example:

`P-RVOL 1.50x`

roughly means the current trading pace is projecting toward about **1.5 times normal session volume**.

The arrows show whether projected relative volume itself is increasing or decreasing.

This makes P-RVOL especially useful early in the trading day because you do not have to wait until the closing bell to know whether participation appears unusually strong.

## RS — relative strength

The RS rating measures the stock's performance relative to the S&P 500.

The calculation gives more weight to recent performance while also considering longer periods, using approximately:

* 63 trading days,
* 126 days,
* 189 days,
* 252 days.

The stock's performance is compared against SPX over those same periods.

The result is converted into an RS-style rating, and an arrow indicates whether relative strength is improving or deteriorating.

Example:

`RS 83 ↑`

means the stock is showing relatively strong performance and its relative-strength trend is improving.

## OBV — buying and selling pressure

On-Balance Volume looks at volume together with whether price closed higher or lower.

VIKING does not clutter the panel with OBV's huge raw cumulative number. Instead it examines the **five-bar change** and converts it into an easy description:

* Strong Buying ↑
* Buying ↑
* Strong Selling ↓
* Selling ↓
* Neutral →

That gives the useful information from OBV without needing an OBV pane.

## ADR% — average daily range

ADR% shows the stock's average trading range as a percentage over the previous 20 bars.

Higher ADR stocks generally make larger percentage moves, while lower ADR stocks generally move less.

For example:

`ADR% 4.94%`

means the stock has recently been moving through an average daily range of roughly 4.94%.

This gives a fast way to judge how volatile or active a stock normally is.

## CMF — Chaikin Money Flow

CMF measures where price closes within each candle's range and weights that behavior by volume over 20 periods.

Positive CMF generally indicates buying pressure, while negative CMF indicates selling pressure.

VIKING calculates both the current CMF value and its recent direction.

A reading such as:

`CMF +0.20`

suggests positive money flow.

A negative reading suggests the opposite.

## Average Volume and liquidity label

VIKING calculates average volume over 50 bars and adds a simple liquidity classification:

* **Liquid** = average volume above 500,000
* **Thin** = above 100,000
* **Avoid** = below 100,000

This is meant as a quick screening aid, not a universal definition of liquidity.

---

# RSI without needing an RSI pane

One of the main purposes of VIKING is to provide enough numerical information about RSI that a separate RSI pane is unnecessary.

The readout looks like:

`RSI 37.2 | Δ5 +1.9 | Dist -1.9 | Acc3 +9.3`

It contains four pieces of information.

### RSI

The first number is standard **RSI(14)**.

The script also calculates a **14-period SMA of RSI** as its baseline.

A simplified way to think about the current reading:

* above 60 = stronger momentum
* 40–60 = middle/transition area
* below 40 = weaker momentum

These same thresholds control the panel's RSI color.

### Δ5

`Δ5` means:

**How much has RSI changed over the previous five bars?**

Example:

`Δ5 +7.0`

means RSI is seven points higher than five candles ago.

`Δ5 -7.0`

means RSI is seven points lower.

Because it is based on bars, the meaning automatically changes with your chart:

* 1H chart = five hours
* Daily chart = five trading days
* Weekly chart = five weeks

This makes the same indicator useful across multiple timeframes.

### Dist

`Dist` is the distance between current RSI and its 14-period RSI moving-average baseline.

Example:

`RSI 55 | Dist +7`

means RSI is seven points above its recent baseline.

`RSI 55 | Dist -4`

means RSI may still be above 50, but it is actually below its recent RSI trend.

That distinction helps identify whether momentum is strengthening or weakening instead of relying only on the absolute RSI number.

### Acc3

`Acc3` measures **three-bar acceleration**.

The script compares RSI's move over the latest three bars with its move over the previous three bars.

This is useful because a single bad candle does not automatically destroy an otherwise improving momentum trend.

For example:

`RSI 42 | Δ5 +5 | Dist +3 | Acc3 +7`

can be read as:

RSI is still relatively low, but it has improved over five bars, moved above its recent baseline, and the recent three-bar move is stronger than the three bars before it.

So rather than simply knowing **where RSI is**, VIKING also tells you:

**where it came from, where it sits relative to its trend, and whether that movement is gaining or losing strength.**

---

# A/D Pressure without needing an Accumulation/Distribution pane

Standard Accumulation/Distribution is cumulative. Raw values can become extremely large and are difficult to compare between different stocks.

VIKING therefore converts A/D into a normalized **A/D Pressure** reading instead of displaying the raw cumulative number.

It examines the change in A/D over 20 bars and divides that change by the total volume over the same period. The result is converted to a scale capped between approximately **-100 and +100**.

The readout looks like:

`A/D -11 | Δ5 -5 | Dist -9 | Acc3 +6`

### A/D

The first number is the current normalized pressure.

Broadly:

* positive = accumulation pressure
* negative = distribution pressure
* near zero = relatively balanced

The panel colors stronger positive readings at +20 or higher and stronger negative readings at -20 or lower.

### A/D Δ5

This tells you how much normalized A/D pressure has changed over five bars.

`Δ5 +10`

means accumulation/distribution behavior has improved by 10 points over five candles.

`Δ5 -10`

means it has deteriorated.

### A/D Dist

A/D Pressure has its own **20-period moving-average baseline**.

`Dist` tells you how far current pressure is above or below that normal path.

Positive Dist means current A/D pressure is stronger than its recent baseline.

Negative Dist means it is weaker.

### A/D Acc3

Acc3 uses the same concept as RSI.

It compares the change in A/D Pressure during the latest three bars with the previous three bars.

This creates some very useful combinations.

For example:

`A/D -11 | Δ5 -5 | Dist -9 | Acc3 +6`

means:

**A/D is still negative, it is still worse than five bars ago, and it remains below its baseline — but the most recent three-bar behavior is improving.**

In other words:

**The condition is still weak, but it may be starting to turn.**

That is much more informative than simply displaying a raw A/D value.

---

# Stage and long-term trend context

The script also contains daily calculations involving the **200-day and 220-day moving averages**.

It checks whether price is moving above the 200-day average while the long-term average is flat or improving, including cases where price gaps completely above the prior 200-day average.

These calculations are designed to provide longer-term stage/trend context directly on the chart rather than adding another separate study.

---

# How to read the indicator as a whole

VIKING is not intended to make a trading decision from one number.

Its purpose is to let several independent pieces of evidence confirm or disagree with each other.

For example, a strong setup might show something like:

```text
ADX 31 Strong ↑
P-RVOL 1.45x ↑
OBV Strong Buying ↑
CMF +0.18
RS 82 ↑
52W Hi -4.2%
RSI 58.4 | Δ5 +7.2 | Dist +5.1 | Acc3 +4.0
A/D +28 | Δ5 +12 | Dist +9 | Acc3 +7
```

That would tell you:

**Trend strength is increasing, volume participation is elevated, OBV and CMF show buying pressure, the stock is relatively strong, it is close to its 52-week high, momentum is improving, and accumulation pressure is strengthening.**

The opposite combination would warn that multiple parts of the market structure are deteriorating.

The important idea is that **no individual reading needs to be treated as a buy or sell signal. VIKING is a compact market-context system.**

## Why it was built

Most TradingView layouts become crowded when you add:

RSI + A/D + OBV + CMF + ADX + relative volume + moving averages + support/resistance + relative strength.

VIKING + AXE & SHIELD is designed to replace that stack with **one indicator**.

Price stays as the main focus.

The moving averages and important support/resistance levels stay directly on the chart, while indicators that would normally require separate panes are converted into compact numerical or descriptive readings in the VIKING panel.

That gives you more chart space while still preserving information about:

**trend, momentum, participation, accumulation/distribution, money flow, volatility, relative strength and market structure.**

That is the core purpose of the script.

Haftungsausschluss

Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.