Compare A/B
Esta página aún no está disponible en tu idioma.
- A
- B
Volume above avg volume 20 × 1.8
- true/false
Compares two values, e.g. price and EMA. Compares two values on every candle, such as the price (A) with a moving average (B). The factor multiplies B by a number. Example: volume (A) above average (B) with factor 1.8 is true when the volume is more than 1.8 times its average.
What it looks like
Section titled “What it looks like”- A: Price
- B: EMA 20
- true as long as
- true on exactly one candle
Setting it in the chart
Section titled “Setting it in the chart”
In the properties, a chart shows the last 150 candles of A with line B and the area up to B × factor. Next to the factor you see the distance in percent, such as “+2%” for 1.02, and the sentence on the board reads the same way. Drag the edge of the area or move it in small steps with the arrow keys; dots mark where the condition would be met.
More under Chart above the price.
Settings
Section titled “Settings”The settings appear on the right under “Properties” once you click the node on the board. Below each field you find the same explanation as here.
Condition
Section titled “Condition”When the comparison is true. “above” and “below” hold as long as A stays there. “crosses” only holds on the one candle where A breaks through B.
- above (default): True while A is greater than B.
- below: True while A is less than B.
- at least: Like “above”, but also true when A exactly reaches line B.
- at most: Like “below”, but also true when A exactly reaches line B.
- crosses above: Only true on the candle where A rises from below to above B.
- crosses below: Only true on the candle where A falls from above to below B.
- crosses: Only true on the candle where A crosses line B in either direction.
Factor for B
Section titled “Factor for B”B is multiplied by this number before comparing. 1 leaves B unchanged. 1.02 puts B 2% higher, 0.98 puts it 2% lower, 2 doubles it. In the chart above you drag the area above or below B and see the distance in percent.
Example
Section titled “Example”Compares two values and notifies you when the volume is above 1.8 times its average.
How to connect the nodes:
- Candle (Volume) → Volume (Volume)
- Candle (Volume) → Compare A/B (A)
- Volume (Average) → Compare A/B (B)
- Compare A/B (true/false) → Telegram (Trigger)
On the board it reads: Volume above avg volume 20 × 1.8
Chain as JSON
To try it, copy it and paste it in the editor under “Import”. Importing creates a new chain.
{ "name": "Example: Compare A/B", "version": 1, "nodes": [ { "id": "c1", "type": "core.candle", "position": { "x": 40, "y": 40 }, "settings": { "pair": "SOL/USDT", "timeframe": "1h" } }, { "id": "v1", "type": "core.volume", "position": { "x": 260, "y": 40 }, "settings": {} }, { "id": "k1", "type": "core.compare-ab", "position": { "x": 480, "y": 40 }, "settings": { "operator": "above", "factor": 1.8 } }, { "id": "t1", "type": "core.telegram", "position": { "x": 700, "y": 40 }, "settings": {} } ], "edges": [ { "from": "c1.volume", "to": "v1.in" }, { "from": "c1.volume", "to": "k1.a" }, { "from": "v1.average", "to": "k1.b" }, { "from": "k1.out", "to": "t1.in" } ]}Inputs and outputs
Section titled “Inputs and outputs”Only matching types connect: number series to number series (round pin), signal to signal (square), message to message (diamond).
| Direction | Pin | Type | Note |
|---|---|---|---|
| Input | A | Number series | required |
| Input | B | Number series | required |
| Output | true/false | Signal (true/false) | – |
Good to know
Section titled “Good to know”- Search also finds it under: crosses, cross, ema, price, above, below, factor.
Technical details
Section titled “Technical details”“crosses above” is true when A is now above B times the factor and was at most on it one candle before, “crosses below” the other way round; the same rule as ta.crossover and ta.crossunder in TradingView.
- Type in the chain:
core.compare-ab· Version 1.0.0 · Category keycond - Settings in the chain:
operator(Condition),factor(Factor for B) - Pins in the chain: Input
a,b· Outputout - Reference tests in the manifest: 1 (with fixed price data: 500 candles of 1h)
- How a node is built
Versión 2026.11.29.15 · Changelog