For quants›Assay

The scripting dialect you already know.

Paste a script that begins //@version=5 or 6 and it runs — and versions 1 to 4 too. Indicators, strategies, drawings, tables and alerts, in a full IDE: completion, diagnostics, a preview, a per-bar inspector, breakpoints and a profiler — and every script also as a graph of wired blocks you can build with, without typing.

1–6
versions run
IDE
in its own window
off
look-ahead by default
Assayillustration
Assay: the script is typed, checked, and drawn on the chart.

Assay

What it does, part by part.

It runs as written

Paste it, it runs

A script written in the dialect many traders already use opens and runs: request.security, ta.*, matrices and maps, tables, plots and fills — and the TA-Lib functions as talib.*.

  • Versions 1 to 6, read as written
  • A conversion only when you ask for it, with a diff
  • Nothing you paste ever leaves your machine
In the Docs
Versions one to six read as written, and a conversion shown as a diff.

The IDE

Write it like code

An editor in its own window with completion, signatures, diagnostics as you type, a preview on the chart in front, a per-bar inspector, breakpoints on a bar and a profiler per line.

  • Split editors and drafts kept
  • History of every save
  • The same language service for agents and editors (LSP)
  • Plus the debugger: stops and stepping into a bar
In the Docs
Completion, a diagnostic and the bar inspector.

The graph

Build it with blocks — or read any script as one

Every script has a second face: blocks wired together, each wearing its kind's colour and icon and the name a trader uses — Simple average, Crosses above, Marker. Drag a block in, press a value to change it, draw a wire socket to socket on the board — each written into the text at once, one step Ctrl+Z takes back. Move the nodes anywhere; the order the script runs in is always drawn.

  • Any script, pasted or written, as a graph
  • Seven colours by kind — and orders in plain ink
  • Nothing of the graph is written into the script
  • Plus to edit as blocks; looking at the graph is in every package
In the Docs
A wire drawn socket to socket on the board, written into the text.

Strategies in Assay

A script that trades

A strategy() script runs on the laboratory, paper or real workbench like any strategy — its orders through the same venue, its look-ahead off unless you turn it on.

  • strategy.entry, exit, close, order
  • Look-ahead only by a setting, marked everywhere
  • Batch and walk-forward over its inputs
In the Docs
A strategy's intentions.

Libraries

Your own libraries, from your own folder

library and import read from your own indicators folder — never fetched from anywhere — so a script's dependencies are files you can see.

  • Local libraries only
  • Completion knows a library's names
  • Each change re-checks what depends on it
In the Docs
A library in your own folder, its names completed in a script.

In code

A script

Two averages and the ribbon between them — pasted into the editor as it is.

//@version=6
indicator("Trend ribbon", overlay = true)
fast = ta.ema(close, 12)
slow = ta.ema(close, 34)
p1 = plot(fast, "fast", color.yellow)
p2 = plot(slow, "slow", color.blue)
fill(p1, p2, color.new(color.yellow, 85))

How it works

Four steps, in order.

  1. Open AssayFrom the application's bar.
  2. Paste or writeIt says whether it is an indicator or a strategy.
  3. Check and previewDiagnostics as you type; the chart in front shows it.
  4. Attach or runOn a chart, or as a strategy.

Packages

Learn on Free. Trade on Plus. Build on Pro.

What each package holds of this page. While the beta lasts, Plus and Pro are free to take: you choose your package on your account page, with no payment.

On this pageFreePlusPro
Your own scripts, on the chart✓✓✓
Editing a script as blocks—✓✓
The debugger—✓✓

∞ is no limit. What exceeds a package is locked, never deleted.Every package side by side

Good to know

What to expect, plainly.

Clean room

Assay is Bentrix's own implementation. Nothing of another product is copied or hosted.

Look-ahead

Off by default in the laboratory and on paper and real; turned on only by a setting you see.

Your scripts stay yours

Scripts live in your own folder. None is uploaded.

Bentrix is in beta. Plus and Pro are free to take.

One download for Windows. Choose your package on your account page, with no payment, while the beta lasts; a feature of Plus or Pro carries its badge in the application, so nothing changes by surprise.