code wiki / (root) / nx_fin_backtest_gate.nx

nx_fin_backtest_gate.nx

buildroot/runtime/nx_fin_backtest_gate.nx

3450 B59 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind gate/prooftopic fin
docsdependenciesstructsconstsfunctions

about

nx_fin_backtest_gate.nx -- R2 GATE: proves the backtester on KNOWN bars + a KNOWN signal, with EVERY metric hand-computed (no network, no false-green). Integrates R1 (md_parse_csv -> bars) into R2 (bt_run). The two trades are +50 (win) and -50 (loss) per share so the gate PROVES the engine reports losses honestly -- not the "no-loss" fantasy. Exits 0 iff all pass. license_tier: ORIGINAL

dependencies 3 imports · 0 importers

nx_gate.nx nx_fin_marketdata.nx nx_fin_backtest.nx nx_fin_backtest_gate.nx

imports: nx_gate.nxnx_fin_marketdata.nxnx_fin_backtest.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main chk gw sys_write gn sys_write ↻ sys_mmap bt_position_size md_capacity md_parse_csv md_find md_date_key md_price_cents md_atoi bt_run bt_position_size ↻ gw ↻ gn ↻

structs

none

consts

none

functions

9func chk(name: *u8, got: i64, want: i64, st: *i64) -> i64
called by 1: main calls 2: gwgn
15func main() -> i64