Sizing reference

All 1 sizing in AlgoBarsX, each with its parameters, defaults, ranges and an example: size_for.

size_for

size_for(symbol = market.symbol, risk, stop)→ lots#

The lot size an entry would use for a risk and stop, rounded down to the lot step.

Parameters

NameTypeDefaultWhat it is
symbolsymbolmarket.symbolMarket to size.
riskpercent | moneyrequiredRisk to take.
stopdistancerequiredStop distance.
Example
eur_size = size_for(EURUSD, risk: 0.5%, stop: 30 pips)
strategysince 1.0

Try this in the Terminal. AlgoBars is free: $0 a month, no card needed.

Create my free account