test: golden-pin the four de-duplicated indicators across all bindings (#305)
* test: golden-pin the four de-duplicated indicators across all C-ABI bindings Extend gen_golden to emit reference fixtures for AdOscillator (ADOSC), IntradayIntensity, AwesomeOscillatorHistogram and AverageDrawdown, and replay them through the Go / C# / Java / R golden harnesses so their corrected definitions stay bit-identical to the Rust core in every binding. Go suite verified locally (gcc 13 + cgo): all 9 golden tests pass; C#/Java/R use the same fixtures and harness pattern (CI-verified). First step of extending the golden coverage beyond the seven archetype representatives. * test: golden-pin the scalar-output tranche (308 indicators) against Rust Extend gen_golden with a generated emit_scalar that writes reference fixtures for every single-f64-output indicator (scalar / candle / pairwise input) using valid constructor params, and add a manifest-driven generic Python golden replay that reconstructs each by its native name and checks it bit-for-bit against the Rust output. 308 indicators now value-tied to the Rust core in Python (pytest: 308/308). Takes golden coverage from the 7 archetype representatives to 308+ of the catalogue. 22 scalar indicators with non-default constructor constraints are skipped by gen_golden for now (logged), as are non-f64-output ones; multi-output, exotic inputs and the per-indicator arg arities of the C-ABI/Node replays follow. Generated + verified locally with the full toolchain. * test: golden-pin the multi-output tranche (70 indicators) in Python Add a generated emit_multi to gen_golden (per-indicator Output-field access, one CSV column per field) and a manifest-driven generic Python replay that checks every field of each multi-output indicator against the Rust reference. 70 multi-output indicators now value-tied to Rust in Python; combined with the scalar tranche, 378 indicators are golden-pinned. 8 multi with non-default param constraints and 5 with non-f64 Output fields (Option/Vec/i64) are deferred. pytest green. * test(golden): add 30 constraint-tuned indicators to scalar/multi golden suite Emit golden fixtures for 22 scalar-output and 8 multi-output indicators whose constructors need non-default parameters (Alma, Jma, Psar, T3, Mama, DoubleBollinger, ZigZag, ...). All 408 fixtures replay bit-for-bit through the Python binding. * test(golden): cover 36 missed scalar/multi indicators Add 26 single-output (LinearRegression family, HT cycle, Candle volatility estimators, DrawdownDuration) and 10 multi-output (BollingerBands, MACD/MACDEXT/MACDFIX, Camarilla, VWAP bands, ...) indicators to the golden suite. 444 fixtures replay bit-for-bit through the Python binding. * test(golden): cover 50 exotic-input indicators Add deterministic synthetic feeders for the DerivativesTick (17), CrossSection (15), Trade (8), TradeQuote (3) and OrderBook (7) families, derived from the shared OHLCV input series in both gen_golden and a new Python replay harness (test_golden_exotic). All 494 fixtures replay bit-for-bit through the Python binding. * test(golden): complete 514-indicator golden coverage Add the final tranches: 3 mixed multi-output indicators (Ichimoku, WilliamsFractals, LeadLagCrossCorrelation), 6 histogram profiles (time/volume seasonality + TPO/volume price profiles), 10 alt-chart bar builders and the footprint. Every one of the 514 distinct indicators now has a Rust-generated g_<Canonical>.csv fixture and a generic Python replay (scalar/multi/exotic/profile/bars), all passing bit-for-bit. * test(golden): add generic Node replay for all 514 indicators A manifest-driven node:test harness reconstructs every indicator by its native class, feeds the same synthetic stream derived from the shared golden input, and checks output bit-for-bit against the Rust reference fixtures (scalar/multi/exotic/profile/bars). node_manifest.json is generated from index.d.ts plus the Python-side manifests. 514/514 pass. * test(golden): add generated Go replay for all 514 indicators golden_all_test.go (generated by gen_golden_test.py) reconstructs every Go indicator, feeds the shared synthetic stream and checks output bit-for-bit against the Rust reference fixtures. A reflection-based comparator flattens multi-output structs, profiles and bar slices so one path covers all archetypes. This is the first C-ABI binding verified across the full catalogue. 514/514 pass. * test(golden): add generated C# replay for all 514 indicators GoldenAllTests.g.cs (generated by gen_golden_test.py) reconstructs every C# indicator, feeds the shared synthetic stream and checks output bit-for-bit against the Rust reference fixtures via a reflection-based flatten covering scalar/multi/profile/bar archetypes. 514/514 pass. Also add the '#nullable enable' directive the compiler requires to the generated Indicators.g.cs, clearing the four CS8669 warnings on the nullable double[] profile return types. * fix(java): marshal C ABI bool params correctly; add 514 golden replay The Java FFM binding marshalled the cross-section state flags (newHigh, newLow, aboveMa, onBuySignal) as JAVA_DOUBLE arrays, but the C ABI takes them as const bool* (one byte each), so the native side read the low byte of each 8-byte double and saw every flag as false. Add WickraNative. boolSegment and use it across the 15 cross-section indicators. Also pass the MacdExt MaType arguments as byte to match the uint8_t downcall descriptor (was int, throwing WrongMethodTypeException). Add GoldenAllTest.java (generated by gen_golden_test.py): a reflection runner replaying all 514 indicators against the Rust reference fixtures. The bugs above were found by this test; 514/514 now pass. * fix(r): marshal C ABI bool flags correctly; add 514 golden replay The R wrapper passed the cross-section state flags as (bool *)REAL(x), reinterpreting the 8-byte doubles as 1-byte bools so the native side read every flag as false. Add wk_bool_vec to convert each flag vector into a real C bool buffer and use it for all 15 cross-section update wrappers. Add test-golden-all.R + generated golden_specs.R: a reflective runner replaying all 514 indicators against the Rust reference fixtures. The bug above was found by this test; verified 514/514 pass locally. * test(golden): add WASM replay for all 514 indicators A manifest-driven node:test harness loads the nodejs-target wasm-pack build, reconstructs every indicator by its JS class, feeds the shared synthetic stream and checks output bit-for-bit against the Rust reference fixtures. wasm_manifest.json is generated from the wasm .d.ts plus the shared manifests; a recursive flattener covers scalar, multi (Reflect objects), profile and bar shapes. 514/514 pass locally (wasm-pack build --target nodejs, then node --test). * test(golden): add C and C++ replay for all 514 indicators golden_test.c (generated by gen_golden_test.py) drives every indicator through the C ABI (wickra.h) and checks output bit-for-bit against the Rust reference fixtures. golden_test.cpp #includes the same source so the identical runner is compiled and run under both gcc (C) and g++ (C++) via the CMake targets golden_test / golden_test_cpp — proving the extern "C" header is consumable from each language. Both 514/514 (verified via ctest). * test(golden): gofmt the generated Go golden replay * test(golden): make the Node fixture reader CRLF-safe and pin fixtures to LF
This commit is contained in:
@@ -32,3 +32,10 @@ bindings/r/src/Makevars.in text eol=lf
|
||||
bindings/r/src/Makevars.win text eol=lf
|
||||
bindings/r/src/wickra.c text eol=lf
|
||||
|
||||
# Golden fixtures are replayed byte-for-byte by every binding's parity test. Pin
|
||||
# them to LF so a Windows `core.autocrlf=true` checkout doesn't rewrite them as
|
||||
# CRLF — which silently broke the Node reader (`Number('inf\r')` is NaN, and a
|
||||
# blank "no-bar" row gained a stray `\r`), failing only on Windows runners. The
|
||||
# tolerant readers (Python `splitlines`/`float`) hid the same hazard.
|
||||
testdata/golden/** text eol=lf
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -159,4 +159,58 @@ public class GoldenTests
|
||||
AssertClose(got.Value.Adx, Cell(e[2]), i, "adx.adx");
|
||||
}
|
||||
}
|
||||
|
||||
// --- the four de-duplicated indicators ------------------------------------
|
||||
|
||||
[Fact]
|
||||
public void Candle_AdOscillator_MatchesGolden()
|
||||
{
|
||||
var input = Input();
|
||||
var expected = ReadCsv("ad_oscillator");
|
||||
using var ad = new AdOscillator();
|
||||
for (var i = 0; i < input.Length; i++)
|
||||
{
|
||||
var (o, h, l, c, v) = (input[i][0], input[i][1], input[i][2], input[i][3], input[i][4]);
|
||||
AssertClose(ad.Update(o, h, l, c, v, i), Cell(expected[i][0]), i, "ad_oscillator");
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Candle_IntradayIntensity_MatchesGolden()
|
||||
{
|
||||
var input = Input();
|
||||
var expected = ReadCsv("intraday_intensity");
|
||||
using var ii = new IntradayIntensity();
|
||||
for (var i = 0; i < input.Length; i++)
|
||||
{
|
||||
var (o, h, l, c, v) = (input[i][0], input[i][1], input[i][2], input[i][3], input[i][4]);
|
||||
AssertClose(ii.Update(o, h, l, c, v, i), Cell(expected[i][0]), i, "intraday_intensity");
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Candle_AwesomeOscillatorHistogram_MatchesGolden()
|
||||
{
|
||||
var input = Input();
|
||||
var expected = ReadCsv("awesome_oscillator_histogram");
|
||||
using var aoh = new AwesomeOscillatorHistogram(5, 34, 1);
|
||||
for (var i = 0; i < input.Length; i++)
|
||||
{
|
||||
var (o, h, l, c, v) = (input[i][0], input[i][1], input[i][2], input[i][3], input[i][4]);
|
||||
AssertClose(aoh.Update(o, h, l, c, v, i), Cell(expected[i][0]), i, "awesome_oscillator_histogram");
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Scalar_AverageDrawdown_MatchesGolden()
|
||||
{
|
||||
var input = Input();
|
||||
var expected = ReadCsv("average_drawdown");
|
||||
using var avg = new AverageDrawdown(20);
|
||||
for (var i = 0; i < input.Length; i++)
|
||||
{
|
||||
// generator fed the close column as the equity-curve sample.
|
||||
AssertClose(avg.Update(input[i][3]), Cell(expected[i][0]), i, "average_drawdown");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// <auto-generated />
|
||||
// Generated from bindings/c/include/wickra.h. Do not edit by hand.
|
||||
#nullable enable
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Wickra;
|
||||
|
||||
@@ -0,0 +1,300 @@
|
||||
"""Generate Wickra.Tests/GoldenAllTests.g.cs: a value-parity test that replays
|
||||
the shared golden input through every one of the 514 C# indicators and checks
|
||||
output bit-for-bit against the Rust reference fixtures g_<Canonical>.csv.
|
||||
|
||||
Run from repo root: python bindings/csharp/gen_golden_test.py
|
||||
"""
|
||||
import glob
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
G = os.path.join(ROOT, "testdata", "golden")
|
||||
GEN = open(os.path.join(ROOT, "bindings", "csharp", "Wickra", "Generated", "Indicators.g.cs"), encoding="utf-8").read()
|
||||
|
||||
# C# constructor parameter types per class.
|
||||
ctor_types = {}
|
||||
cur = None
|
||||
for line in GEN.splitlines():
|
||||
m = re.match(r"public sealed class (\w+)", line)
|
||||
if m:
|
||||
cur = m.group(1)
|
||||
continue
|
||||
if cur:
|
||||
cm = re.match(r"\s*public %s\(([^)]*)\)" % re.escape(cur), line)
|
||||
if cm:
|
||||
ps = cm.group(1).strip()
|
||||
types = [p.strip().rsplit(" ", 1)[0].strip() for p in ps.split(",")] if ps else []
|
||||
ctor_types[cur] = types
|
||||
cur = None
|
||||
|
||||
# Unified archetype + params, keyed by canonical (== C# class name).
|
||||
spec = {}
|
||||
for e in json.load(open(os.path.join(G, "scalar_manifest.json"))):
|
||||
arch = {"f64": "scalar_f64", "Candle": "scalar_candle", "(f64, f64)": "pairwise"}[e["input"]]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "multi_manifest.json"))):
|
||||
arch = {"f64": "multi_f64", "Candle": "multi_candle", "(f64, f64)": "multi_pairwise"}[e["input"]]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"], "n": e["n"]}
|
||||
ex = json.load(open(os.path.join(G, "exotic_manifest.json")))
|
||||
for e in ex["deriv"]:
|
||||
spec[e["canonical"]] = {"arch": "deriv_multi" if "n" in e else "deriv", "params": e["params"], "n": e.get("n")}
|
||||
for e in ex["cross"]:
|
||||
spec[e["canonical"]] = {"arch": "cross", "params": e["params"]}
|
||||
for e in ex["trade"]:
|
||||
spec[e["canonical"]] = {"arch": "trade", "params": e["params"]}
|
||||
for e in ex["trademid"]:
|
||||
spec[e["canonical"]] = {"arch": "trademid", "params": e["params"]}
|
||||
for e in ex["ob"]:
|
||||
spec[e["canonical"]] = {"arch": "ob", "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "profile_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": "profile_" + e["kind"], "params": e["params"], "width": e["width"]}
|
||||
for e in json.load(open(os.path.join(G, "bars_manifest.json"))):
|
||||
arch = "footprint" if e["canonical"] == "Footprint" else "bars_" + e["feed"]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"]}
|
||||
|
||||
canons = sorted(os.path.basename(f)[2:-4] for f in glob.glob(os.path.join(G, "g_*.csv")))
|
||||
|
||||
|
||||
def lit(value, cstype):
|
||||
if cstype == "int":
|
||||
return str(int(round(value)))
|
||||
if cstype == "uint":
|
||||
return f"{int(round(value))}u"
|
||||
if cstype == "byte":
|
||||
return f"(byte){int(round(value))}"
|
||||
f = float(value)
|
||||
s = repr(f)
|
||||
return s if ("." in s or "e" in s or "E" in s) else s + ".0"
|
||||
|
||||
|
||||
def ctor_call(canon):
|
||||
types = ctor_types.get(canon, [])
|
||||
vals = spec[canon]["params"]
|
||||
args = ", ".join(lit(v, t) for v, t in zip(vals, types))
|
||||
return f"new Wickra.{canon}({args})"
|
||||
|
||||
|
||||
def block(canon):
|
||||
s = spec[canon]
|
||||
a = s["arch"]
|
||||
L = [f" [Fact]", f" public void Golden_{canon}()", " {"]
|
||||
L.append(f" using var ind = {ctor_call(canon)};")
|
||||
L.append(" var got = new List<double[]>();")
|
||||
L.append(" for (var i = 0; i < Rows.Length; i++)")
|
||||
L.append(" {")
|
||||
L.append(" var r = Rows[i];")
|
||||
if a == "scalar_f64":
|
||||
L.append(" got.Add(new[] { ind.Update(r[3]) });")
|
||||
elif a == "pairwise":
|
||||
L.append(" got.Add(new[] { ind.Update(r[3], r[0]) });")
|
||||
elif a == "scalar_candle":
|
||||
L.append(" got.Add(new[] { ind.Update(r[0], r[1], r[2], r[3], r[4], i) });")
|
||||
elif a == "trade":
|
||||
L.append(" got.Add(new[] { ind.Update(r[3], r[4], r[3] >= r[0], i) });")
|
||||
elif a == "trademid":
|
||||
L.append(" got.Add(new[] { ind.Update(r[3], r[4], r[3] >= r[0], i, (r[1] + r[2]) / 2) });")
|
||||
elif a == "ob":
|
||||
L.append(" var (bp, bs, ap, asz) = ObLists(r);")
|
||||
L.append(" got.Add(new[] { ind.Update(bp, bs, ap, asz) });")
|
||||
elif a == "deriv":
|
||||
L.append(" var d = DerivFields(r);")
|
||||
L.append(" got.Add(new[] { ind.Update(d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], i) });")
|
||||
elif a == "deriv_multi":
|
||||
L.append(" var d = DerivFields(r);")
|
||||
L.append(" got.Add(FlattenNullable(ind.Update(d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], i), %d));" % s["n"])
|
||||
elif a == "cross":
|
||||
L.append(" var (ch, vo, nh, nl, am, ob) = CrossLists(r);")
|
||||
L.append(" got.Add(new[] { ind.Update(ch, vo, nh, nl, am, ob, i) });")
|
||||
elif a == "multi_f64":
|
||||
L.append(" got.Add(FlattenNullable(ind.Update(r[3]), %d));" % s["n"])
|
||||
elif a == "multi_pairwise":
|
||||
L.append(" got.Add(FlattenNullable(ind.Update(r[3], r[0]), %d));" % s["n"])
|
||||
elif a == "multi_candle":
|
||||
L.append(" got.Add(FlattenNullable(ind.Update(r[0], r[1], r[2], r[3], r[4], i), %d));" % s["n"])
|
||||
elif a == "profile_bins":
|
||||
L.append(" var bins = ind.Update(r[0], r[1], r[2], r[3], r[4], i);")
|
||||
L.append(" got.Add(bins ?? NanRow(%d));" % s["width"])
|
||||
elif a == "profile_pricebins":
|
||||
L.append(" got.Add(FlattenNullable(ind.Update(r[0], r[1], r[2], r[3], r[4], i), %d));" % s["width"])
|
||||
elif a == "bars_close":
|
||||
L.append(" got.Add(FlattenBars(ind.Update(r[3], r[3], r[3], r[3], 1.0, 0)));")
|
||||
elif a == "bars_candle4":
|
||||
L.append(" got.Add(FlattenBars(ind.Update(r[0], r[1], r[2], r[3], 1.0, 0)));")
|
||||
elif a == "bars_candle5":
|
||||
L.append(" got.Add(FlattenBars(ind.Update(r[0], r[1], r[2], r[3], r[4], 0)));")
|
||||
elif a == "footprint":
|
||||
L.append(" got.Add(FlattenBars(ind.Update(r[3], r[4], r[3] >= r[0], i)));")
|
||||
else:
|
||||
raise SystemExit("arch " + a)
|
||||
L.append(" }")
|
||||
L.append(f' Compare("{canon}", got);')
|
||||
L.append(" }")
|
||||
return "\n".join(L)
|
||||
|
||||
|
||||
HEADER = '''// <auto-generated>
|
||||
// Generated by gen_golden_test.py. DO NOT EDIT.
|
||||
//
|
||||
// Value-parity for every one of the 514 C# indicators: the shared golden input
|
||||
// is replayed through each one and checked bit-for-bit against the Rust
|
||||
// reference fixtures testdata/golden/g_<Canonical>.csv. Multi-output, profile
|
||||
// and bar shapes are flattened by reflection so one comparator covers all
|
||||
// archetypes. Regenerate with: python bindings/csharp/gen_golden_test.py
|
||||
// </auto-generated>
|
||||
#nullable enable
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using Xunit;
|
||||
|
||||
namespace Wickra.Tests;
|
||||
|
||||
public class GoldenAllTests
|
||||
{
|
||||
private const double Tol = 1e-6;
|
||||
|
||||
private static readonly double[][] Rows = LoadInput();
|
||||
|
||||
private static string GoldenDir([System.Runtime.CompilerServices.CallerFilePath] string file = "") =>
|
||||
Path.GetFullPath(Path.Combine(Path.GetDirectoryName(file)!, "..", "..", "..", "testdata", "golden"));
|
||||
|
||||
private static double Cell(string s) =>
|
||||
s == "nan" ? double.NaN
|
||||
: s == "inf" ? double.PositiveInfinity
|
||||
: s == "-inf" ? double.NegativeInfinity
|
||||
: double.Parse(s, CultureInfo.InvariantCulture);
|
||||
|
||||
private static double[][] LoadInput()
|
||||
{
|
||||
var lines = File.ReadAllLines(Path.Combine(GoldenDir(), "input.csv"));
|
||||
return lines.Skip(1).Where(l => l.Length > 0)
|
||||
.Select(l => l.Split(',').Select(x => double.Parse(x, CultureInfo.InvariantCulture)).ToArray())
|
||||
.ToArray();
|
||||
}
|
||||
|
||||
// Keep blank lines (a candle on which no bar closed) so rows stay aligned.
|
||||
private static double[]?[] ReadFixture(string name)
|
||||
{
|
||||
var lines = File.ReadAllLines(Path.Combine(GoldenDir(), "g_" + name + ".csv"));
|
||||
return lines.Skip(1).Select(l => l.Length == 0 ? Array.Empty<double>() : l.Split(',').Select(Cell).ToArray()).ToArray();
|
||||
}
|
||||
|
||||
private static double[] NanRow(int n)
|
||||
{
|
||||
var r = new double[n];
|
||||
for (var i = 0; i < n; i++) r[i] = double.NaN;
|
||||
return r;
|
||||
}
|
||||
|
||||
private static double[] FlattenStruct(object o)
|
||||
{
|
||||
var props = o.GetType()
|
||||
.GetProperties(BindingFlags.Public | BindingFlags.Instance)
|
||||
.OrderBy(p => p.MetadataToken);
|
||||
var list = new List<double>();
|
||||
foreach (var p in props)
|
||||
{
|
||||
var v = p.GetValue(o);
|
||||
switch (v)
|
||||
{
|
||||
case double d: list.Add(d); break;
|
||||
case float f: list.Add(f); break;
|
||||
case long l: list.Add(l); break;
|
||||
case int n: list.Add(n); break;
|
||||
case double[] arr: list.AddRange(arr); break;
|
||||
}
|
||||
}
|
||||
return list.ToArray();
|
||||
}
|
||||
|
||||
private static double[] FlattenNullable<T>(T? value, int width) where T : struct =>
|
||||
value.HasValue ? FlattenStruct(value.Value) : NanRow(width);
|
||||
|
||||
private static double[] FlattenBars<T>(T[] bars)
|
||||
{
|
||||
var list = new List<double>();
|
||||
foreach (var bar in bars) list.AddRange(FlattenStruct(bar!));
|
||||
return list.ToArray();
|
||||
}
|
||||
|
||||
private static double[] DerivFields(double[] r)
|
||||
{
|
||||
double o = r[0], h = r[1], l = r[2], c = r[3], v = r[4];
|
||||
return new[]
|
||||
{
|
||||
(c - o) / c * 0.01, c, c - 0.5, c + 1.0, v * 10.0, v * 0.6, v * 0.4,
|
||||
v * 0.55, v * 0.45, h - c, c - l,
|
||||
};
|
||||
}
|
||||
|
||||
private static (double[], double[], bool[], bool[], bool[], bool[]) CrossLists(double[] r)
|
||||
{
|
||||
double o = r[0], c = r[3], v = r[4];
|
||||
var change = new double[5];
|
||||
var volume = new double[5];
|
||||
var nh = new bool[5];
|
||||
var nl = new bool[5];
|
||||
var am = new bool[5];
|
||||
var ob = new bool[5];
|
||||
for (var j = 0; j < 5; j++)
|
||||
{
|
||||
change[j] = (c - o) + j;
|
||||
volume[j] = v + j * 10.0;
|
||||
nh[j] = j % 2 == 0;
|
||||
nl[j] = j % 3 == 0;
|
||||
am[j] = j % 2 == 0;
|
||||
ob[j] = j % 3 == 0;
|
||||
}
|
||||
return (change, volume, nh, nl, am, ob);
|
||||
}
|
||||
|
||||
private static (double[], double[], double[], double[]) ObLists(double[] r)
|
||||
{
|
||||
double c = r[3], v = r[4];
|
||||
var bp = new double[5];
|
||||
var bs = new double[5];
|
||||
var ap = new double[5];
|
||||
var asz = new double[5];
|
||||
for (var k = 0; k < 5; k++)
|
||||
{
|
||||
var kf = k + 1;
|
||||
bp[k] = c - 0.1 * kf;
|
||||
bs[k] = v / kf;
|
||||
ap[k] = c + 0.1 * kf;
|
||||
asz[k] = v * 0.9 / kf;
|
||||
}
|
||||
return (bp, bs, ap, asz);
|
||||
}
|
||||
|
||||
private static void Compare(string name, List<double[]> got)
|
||||
{
|
||||
var exp = ReadFixture(name);
|
||||
Assert.True(exp.Length == got.Count, $"{name}: {exp.Length} fixture rows vs {got.Count} computed");
|
||||
for (var i = 0; i < exp.Length; i++)
|
||||
{
|
||||
var want = exp[i]!;
|
||||
var g = got[i];
|
||||
Assert.True(want.Length == g.Length, $"{name} row {i}: arity {g.Length} vs {want.Length}");
|
||||
for (var k = 0; k < want.Length; k++)
|
||||
{
|
||||
var w = want[k];
|
||||
if (double.IsNaN(w)) { Assert.True(double.IsNaN(g[k]), $"{name} row {i} col {k}: want NaN got {g[k]}"); continue; }
|
||||
if (double.IsInfinity(w)) { Assert.True(double.IsInfinity(g[k]) && Math.Sign(g[k]) == Math.Sign(w), $"{name} row {i} col {k}: want {w} got {g[k]}"); continue; }
|
||||
var tol = Tol * Math.Max(1.0, Math.Abs(w));
|
||||
Assert.True(Math.Abs(g[k] - w) <= tol, $"{name} row {i} col {k}: got {g[k]} want {w}");
|
||||
}
|
||||
}
|
||||
}
|
||||
'''
|
||||
|
||||
out = [HEADER]
|
||||
for canon in canons:
|
||||
out.append(block(canon))
|
||||
out.append("}")
|
||||
open(os.path.join(ROOT, "bindings", "csharp", "Wickra.Tests", "GoldenAllTests.g.cs"), "w", encoding="utf-8").write("\n".join(out) + "\n")
|
||||
print("generated GoldenAllTests.g.cs with", len(canons), "indicators")
|
||||
@@ -0,0 +1,337 @@
|
||||
"""Generate golden_all_test.go: a value-parity test that replays the shared
|
||||
golden input through every one of the 514 Go indicators and checks output
|
||||
bit-for-bit against the Rust-generated g_<Canonical>.csv fixtures.
|
||||
|
||||
Run from repo root: python bindings/go/gen_golden_test.py
|
||||
"""
|
||||
import glob
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
G = os.path.join(ROOT, "testdata", "golden")
|
||||
GEN = open(os.path.join(ROOT, "bindings", "go", "indicators_gen.go"), encoding="utf-8").read()
|
||||
|
||||
# Go constructor parameter types, keyed by canonical (== Go type name).
|
||||
ctor_types = {}
|
||||
for m in re.finditer(r"func New(\w+)\(([^)]*)\)\s*\(\*\w+, error\)", GEN):
|
||||
name, ps = m.group(1), m.group(2).strip()
|
||||
types = []
|
||||
if ps:
|
||||
for p in ps.split(","):
|
||||
p = p.strip()
|
||||
_, _, ty = p.partition(" ")
|
||||
types.append(ty.strip())
|
||||
ctor_types[name] = types
|
||||
|
||||
# Unified archetype + params, keyed by canonical.
|
||||
spec = {} # canon -> dict(arch, params, width?, n?)
|
||||
scal = json.load(open(os.path.join(G, "scalar_manifest.json")))
|
||||
for e in scal:
|
||||
inp = e["input"]
|
||||
arch = {"f64": "scalar_f64", "Candle": "scalar_candle", "(f64, f64)": "pairwise"}[inp]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "multi_manifest.json"))):
|
||||
inp = e["input"]
|
||||
arch = {"f64": "multi_f64", "Candle": "multi_candle", "(f64, f64)": "multi_pairwise"}[inp]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"], "n": e["n"]}
|
||||
ex = json.load(open(os.path.join(G, "exotic_manifest.json")))
|
||||
for e in ex["deriv"]:
|
||||
spec[e["canonical"]] = {"arch": "deriv_multi" if "n" in e else "deriv", "params": e["params"], "n": e.get("n")}
|
||||
for e in ex["cross"]:
|
||||
spec[e["canonical"]] = {"arch": "cross", "params": e["params"]}
|
||||
for e in ex["trade"]:
|
||||
spec[e["canonical"]] = {"arch": "trade", "params": e["params"]}
|
||||
for e in ex["trademid"]:
|
||||
spec[e["canonical"]] = {"arch": "trademid", "params": e["params"]}
|
||||
for e in ex["ob"]:
|
||||
spec[e["canonical"]] = {"arch": "ob", "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "profile_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": "profile_" + e["kind"], "params": e["params"], "width": e["width"]}
|
||||
for e in json.load(open(os.path.join(G, "bars_manifest.json"))):
|
||||
arch = "footprint" if e["canonical"] == "Footprint" else "bars_" + e["feed"]
|
||||
spec[e["canonical"]] = {"arch": arch, "params": e["params"]}
|
||||
|
||||
canons = sorted(os.path.basename(f)[2:-4] for f in glob.glob(os.path.join(G, "g_*.csv")))
|
||||
|
||||
|
||||
def go_param(value, gotype):
|
||||
intlike = gotype in ("int", "int32", "int64", "uint", "uintptr", "usize")
|
||||
if intlike:
|
||||
return str(int(round(value)))
|
||||
# float64
|
||||
return repr(float(value)) if "." in repr(float(value)) or "e" in repr(float(value)) else f"{float(value)}"
|
||||
|
||||
|
||||
def ctor_call(canon):
|
||||
types = ctor_types.get(canon, [])
|
||||
vals = spec[canon]["params"]
|
||||
args = ", ".join(go_param(v, t) for v, t in zip(vals, types))
|
||||
return f"New{canon}({args})"
|
||||
|
||||
|
||||
# Update-call expression + output handling per archetype.
|
||||
def block(canon):
|
||||
s = spec[canon]
|
||||
a = s["arch"]
|
||||
ctor = ctor_call(canon)
|
||||
lines = [f'\tt.Run("{canon}", func(t *testing.T) {{']
|
||||
lines.append(f"\t\tind, err := {ctor}")
|
||||
lines.append('\t\tif err != nil {')
|
||||
lines.append(f'\t\t\tt.Fatalf("new {canon}: %v", err)')
|
||||
lines.append("\t\t}")
|
||||
lines.append("\t\tgot := make([][]float64, len(rows))")
|
||||
lines.append("\t\tfor i, r := range rows {")
|
||||
if a == "scalar_f64":
|
||||
upd = "ind.Update(r[3])"
|
||||
lines.append(f"\t\t\tgot[i] = []float64{{{upd}}}")
|
||||
elif a == "pairwise":
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(r[3], r[0])}")
|
||||
elif a == "scalar_candle":
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(r[0], r[1], r[2], r[3], r[4], int64(i))}")
|
||||
elif a == "trade":
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(r[3], r[4], r[3] >= r[0], int64(i))}")
|
||||
elif a == "trademid":
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(r[3], r[4], r[3] >= r[0], int64(i), (r[1]+r[2])/2)}")
|
||||
elif a == "ob":
|
||||
lines.append("\t\t\tbp, bs, ap, as_ := obLists(r)")
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(bp, bs, ap, as_)}")
|
||||
elif a == "deriv":
|
||||
lines.append("\t\t\td := derivFields(r)")
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], int64(i))}")
|
||||
elif a == "deriv_multi":
|
||||
lines.append("\t\t\td := derivFields(r)")
|
||||
lines.append("\t\t\tout, ok := ind.Update(d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], int64(i))")
|
||||
lines.append(f"\t\t\tgot[i] = reflectRow(out, ok, {s['n']})")
|
||||
elif a == "cross":
|
||||
lines.append("\t\t\tch, vo, nh, nl, am, ob_ := crossLists(r)")
|
||||
lines.append("\t\t\tgot[i] = []float64{ind.Update(ch, vo, nh, nl, am, ob_, int64(i))}")
|
||||
elif a in ("multi_f64",):
|
||||
lines.append("\t\t\tout, ok := ind.Update(r[3])")
|
||||
lines.append(f"\t\t\tgot[i] = reflectRow(out, ok, {s['n']})")
|
||||
elif a == "multi_pairwise":
|
||||
lines.append("\t\t\tout, ok := ind.Update(r[3], r[0])")
|
||||
lines.append(f"\t\t\tgot[i] = reflectRow(out, ok, {s['n']})")
|
||||
elif a == "multi_candle":
|
||||
lines.append("\t\t\tout, ok := ind.Update(r[0], r[1], r[2], r[3], r[4], int64(i))")
|
||||
lines.append(f"\t\t\tgot[i] = reflectRow(out, ok, {s['n']})")
|
||||
elif a == "profile_bins":
|
||||
lines.append("\t\t\tbins, ok := ind.Update(r[0], r[1], r[2], r[3], r[4], int64(i))")
|
||||
lines.append(f"\t\t\tif ok {{ got[i] = bins }} else {{ got[i] = nanRow({s['width']}) }}")
|
||||
elif a == "profile_pricebins":
|
||||
lines.append("\t\t\tout, ok := ind.Update(r[0], r[1], r[2], r[3], r[4], int64(i))")
|
||||
lines.append(f"\t\t\tgot[i] = reflectRow(out, ok, {s['width']})")
|
||||
elif a == "bars_close":
|
||||
lines.append("\t\t\tgot[i] = flattenBars(ind.Update(r[3], r[3], r[3], r[3], 1.0, 0))")
|
||||
elif a == "bars_candle4":
|
||||
lines.append("\t\t\tgot[i] = flattenBars(ind.Update(r[0], r[1], r[2], r[3], 1.0, 0))")
|
||||
elif a == "bars_candle5":
|
||||
lines.append("\t\t\tgot[i] = flattenBars(ind.Update(r[0], r[1], r[2], r[3], r[4], 0))")
|
||||
elif a == "footprint":
|
||||
lines.append("\t\t\tgot[i] = flattenBars(ind.Update(r[3], r[4], r[3] >= r[0], int64(i)))")
|
||||
else:
|
||||
raise SystemExit("unknown arch " + a)
|
||||
lines.append("\t\t}")
|
||||
lines.append(f'\t\tcompareGolden(t, "{canon}", got)')
|
||||
lines.append("\t})")
|
||||
return "\n".join(lines)
|
||||
|
||||
|
||||
HEADER = '''// Code generated by gen_golden_test.py. DO NOT EDIT.
|
||||
//
|
||||
// Value-parity for every one of the 514 Go indicators: the shared golden input
|
||||
// is replayed through each one and checked bit-for-bit against the Rust
|
||||
// reference fixtures testdata/golden/g_<Canonical>.csv. Multi-output, profile
|
||||
// and bar shapes are flattened by reflection so a single comparator covers all
|
||||
// archetypes. Regenerate with: python bindings/go/gen_golden_test.py
|
||||
|
||||
package wickra
|
||||
|
||||
import (
|
||||
\t"bufio"
|
||||
\t"math"
|
||||
\t"os"
|
||||
\t"reflect"
|
||||
\t"strings"
|
||||
\t"testing"
|
||||
)
|
||||
|
||||
// readGoldenRaw keeps blank lines (a candle on which no bar closed) so bar rows
|
||||
// stay aligned to the input; non-bar fixtures contain no blank lines.
|
||||
func readGoldenRaw(t *testing.T, name string) [][]string {
|
||||
\tt.Helper()
|
||||
\tf, err := os.Open("../../testdata/golden/" + name + ".csv")
|
||||
\tif err != nil {
|
||||
\t\tt.Fatalf("open %s: %v", name, err)
|
||||
\t}
|
||||
\tdefer f.Close()
|
||||
\tvar rows [][]string
|
||||
\tsc := bufio.NewScanner(f)
|
||||
\tsc.Buffer(make([]byte, 0, 1024*1024), 1024*1024)
|
||||
\tfirst := true
|
||||
\tfor sc.Scan() {
|
||||
\t\tline := sc.Text()
|
||||
\t\tif first {
|
||||
\t\t\tfirst = false
|
||||
\t\t\tcontinue
|
||||
\t\t}
|
||||
\t\tif line == "" {
|
||||
\t\t\trows = append(rows, []string{})
|
||||
\t\t\tcontinue
|
||||
\t\t}
|
||||
\t\trows = append(rows, strings.Split(line, ","))
|
||||
\t}
|
||||
\treturn rows
|
||||
}
|
||||
|
||||
func nanRow(n int) []float64 {
|
||||
\tr := make([]float64, n)
|
||||
\tfor i := range r {
|
||||
\t\tr[i] = math.NaN()
|
||||
\t}
|
||||
\treturn r
|
||||
}
|
||||
|
||||
func reflectRow(out any, ok bool, width int) []float64 {
|
||||
\tif !ok {
|
||||
\t\treturn nanRow(width)
|
||||
\t}
|
||||
\tv := reflect.ValueOf(out)
|
||||
\trow := make([]float64, 0, width)
|
||||
\tfor k := 0; k < v.NumField(); k++ {
|
||||
\t\trow = appendField(row, v.Field(k))
|
||||
\t}
|
||||
\treturn row
|
||||
}
|
||||
|
||||
func appendField(row []float64, f reflect.Value) []float64 {
|
||||
\tswitch f.Kind() {
|
||||
\tcase reflect.Float64, reflect.Float32:
|
||||
\t\treturn append(row, f.Float())
|
||||
\tcase reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
|
||||
\t\treturn append(row, float64(f.Int()))
|
||||
\tcase reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr:
|
||||
\t\treturn append(row, float64(f.Uint()))
|
||||
\tcase reflect.Slice:
|
||||
\t\tfor j := 0; j < f.Len(); j++ {
|
||||
\t\t\trow = appendField(row, f.Index(j))
|
||||
\t\t}
|
||||
\t\treturn row
|
||||
\tdefault:
|
||||
\t\treturn row
|
||||
\t}
|
||||
}
|
||||
|
||||
func flattenBars(bars any) []float64 {
|
||||
\tv := reflect.ValueOf(bars)
|
||||
\trow := []float64{}
|
||||
\tfor i := 0; i < v.Len(); i++ {
|
||||
\t\tbar := v.Index(i)
|
||||
\t\tfor k := 0; k < bar.NumField(); k++ {
|
||||
\t\t\trow = appendField(row, bar.Field(k))
|
||||
\t\t}
|
||||
\t}
|
||||
\treturn row
|
||||
}
|
||||
|
||||
// Synthetic feeds derived from one OHLCV row, identical to gen_golden's Rust
|
||||
// construction (DerivativesTick / CrossSection / OrderBook).
|
||||
func derivFields(r []float64) [11]float64 {
|
||||
\to, h, l, c, v := r[0], r[1], r[2], r[3], r[4]
|
||||
\treturn [11]float64{
|
||||
\t\t(c - o) / c * 0.01, // funding_rate
|
||||
\t\tc, // mark_price
|
||||
\t\tc - 0.5, // index_price
|
||||
\t\tc + 1.0, // futures_price
|
||||
\t\tv * 10.0, // open_interest
|
||||
\t\tv * 0.6, // long_size
|
||||
\t\tv * 0.4, // short_size
|
||||
\t\tv * 0.55, // taker_buy_volume
|
||||
\t\tv * 0.45, // taker_sell_volume
|
||||
\t\th - c, // long_liquidation
|
||||
\t\tc - l, // short_liquidation
|
||||
\t}
|
||||
}
|
||||
|
||||
func crossLists(r []float64) ([]float64, []float64, []bool, []bool, []bool, []bool) {
|
||||
\to, c, v := r[0], r[3], r[4]
|
||||
\tchange := make([]float64, 5)
|
||||
\tvolume := make([]float64, 5)
|
||||
\tnewHigh := make([]bool, 5)
|
||||
\tnewLow := make([]bool, 5)
|
||||
\taboveMa := make([]bool, 5)
|
||||
\tonBuy := make([]bool, 5)
|
||||
\tfor j := 0; j < 5; j++ {
|
||||
\t\tjf := float64(j)
|
||||
\t\tchange[j] = (c - o) + jf
|
||||
\t\tvolume[j] = v + jf*10.0
|
||||
\t\tnewHigh[j] = j%2 == 0
|
||||
\t\tnewLow[j] = j%3 == 0
|
||||
\t\taboveMa[j] = j%2 == 0
|
||||
\t\tonBuy[j] = j%3 == 0
|
||||
\t}
|
||||
\treturn change, volume, newHigh, newLow, aboveMa, onBuy
|
||||
}
|
||||
|
||||
func obLists(r []float64) ([]float64, []float64, []float64, []float64) {
|
||||
\tc, v := r[3], r[4]
|
||||
\tbidPx := make([]float64, 5)
|
||||
\tbidSz := make([]float64, 5)
|
||||
\taskPx := make([]float64, 5)
|
||||
\taskSz := make([]float64, 5)
|
||||
\tfor k := 0; k < 5; k++ {
|
||||
\t\tkf := float64(k + 1)
|
||||
\t\tbidPx[k] = c - 0.1*kf
|
||||
\t\tbidSz[k] = v / kf
|
||||
\t\taskPx[k] = c + 0.1*kf
|
||||
\t\taskSz[k] = v * 0.9 / kf
|
||||
\t}
|
||||
\treturn bidPx, bidSz, askPx, askSz
|
||||
}
|
||||
|
||||
func compareGolden(t *testing.T, name string, got [][]float64) {
|
||||
\tt.Helper()
|
||||
\texp := readGoldenRaw(t, "g_"+name)
|
||||
\tif len(exp) != len(got) {
|
||||
\t\tt.Fatalf("%s: %d fixture rows vs %d computed", name, len(exp), len(got))
|
||||
\t}
|
||||
\tfor i := range exp {
|
||||
\t\tif len(exp[i]) != len(got[i]) {
|
||||
\t\t\tt.Fatalf("%s row %d: arity %d vs %d", name, i, len(got[i]), len(exp[i]))
|
||||
\t\t}
|
||||
\t\tfor k := range exp[i] {
|
||||
\t\t\twant := goldenCell(exp[i][k])
|
||||
\t\t\tg := got[i][k]
|
||||
\t\t\tif math.IsNaN(want) {
|
||||
\t\t\t\tif !math.IsNaN(g) {
|
||||
\t\t\t\t\tt.Fatalf("%s row %d col %d: want NaN got %v", name, i, k, g)
|
||||
\t\t\t\t}
|
||||
\t\t\t\tcontinue
|
||||
\t\t\t}
|
||||
\t\t\tif math.IsInf(want, 0) {
|
||||
\t\t\t\tif !math.IsInf(g, 0) || (g > 0) != (want > 0) {
|
||||
\t\t\t\t\tt.Fatalf("%s row %d col %d: want %v got %v", name, i, k, want, g)
|
||||
\t\t\t\t}
|
||||
\t\t\t\tcontinue
|
||||
\t\t\t}
|
||||
\t\t\ttol := goldenTol * math.Max(1.0, math.Abs(want))
|
||||
\t\t\tif math.Abs(g-want) > tol {
|
||||
\t\t\t\tt.Fatalf("%s row %d col %d: got %v want %v", name, i, k, g, want)
|
||||
\t\t\t}
|
||||
\t\t}
|
||||
\t}
|
||||
}
|
||||
|
||||
func TestGoldenAll(t *testing.T) {
|
||||
\trows := goldenInput(t)
|
||||
'''
|
||||
|
||||
# bars need blank-line-preserving fixture reads; reuse readGolden but it skips
|
||||
# blanks. We need a raw reader for bars and input.
|
||||
out = [HEADER]
|
||||
for canon in canons:
|
||||
out.append(block(canon))
|
||||
out.append("}")
|
||||
open(os.path.join(ROOT, "bindings", "go", "golden_all_test.go"), "w", encoding="utf-8").write("\n".join(out) + "\n")
|
||||
print("generated golden_all_test.go with", len(canons), "indicators")
|
||||
File diff suppressed because it is too large
Load Diff
@@ -189,3 +189,62 @@ func TestGoldenAdx(t *testing.T) {
|
||||
assertGoldenClose(t, out.Adx, goldenCell(exp[i][2]), i, "adx.adx")
|
||||
}
|
||||
}
|
||||
|
||||
// The four de-duplicated indicators: pin their corrected definitions against
|
||||
// the Rust reference so the Go FFI stays bit-identical.
|
||||
|
||||
func TestGoldenAdOscillator(t *testing.T) {
|
||||
input := goldenInput(t)
|
||||
exp := readGolden(t, "ad_oscillator")
|
||||
ad, err := NewAdOscillator()
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer ad.Close()
|
||||
for i := range input {
|
||||
got := ad.Update(input[i][0], input[i][1], input[i][2], input[i][3], input[i][4], int64(i))
|
||||
assertGoldenClose(t, got, goldenCell(exp[i][0]), i, "ad_oscillator")
|
||||
}
|
||||
}
|
||||
|
||||
func TestGoldenIntradayIntensity(t *testing.T) {
|
||||
input := goldenInput(t)
|
||||
exp := readGolden(t, "intraday_intensity")
|
||||
ii, err := NewIntradayIntensity()
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer ii.Close()
|
||||
for i := range input {
|
||||
got := ii.Update(input[i][0], input[i][1], input[i][2], input[i][3], input[i][4], int64(i))
|
||||
assertGoldenClose(t, got, goldenCell(exp[i][0]), i, "intraday_intensity")
|
||||
}
|
||||
}
|
||||
|
||||
func TestGoldenAwesomeOscillatorHistogram(t *testing.T) {
|
||||
input := goldenInput(t)
|
||||
exp := readGolden(t, "awesome_oscillator_histogram")
|
||||
aoh, err := NewAwesomeOscillatorHistogram(5, 34, 1)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer aoh.Close()
|
||||
for i := range input {
|
||||
got := aoh.Update(input[i][0], input[i][1], input[i][2], input[i][3], input[i][4], int64(i))
|
||||
assertGoldenClose(t, got, goldenCell(exp[i][0]), i, "awesome_oscillator_histogram")
|
||||
}
|
||||
}
|
||||
|
||||
func TestGoldenAverageDrawdown(t *testing.T) {
|
||||
input := goldenInput(t)
|
||||
exp := readGolden(t, "average_drawdown")
|
||||
avg, err := NewAverageDrawdown(20)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer avg.Close()
|
||||
for i := range input {
|
||||
// generator fed the close column as the equity-curve sample.
|
||||
assertGoldenClose(t, avg.Update(input[i][3]), goldenCell(exp[i][0]), i, "average_drawdown")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,279 @@
|
||||
"""Generate src/test/java/org/wickra/GoldenAllTest.java: a reflection-driven
|
||||
value-parity test that replays the shared golden input through every one of the
|
||||
514 Java indicators and checks output bit-for-bit against the Rust reference
|
||||
fixtures g_<Canonical>.csv. The per-indicator spec is embedded so the test has
|
||||
no JSON dependency; a single reflective runner covers all archetypes.
|
||||
|
||||
Run from repo root: python bindings/java/gen_golden_test.py
|
||||
"""
|
||||
import json
|
||||
import os
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
MAN = json.load(open(os.path.join(ROOT, "testdata", "golden", "golden_manifest.json")))
|
||||
|
||||
|
||||
def params_lit(ps):
|
||||
if not ps:
|
||||
return "new double[]{}"
|
||||
return "new double[]{" + ", ".join(repr(float(p)) for p in ps) + "}"
|
||||
|
||||
|
||||
specs = []
|
||||
for e in MAN:
|
||||
n = e.get("n", e.get("width", 0))
|
||||
specs.append(f' new Spec("{e["canonical"]}", "{e["arch"]}", {params_lit(e["params"])}, {n}),')
|
||||
specs_block = "\n".join(specs)
|
||||
|
||||
TEMPLATE = '''// Code generated by gen_golden_test.py. DO NOT EDIT.
|
||||
package org.wickra;
|
||||
|
||||
import org.junit.jupiter.api.DynamicTest;
|
||||
import org.junit.jupiter.api.TestFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.lang.reflect.Array;
|
||||
import java.lang.reflect.Constructor;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.RecordComponent;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
import static org.junit.jupiter.api.DynamicTest.dynamicTest;
|
||||
|
||||
/**
|
||||
* Reflection-driven value parity for the whole 514-indicator catalogue: each
|
||||
* indicator is reconstructed by its class name, fed the synthetic stream derived
|
||||
* from the shared golden input (identical to gen_golden's Rust construction) and
|
||||
* checked bit-for-bit against testdata/golden/g_<Canonical>.csv. One runner
|
||||
* flattens scalar, multi-output records, profiles and bar arrays by reflection.
|
||||
*/
|
||||
class GoldenAllTest {
|
||||
private static final double TOL = 1e-6;
|
||||
|
||||
private record Spec(String canonical, String arch, double[] params, int width) {}
|
||||
|
||||
private static final Spec[] SPECS = {
|
||||
%SPECS%
|
||||
};
|
||||
|
||||
private static Path goldenDir() {
|
||||
java.io.File d = new java.io.File("").getAbsoluteFile();
|
||||
while (d != null) {
|
||||
java.io.File g = new java.io.File(d, "testdata/golden");
|
||||
if (g.isDirectory()) {
|
||||
return g.toPath();
|
||||
}
|
||||
d = d.getParentFile();
|
||||
}
|
||||
throw new IllegalStateException("testdata/golden not found");
|
||||
}
|
||||
|
||||
private static double cell(String s) {
|
||||
return switch (s) {
|
||||
case "nan" -> Double.NaN;
|
||||
case "inf" -> Double.POSITIVE_INFINITY;
|
||||
case "-inf" -> Double.NEGATIVE_INFINITY;
|
||||
default -> Double.parseDouble(s);
|
||||
};
|
||||
}
|
||||
|
||||
private static double[][] input() throws IOException {
|
||||
List<String> lines = Files.readAllLines(goldenDir().resolve("input.csv"));
|
||||
List<double[]> rows = new ArrayList<>();
|
||||
for (int i = 1; i < lines.size(); i++) {
|
||||
if (lines.get(i).isEmpty()) continue;
|
||||
String[] p = lines.get(i).split(",");
|
||||
double[] r = new double[p.length];
|
||||
for (int j = 0; j < p.length; j++) r[j] = Double.parseDouble(p[j]);
|
||||
rows.add(r);
|
||||
}
|
||||
return rows.toArray(new double[0][]);
|
||||
}
|
||||
|
||||
// Keep blank lines (a candle on which no bar closed) so rows stay aligned.
|
||||
private static double[][] fixture(String name) throws IOException {
|
||||
List<String> lines = Files.readAllLines(goldenDir().resolve("g_" + name + ".csv"));
|
||||
List<double[]> rows = new ArrayList<>();
|
||||
for (int i = 1; i < lines.size(); i++) {
|
||||
String ln = lines.get(i);
|
||||
if (ln.isEmpty()) {
|
||||
rows.add(new double[0]);
|
||||
continue;
|
||||
}
|
||||
String[] p = ln.split(",");
|
||||
double[] r = new double[p.length];
|
||||
for (int j = 0; j < p.length; j++) r[j] = cell(p[j]);
|
||||
rows.add(r);
|
||||
}
|
||||
return rows.toArray(new double[0][]);
|
||||
}
|
||||
|
||||
private static double[] nanRow(int n) {
|
||||
double[] r = new double[n];
|
||||
java.util.Arrays.fill(r, Double.NaN);
|
||||
return r;
|
||||
}
|
||||
|
||||
private static double[] derivFields(double[] r) {
|
||||
double o = r[0], h = r[1], l = r[2], c = r[3], v = r[4];
|
||||
return new double[]{
|
||||
(c - o) / c * 0.01, c, c - 0.5, c + 1.0, v * 10.0, v * 0.6, v * 0.4,
|
||||
v * 0.55, v * 0.45, h - c, c - l,
|
||||
};
|
||||
}
|
||||
|
||||
private static double[] crossList(double[] r, int which) {
|
||||
double o = r[0], c = r[3], v = r[4];
|
||||
double[] out = new double[5];
|
||||
for (int j = 0; j < 5; j++) {
|
||||
out[j] = switch (which) {
|
||||
case 0 -> (c - o) + j;
|
||||
case 1 -> v + j * 10.0;
|
||||
case 2 -> j % 2 == 0 ? 1.0 : 0.0; // newHigh
|
||||
case 3 -> j % 3 == 0 ? 1.0 : 0.0; // newLow
|
||||
case 4 -> j % 2 == 0 ? 1.0 : 0.0; // aboveMa
|
||||
default -> j % 3 == 0 ? 1.0 : 0.0; // onBuySignal
|
||||
};
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] obList(double[] r, int which) {
|
||||
double c = r[3], v = r[4];
|
||||
double[] out = new double[5];
|
||||
for (int k = 0; k < 5; k++) {
|
||||
double kf = k + 1;
|
||||
out[k] = switch (which) {
|
||||
case 0 -> c - 0.1 * kf;
|
||||
case 1 -> v / kf;
|
||||
case 2 -> c + 0.1 * kf;
|
||||
default -> v * 0.9 / kf;
|
||||
};
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] flattenRecord(Object o) throws Exception {
|
||||
RecordComponent[] rc = o.getClass().getRecordComponents();
|
||||
List<Double> list = new ArrayList<>();
|
||||
for (RecordComponent c : rc) {
|
||||
Object v = c.getAccessor().invoke(o);
|
||||
if (v instanceof double[] arr) {
|
||||
for (double d : arr) list.add(d);
|
||||
} else if (v instanceof Number num) {
|
||||
list.add(num.doubleValue());
|
||||
}
|
||||
}
|
||||
double[] out = new double[list.size()];
|
||||
for (int i = 0; i < out.length; i++) out[i] = list.get(i);
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] flattenArray(Object arr) throws Exception {
|
||||
int len = Array.getLength(arr);
|
||||
List<Double> list = new ArrayList<>();
|
||||
for (int i = 0; i < len; i++) {
|
||||
for (double d : flattenRecord(Array.get(arr, i))) list.add(d);
|
||||
}
|
||||
double[] out = new double[list.size()];
|
||||
for (int i = 0; i < out.length; i++) out[i] = list.get(i);
|
||||
return out;
|
||||
}
|
||||
|
||||
private static Object construct(Spec s) throws Exception {
|
||||
Class<?> cls = Class.forName("org.wickra." + s.canonical());
|
||||
Constructor<?> ctor = cls.getConstructors()[0];
|
||||
Class<?>[] pt = ctor.getParameterTypes();
|
||||
Object[] args = new Object[pt.length];
|
||||
for (int i = 0; i < pt.length; i++) {
|
||||
double v = s.params()[i];
|
||||
if (pt[i] == int.class) args[i] = (int) Math.round(v);
|
||||
else if (pt[i] == long.class) args[i] = (long) Math.round(v);
|
||||
else args[i] = v;
|
||||
}
|
||||
return ctor.newInstance(args);
|
||||
}
|
||||
|
||||
private static Method updateMethod(Object ind) {
|
||||
for (Method m : ind.getClass().getMethods()) {
|
||||
if (m.getName().equals("update")) return m;
|
||||
}
|
||||
throw new IllegalStateException("no update on " + ind.getClass());
|
||||
}
|
||||
|
||||
private static double[] row(Spec s, Object ind, Method upd, double[] r, int i) throws Exception {
|
||||
double o = r[0], h = r[1], l = r[2], c = r[3], v = r[4];
|
||||
Object res = switch (s.arch()) {
|
||||
case "scalar_f64", "multi_f64" -> upd.invoke(ind, c);
|
||||
case "pairwise", "multi_pairwise" -> upd.invoke(ind, c, o);
|
||||
case "scalar_candle", "multi_candle", "profile_bins", "profile_pricebins" ->
|
||||
upd.invoke(ind, o, h, l, c, v, (long) i);
|
||||
case "trade" -> upd.invoke(ind, c, v, c >= o, (long) i);
|
||||
case "trademid" -> upd.invoke(ind, c, v, c >= o, (long) i, (h + l) / 2);
|
||||
case "ob" -> upd.invoke(ind, obList(r, 0), obList(r, 1), obList(r, 2), obList(r, 3));
|
||||
case "cross" -> upd.invoke(ind, crossList(r, 0), crossList(r, 1), crossList(r, 2),
|
||||
crossList(r, 3), crossList(r, 4), crossList(r, 5), (long) i);
|
||||
case "deriv", "deriv_multi" -> {
|
||||
double[] d = derivFields(r);
|
||||
yield upd.invoke(ind, d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], (long) i);
|
||||
}
|
||||
case "bars_close" -> upd.invoke(ind, c, c, c, c, 1.0, 0L);
|
||||
case "bars_candle4" -> upd.invoke(ind, o, h, l, c, 1.0, 0L);
|
||||
case "bars_candle5" -> upd.invoke(ind, o, h, l, c, v, 0L);
|
||||
case "footprint" -> upd.invoke(ind, c, v, c >= o, (long) i);
|
||||
default -> throw new IllegalStateException("arch " + s.arch());
|
||||
};
|
||||
return switch (s.arch()) {
|
||||
case "scalar_f64", "scalar_candle", "pairwise", "trade", "trademid", "ob", "cross", "deriv" ->
|
||||
new double[]{((Number) res).doubleValue()};
|
||||
case "multi_f64", "multi_candle", "multi_pairwise", "deriv_multi", "profile_pricebins" ->
|
||||
res == null ? nanRow(s.width()) : flattenRecord(res);
|
||||
case "profile_bins" -> res == null ? nanRow(s.width()) : (double[]) res;
|
||||
default -> flattenArray(res); // bars_*, footprint
|
||||
};
|
||||
}
|
||||
|
||||
@TestFactory
|
||||
List<DynamicTest> golden() throws Exception {
|
||||
double[][] rows = input();
|
||||
List<DynamicTest> tests = new ArrayList<>();
|
||||
for (Spec s : SPECS) {
|
||||
tests.add(dynamicTest(s.canonical(), () -> {
|
||||
Object ind = construct(s);
|
||||
Method upd = updateMethod(ind);
|
||||
double[][] exp = fixture(s.canonical());
|
||||
assertTrue(exp.length == rows.length, s.canonical() + ": row count " + exp.length + " vs " + rows.length);
|
||||
for (int i = 0; i < rows.length; i++) {
|
||||
double[] got = row(s, ind, upd, rows[i], i);
|
||||
double[] want = exp[i];
|
||||
assertTrue(got.length == want.length,
|
||||
s.canonical() + " row " + i + ": arity " + got.length + " vs " + want.length);
|
||||
for (int k = 0; k < want.length; k++) {
|
||||
double w = want[k], g = got[k];
|
||||
if (Double.isNaN(w)) {
|
||||
assertTrue(Double.isNaN(g), s.canonical() + " row " + i + " col " + k + ": want NaN got " + g);
|
||||
} else if (Double.isInfinite(w)) {
|
||||
assertTrue(Double.isInfinite(g) && Math.signum(g) == Math.signum(w),
|
||||
s.canonical() + " row " + i + " col " + k + ": want " + w + " got " + g);
|
||||
} else {
|
||||
double tol = TOL * Math.max(1.0, Math.abs(w));
|
||||
assertTrue(Math.abs(g - w) <= tol,
|
||||
s.canonical() + " row " + i + " col " + k + ": got " + g + " want " + w);
|
||||
}
|
||||
}
|
||||
}
|
||||
}));
|
||||
}
|
||||
return tests;
|
||||
}
|
||||
}
|
||||
'''
|
||||
|
||||
out = TEMPLATE.replace("%SPECS%", specs_block)
|
||||
dest = os.path.join(ROOT, "bindings", "java", "src", "test", "java", "org", "wickra", "GoldenAllTest.java")
|
||||
open(dest, "w", encoding="utf-8").write(out)
|
||||
print("generated GoldenAllTest.java with", len(MAN), "indicators")
|
||||
@@ -47,10 +47,10 @@ public final class AbsoluteBreadthIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_ABSOLUTE_BREADTH_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class AdVolumeLine implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_AD_VOLUME_LINE_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class AdvanceDecline implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_ADVANCE_DECLINE_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class AdvanceDeclineRatio implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_ADVANCE_DECLINE_RATIO_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -50,10 +50,10 @@ public final class BreadthThrust implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_BREADTH_THRUST_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class BullishPercentIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_BULLISH_PERCENT_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class CumulativeVolumeIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_CUMULATIVE_VOLUME_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -50,10 +50,10 @@ public final class HighLowIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_HIGH_LOW_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -25,7 +25,7 @@ public final class MacdExt implements AutoCloseable {
|
||||
}
|
||||
MemorySegment h;
|
||||
try {
|
||||
h = (MemorySegment) NativeMethods.WICKRA_MACD_EXT_NEW.invokeExact((long) fast, fastType, (long) slow, slowType, (long) signal, signalType);
|
||||
h = (MemorySegment) NativeMethods.WICKRA_MACD_EXT_NEW.invokeExact((long) fast, (byte) fastType, (long) slow, (byte) slowType, (long) signal, (byte) signalType);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
}
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class McClellanOscillator implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_MC_CLELLAN_OSCILLATOR_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class McClellanSummationIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_MC_CLELLAN_SUMMATION_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class NewHighsNewLows implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_NEW_HIGHS_NEW_LOWS_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class PercentAboveMa implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_PERCENT_ABOVE_MA_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class TickIndex implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_TICK_INDEX_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class Trin implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_TRIN_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -47,10 +47,10 @@ public final class UpDownVolumeRatio implements AutoCloseable {
|
||||
try (Arena a = Arena.ofConfined()) {
|
||||
MemorySegment changeSeg = a.allocateFrom(JAVA_DOUBLE, change);
|
||||
MemorySegment volumeSeg = a.allocateFrom(JAVA_DOUBLE, volume);
|
||||
MemorySegment newHighSeg = a.allocateFrom(JAVA_DOUBLE, newHigh);
|
||||
MemorySegment newLowSeg = a.allocateFrom(JAVA_DOUBLE, newLow);
|
||||
MemorySegment aboveMaSeg = a.allocateFrom(JAVA_DOUBLE, aboveMa);
|
||||
MemorySegment onBuySignalSeg = a.allocateFrom(JAVA_DOUBLE, onBuySignal);
|
||||
MemorySegment newHighSeg = WickraNative.boolSegment(a, newHigh);
|
||||
MemorySegment newLowSeg = WickraNative.boolSegment(a, newLow);
|
||||
MemorySegment aboveMaSeg = WickraNative.boolSegment(a, aboveMa);
|
||||
MemorySegment onBuySignalSeg = WickraNative.boolSegment(a, onBuySignal);
|
||||
return (double) NativeMethods.WICKRA_UP_DOWN_VOLUME_RATIO_UPDATE.invokeExact(handle, changeSeg, volumeSeg, newHighSeg, newLowSeg, aboveMaSeg, onBuySignalSeg, (long) change.length, timestamp);
|
||||
} catch (Throwable t) {
|
||||
throw WickraNative.rethrow(t);
|
||||
|
||||
@@ -58,6 +58,20 @@ public final class WickraNative {
|
||||
return CLEANER.register(owner, new FreeAction(handle, free));
|
||||
}
|
||||
|
||||
/**
|
||||
* Allocate a C {@code bool*} buffer (one byte per element) from flag values
|
||||
* supplied as doubles, treating any non-zero value as {@code true}. The C
|
||||
* ABI takes the cross-section state flags as {@code const bool*}, so they
|
||||
* must be one byte each rather than eight-byte doubles.
|
||||
*/
|
||||
public static MemorySegment boolSegment(Arena arena, double[] flags) {
|
||||
byte[] bytes = new byte[flags.length];
|
||||
for (int i = 0; i < flags.length; i++) {
|
||||
bytes[i] = (byte) (flags[i] != 0.0 ? 1 : 0);
|
||||
}
|
||||
return arena.allocateFrom(java.lang.foreign.ValueLayout.JAVA_BYTE, bytes);
|
||||
}
|
||||
|
||||
/** Re-throw a {@link MethodHandle#invokeExact} {@link Throwable} as an unchecked exception. */
|
||||
public static RuntimeException rethrow(Throwable t) {
|
||||
if (t instanceof RuntimeException re) {
|
||||
|
||||
@@ -0,0 +1,759 @@
|
||||
// Code generated by gen_golden_test.py. DO NOT EDIT.
|
||||
package org.wickra;
|
||||
|
||||
import org.junit.jupiter.api.DynamicTest;
|
||||
import org.junit.jupiter.api.TestFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.lang.reflect.Array;
|
||||
import java.lang.reflect.Constructor;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.RecordComponent;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
import static org.junit.jupiter.api.DynamicTest.dynamicTest;
|
||||
|
||||
/**
|
||||
* Reflection-driven value parity for the whole 514-indicator catalogue: each
|
||||
* indicator is reconstructed by its class name, fed the synthetic stream derived
|
||||
* from the shared golden input (identical to gen_golden's Rust construction) and
|
||||
* checked bit-for-bit against testdata/golden/g_<Canonical>.csv. One runner
|
||||
* flattens scalar, multi-output records, profiles and bar arrays by reflection.
|
||||
*/
|
||||
class GoldenAllTest {
|
||||
private static final double TOL = 1e-6;
|
||||
|
||||
private record Spec(String canonical, String arch, double[] params, int width) {}
|
||||
|
||||
private static final Spec[] SPECS = {
|
||||
new Spec("AbandonedBaby", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Abcd", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AbsoluteBreadthIndex", "cross", new double[]{}, 0),
|
||||
new Spec("AccelerationBands", "multi_candle", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("AcceleratorOscillator", "scalar_candle", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("AdOscillator", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AdVolumeLine", "cross", new double[]{}, 0),
|
||||
new Spec("AdaptiveCci", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("AdaptiveCycle", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("AdaptiveLaguerreFilter", "scalar_f64", new double[]{20.0}, 0),
|
||||
new Spec("AdaptiveRsi", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Adl", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AdvanceBlock", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AdvanceDecline", "cross", new double[]{}, 0),
|
||||
new Spec("AdvanceDeclineRatio", "cross", new double[]{}, 0),
|
||||
new Spec("Adx", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("Adxr", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Alligator", "multi_candle", new double[]{3.0, 7.0, 14.0}, 3),
|
||||
new Spec("Alma", "scalar_f64", new double[]{9.0, 0.85, 6.0}, 0),
|
||||
new Spec("Alpha", "pairwise", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("AmihudIlliquidity", "trade", new double[]{20.0}, 0),
|
||||
new Spec("AnchoredRsi", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("AnchoredVwap", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AndrewsPitchfork", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("Apo", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Aroon", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("AroonOscillator", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Atr", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("AtrBands", "multi_candle", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("AtrRatchet", "multi_candle", new double[]{14.0, 2.0, 0.5}, 2),
|
||||
new Spec("AtrTrailingStop", "scalar_candle", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("AutoFib", "multi_candle", new double[]{}, 7),
|
||||
new Spec("Autocorrelation", "scalar_f64", new double[]{10.0, 1.0}, 0),
|
||||
new Spec("AutocorrelationPeriodogram", "scalar_f64", new double[]{10.0, 48.0}, 0),
|
||||
new Spec("AverageDailyRange", "scalar_candle", new double[]{14.0, 0.0}, 0),
|
||||
new Spec("AverageDrawdown", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("AvgPrice", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("AwesomeOscillator", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("AwesomeOscillatorHistogram", "scalar_candle", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("BalanceOfPower", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("BandpassFilter", "scalar_f64", new double[]{20.0, 0.3}, 0),
|
||||
new Spec("Bat", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("BeltHold", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Beta", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("BetaNeutralSpread", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("BetterVolume", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("BipowerVariation", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("BodySizePct", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("BollingerBands", "multi_f64", new double[]{20.0, 2.0}, 4),
|
||||
new Spec("BollingerBandwidth", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("BomarBands", "multi_f64", new double[]{4.0, 0.85}, 3),
|
||||
new Spec("BreadthThrust", "cross", new double[]{10.0}, 0),
|
||||
new Spec("Breakaway", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("BullishPercentIndex", "cross", new double[]{}, 0),
|
||||
new Spec("BurkeRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Butterfly", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("CalendarSpread", "deriv", new double[]{}, 0),
|
||||
new Spec("CalmarRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Camarilla", "multi_candle", new double[]{}, 9),
|
||||
new Spec("CandleVolume", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("Cci", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("CenterOfGravity", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("CentralPivotRange", "multi_candle", new double[]{}, 3),
|
||||
new Spec("Cfo", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("ChaikinMoneyFlow", "scalar_candle", new double[]{20.0}, 0),
|
||||
new Spec("ChaikinOscillator", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("ChaikinVolatility", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("ChandeKrollStop", "multi_candle", new double[]{3.0, 2.0, 7.0}, 2),
|
||||
new Spec("ChandelierExit", "multi_candle", new double[]{14.0, 2.0}, 2),
|
||||
new Spec("ChoppinessIndex", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("ClassicPivots", "multi_candle", new double[]{}, 7),
|
||||
new Spec("CloseVsOpen", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ClosingMarubozu", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Cmo", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("CoefficientOfVariation", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Cointegration", "multi_pairwise", new double[]{40.0, 1.0}, 3),
|
||||
new Spec("CommonSenseRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("CompositeProfile", "multi_candle", new double[]{20.0, 24.0, 0.7}, 3),
|
||||
new Spec("ConcealingBabySwallow", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ConditionalValueAtRisk", "scalar_f64", new double[]{20.0, 0.95}, 0),
|
||||
new Spec("ConnorsRsi", "scalar_f64", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("Coppock", "scalar_f64", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("CorrelationTrendIndicator", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Counterattack", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Crab", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("CumulativeVolumeDelta", "trade", new double[]{}, 0),
|
||||
new Spec("CumulativeVolumeIndex", "cross", new double[]{}, 0),
|
||||
new Spec("CupAndHandle", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("CyberneticCycle", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Cypher", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("DayOfWeekProfile", "profile_bins", new double[]{0.0}, 7),
|
||||
new Spec("Decycler", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("DecyclerOscillator", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Dema", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("DemandIndex", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("DemarkPivots", "multi_candle", new double[]{}, 3),
|
||||
new Spec("DepthSlope", "ob", new double[]{}, 0),
|
||||
new Spec("DerivativeOscillator", "scalar_f64", new double[]{3.0, 7.0, 14.0, 28.0}, 0),
|
||||
new Spec("DetrendedStdDev", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("DisparityIndex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("DistanceSsd", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("Doji", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("DojiStar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("DollarBars", "bars_candle5", new double[]{50000.0}, 0),
|
||||
new Spec("Donchian", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("DonchianStop", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("DoubleBollinger", "multi_f64", new double[]{20.0, 1.0, 2.0}, 5),
|
||||
new Spec("DoubleTopBottom", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("DownsideGapThreeMethods", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Dpo", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("DragonflyDoji", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("DrawdownDuration", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("DumplingTop", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Dx", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("DynamicMomentumIndex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("EaseOfMovement", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("EffectiveSpread", "trademid", new double[]{}, 0),
|
||||
new Spec("EhlersStochastic", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Ehma", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("ElderImpulse", "scalar_f64", new double[]{3.0, 7.0, 14.0, 28.0}, 0),
|
||||
new Spec("ElderRay", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("ElderSafeZone", "multi_candle", new double[]{10.0, 2.0}, 2),
|
||||
new Spec("Ema", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("EmpiricalModeDecomposition", "scalar_f64", new double[]{20.0, 0.1}, 0),
|
||||
new Spec("Engulfing", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Equivolume", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("EstimatedLeverageRatio", "deriv", new double[]{}, 0),
|
||||
new Spec("EvenBetterSinewave", "scalar_f64", new double[]{40.0, 10.0}, 0),
|
||||
new Spec("EveningDojiStar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Evwma", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("EwmaVolatility", "scalar_f64", new double[]{0.94}, 0),
|
||||
new Spec("Expectancy", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("FallingThreeMethods", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Fama", "scalar_f64", new double[]{0.5, 0.05}, 0),
|
||||
new Spec("FibArcs", "multi_candle", new double[]{}, 3),
|
||||
new Spec("FibChannel", "multi_candle", new double[]{}, 4),
|
||||
new Spec("FibConfluence", "multi_candle", new double[]{}, 2),
|
||||
new Spec("FibExtension", "multi_candle", new double[]{}, 5),
|
||||
new Spec("FibFan", "multi_candle", new double[]{}, 3),
|
||||
new Spec("FibProjection", "multi_candle", new double[]{}, 4),
|
||||
new Spec("FibRetracement", "multi_candle", new double[]{}, 7),
|
||||
new Spec("FibTimeZones", "multi_candle", new double[]{}, 2),
|
||||
new Spec("FibonacciPivots", "multi_candle", new double[]{}, 7),
|
||||
new Spec("FisherRsi", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("FisherTransform", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("FlagPennant", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Footprint", "footprint", new double[]{1.0}, 0),
|
||||
new Spec("ForceIndex", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("FractalChaosBands", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("Frama", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("FryPanBottom", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("FundingBasis", "deriv", new double[]{}, 0),
|
||||
new Spec("FundingImpliedApr", "deriv", new double[]{1095.0}, 0),
|
||||
new Spec("FundingRate", "deriv", new double[]{}, 0),
|
||||
new Spec("FundingRateMean", "deriv", new double[]{20.0}, 0),
|
||||
new Spec("FundingRateZScore", "deriv", new double[]{20.0}, 0),
|
||||
new Spec("GainLossRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("GainToPainRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("GapSideBySideWhite", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Garch11", "scalar_f64", new double[]{2e-06, 0.1, 0.88}, 0),
|
||||
new Spec("GarmanKlassVolatility", "scalar_candle", new double[]{20.0, 252.0}, 0),
|
||||
new Spec("Gartley", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("GatorOscillator", "multi_candle", new double[]{3.0, 7.0, 14.0}, 2),
|
||||
new Spec("GeneralizedDema", "scalar_f64", new double[]{5.0, 0.7}, 0),
|
||||
new Spec("GeometricMa", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("GoldenPocket", "multi_candle", new double[]{}, 3),
|
||||
new Spec("GrangerCausality", "pairwise", new double[]{60.0, 1.0}, 0),
|
||||
new Spec("GravestoneDoji", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Hammer", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HangingMan", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Harami", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HaramiCross", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HasbrouckInformationShare", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("HeadAndShoulders", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HeikinAshi", "multi_candle", new double[]{}, 4),
|
||||
new Spec("HeikinAshiOscillator", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("HiLoActivator", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("HighLowIndex", "cross", new double[]{10.0}, 0),
|
||||
new Spec("HighLowRange", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HighLowVolumeNodes", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("HighWave", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HighpassFilter", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Hikkake", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HikkakeModified", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HilbertDominantCycle", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("HistoricalVolatility", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Hma", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("HoltWinters", "scalar_f64", new double[]{0.5, 0.1}, 0),
|
||||
new Spec("HomingPigeon", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("HtDcPhase", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("HtPhasor", "multi_f64", new double[]{}, 2),
|
||||
new Spec("HtTrendMode", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("HurstChannel", "multi_candle", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("HurstExponent", "scalar_f64", new double[]{100.0, 4.0}, 0),
|
||||
new Spec("Ichimoku", "multi_candle", new double[]{9.0, 26.0, 52.0, 26.0}, 5),
|
||||
new Spec("IdenticalThreeCrows", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ImbalanceBars", "bars_candle4", new double[]{5.0}, 0),
|
||||
new Spec("InNeck", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Inertia", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("InformationRatio", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("InitialBalance", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("InstantaneousTrendline", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("IntradayIntensity", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("IntradayMomentumIndex", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("IntradayVolatilityProfile", "profile_bins", new double[]{24.0, 0.0}, 24),
|
||||
new Spec("InverseFisherTransform", "scalar_f64", new double[]{2.0}, 0),
|
||||
new Spec("InvertedHammer", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("JarqueBera", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Jma", "scalar_f64", new double[]{7.0, 0.0, 2.0}, 0),
|
||||
new Spec("JumpIndicator", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("KRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("KagiBars", "bars_close", new double[]{2.0}, 0),
|
||||
new Spec("KalmanHedgeRatio", "multi_pairwise", new double[]{0.01, 0.001}, 3),
|
||||
new Spec("Kama", "scalar_f64", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("KaseDevStop", "multi_candle", new double[]{14.0, 2.0}, 2),
|
||||
new Spec("KasePermissionStochastic", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("KellyCriterion", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Keltner", "multi_candle", new double[]{3.0, 7.0, 2.0}, 3),
|
||||
new Spec("KendallTau", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("Kicking", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("KickingByLength", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Kst", "multi_f64", new double[]{3.0, 7.0, 14.0, 28.0, 35.0, 42.0, 56.0, 63.0, 70.0}, 2),
|
||||
new Spec("Kurtosis", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Kvo", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("KylesLambda", "trademid", new double[]{20.0}, 0),
|
||||
new Spec("LadderBottom", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("LaguerreRsi", "scalar_f64", new double[]{0.5}, 0),
|
||||
new Spec("LeadLagCrossCorrelation", "multi_pairwise", new double[]{20.0, 10.0}, 2),
|
||||
new Spec("LinRegAngle", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("LinRegChannel", "multi_f64", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("LinRegIntercept", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("LinRegSlope", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("LinearRegression", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("LiquidationFeatures", "deriv_multi", new double[]{}, 5),
|
||||
new Spec("LogReturn", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("LongLeggedDoji", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("LongLine", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("LongShortRatio", "deriv", new double[]{}, 0),
|
||||
new Spec("M2Measure", "scalar_f64", new double[]{14.0, 2.0, 0.5}, 0),
|
||||
new Spec("MaEnvelope", "multi_f64", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("MacdExt", "multi_f64", new double[]{12.0, 0.0, 26.0, 0.0, 9.0, 0.0}, 3),
|
||||
new Spec("MacdFix", "multi_f64", new double[]{9.0}, 3),
|
||||
new Spec("MacdHistogram", "scalar_f64", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("MacdIndicator", "multi_f64", new double[]{12.0, 26.0, 9.0}, 3),
|
||||
new Spec("Mama", "multi_f64", new double[]{0.5, 0.05}, 2),
|
||||
new Spec("MarketFacilitationIndex", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MartinRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Marubozu", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MassIndex", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("MatHold", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MatchingLow", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MaxDrawdown", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("McClellanOscillator", "cross", new double[]{}, 0),
|
||||
new Spec("McClellanSummationIndex", "cross", new double[]{}, 0),
|
||||
new Spec("McGinleyDynamic", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("MedianAbsoluteDeviation", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("MedianChannel", "multi_f64", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("MedianMa", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("MedianPrice", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Mfi", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Microprice", "ob", new double[]{}, 0),
|
||||
new Spec("MidPoint", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("MidPrice", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("MinusDi", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("MinusDm", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("ModifiedMaStop", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("Mom", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("MorningDojiStar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MorningEveningStar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("MurreyMathLines", "multi_candle", new double[]{14.0}, 9),
|
||||
new Spec("NakedPoc", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Natr", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("NewHighsNewLows", "cross", new double[]{}, 0),
|
||||
new Spec("NewPriceLines", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Nrtr", "multi_candle", new double[]{2.0}, 2),
|
||||
new Spec("Nvi", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("OIPriceDivergence", "deriv", new double[]{20.0}, 0),
|
||||
new Spec("OIWeighted", "deriv", new double[]{}, 0),
|
||||
new Spec("Obv", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("OiToVolumeRatio", "deriv", new double[]{}, 0),
|
||||
new Spec("OmegaRatio", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("OnNeck", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("OpenInterestDelta", "deriv", new double[]{}, 0),
|
||||
new Spec("OpenInterestMomentum", "deriv", new double[]{10.0}, 0),
|
||||
new Spec("OpeningMarubozu", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("OpeningRange", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("OrderBookImbalanceFull", "ob", new double[]{}, 0),
|
||||
new Spec("OrderBookImbalanceTop1", "ob", new double[]{}, 0),
|
||||
new Spec("OrderBookImbalanceTopN", "ob", new double[]{5.0}, 0),
|
||||
new Spec("OrderFlowImbalance", "ob", new double[]{20.0}, 0),
|
||||
new Spec("OuHalfLife", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("OvernightGap", "scalar_candle", new double[]{0.0}, 0),
|
||||
new Spec("OvernightIntradayReturn", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("PainIndex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("PairSpreadZScore", "pairwise", new double[]{20.0, 20.0}, 0),
|
||||
new Spec("PairwiseBeta", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("ParkinsonVolatility", "scalar_candle", new double[]{20.0, 252.0}, 0),
|
||||
new Spec("PearsonCorrelation", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("PercentAboveMa", "cross", new double[]{}, 0),
|
||||
new Spec("PercentB", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("PercentageTrailingStop", "scalar_f64", new double[]{2.0}, 0),
|
||||
new Spec("PerpetualPremiumIndex", "deriv", new double[]{}, 0),
|
||||
new Spec("Pgo", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("PiercingDarkCloud", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Pin", "trade", new double[]{20.0}, 0),
|
||||
new Spec("PivotReversal", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("PlusDi", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("PlusDm", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Pmo", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("PointAndFigureBars", "bars_close", new double[]{2.0, 3.0}, 0),
|
||||
new Spec("PolarizedFractalEfficiency", "scalar_f64", new double[]{10.0, 5.0}, 0),
|
||||
new Spec("Ppo", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("PpoHistogram", "scalar_f64", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("ProfileShape", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("ProfitFactor", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("ProjectionBands", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("ProjectionOscillator", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Psar", "scalar_candle", new double[]{0.02, 0.02, 0.2}, 0),
|
||||
new Spec("Pvi", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Qqe", "multi_f64", new double[]{3.0, 7.0, 2.0}, 2),
|
||||
new Spec("Qstick", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("QuartileBands", "multi_f64", new double[]{14.0}, 3),
|
||||
new Spec("QuotedSpread", "ob", new double[]{}, 0),
|
||||
new Spec("RSquared", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RangeBars", "bars_close", new double[]{2.0}, 0),
|
||||
new Spec("RealizedSpread", "trademid", new double[]{20.0}, 0),
|
||||
new Spec("RealizedVolatility", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RecoveryFactor", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("RectangleRange", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Reflex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RegimeLabel", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("RelativeStrengthAB", "multi_pairwise", new double[]{14.0, 14.0}, 3),
|
||||
new Spec("RenkoBars", "bars_close", new double[]{2.0}, 0),
|
||||
new Spec("RenkoTrailingStop", "scalar_f64", new double[]{2.0}, 0),
|
||||
new Spec("RickshawMan", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("RisingThreeMethods", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Rmi", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Roc", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Rocp", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Rocr", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Rocr100", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RogersSatchellVolatility", "scalar_candle", new double[]{20.0, 252.0}, 0),
|
||||
new Spec("RollMeasure", "trade", new double[]{20.0}, 0),
|
||||
new Spec("RollingCorrelation", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("RollingCovariance", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("RollingIqr", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RollingMinMaxScaler", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RollingPercentileRank", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RollingQuantile", "scalar_f64", new double[]{20.0, 0.5}, 0),
|
||||
new Spec("RollingVwap", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("RoofingFilter", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Rsi", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Rsx", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("RunBars", "bars_candle4", new double[]{3.0}, 0),
|
||||
new Spec("Rvi", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("RviVolatility", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Rwi", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("SampleEntropy", "scalar_f64", new double[]{20.0, 2.0, 0.2}, 0),
|
||||
new Spec("SarExt", "scalar_candle", new double[]{2.0, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5}, 0),
|
||||
new Spec("SeasonalZScore", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("SeparatingLines", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("SessionHighLow", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("SessionRange", "multi_candle", new double[]{14.0}, 3),
|
||||
new Spec("SessionVwap", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("ShannonEntropy", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Shark", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("SharpeRatio", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("ShootingStar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ShortLine", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("SignedVolume", "trade", new double[]{}, 0),
|
||||
new Spec("SineWave", "scalar_f64", new double[]{}, 0),
|
||||
new Spec("SineWeightedMa", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("SinglePrints", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Skewness", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Sma", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Smi", "scalar_candle", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("Smma", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("SmoothedHeikinAshi", "multi_candle", new double[]{14.0}, 4),
|
||||
new Spec("SortinoRatio", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("SpearmanCorrelation", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("SpinningTop", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("SpreadAr1Coefficient", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("SpreadBollingerBands", "multi_pairwise", new double[]{14.0, 2.0}, 4),
|
||||
new Spec("SpreadHurst", "pairwise", new double[]{14.0}, 0),
|
||||
new Spec("StalledPattern", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("StandardError", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("StandardErrorBands", "multi_f64", new double[]{14.0, 2.0}, 3),
|
||||
new Spec("StarcBands", "multi_candle", new double[]{3.0, 7.0, 2.0}, 3),
|
||||
new Spec("Stc", "scalar_f64", new double[]{10.0, 23.0, 10.0, 0.5}, 0),
|
||||
new Spec("StdDev", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("StepTrailingStop", "scalar_f64", new double[]{2.0}, 0),
|
||||
new Spec("SterlingRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("StickSandwich", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("StochRsi", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Stochastic", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("StochasticCci", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("SuperSmoother", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("SuperTrend", "multi_candle", new double[]{14.0, 2.0}, 2),
|
||||
new Spec("T3", "scalar_f64", new double[]{5.0, 0.7}, 0),
|
||||
new Spec("TailRatio", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TakerBuySellRatio", "deriv", new double[]{}, 0),
|
||||
new Spec("Takuri", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TasukiGap", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdCamouflage", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdClop", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdClopwin", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdCombo", "scalar_candle", new double[]{3.0, 7.0, 14.0, 28.0}, 0),
|
||||
new Spec("TdCountdown", "scalar_candle", new double[]{3.0, 7.0, 14.0, 28.0}, 0),
|
||||
new Spec("TdDWave", "scalar_candle", new double[]{2.0}, 0),
|
||||
new Spec("TdDeMarker", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TdDifferential", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdLines", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("TdMovingAverage", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("TdOpen", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdPressure", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TdPropulsion", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TdRangeProjection", "multi_candle", new double[]{}, 2),
|
||||
new Spec("TdRei", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TdRiskLevel", "multi_candle", new double[]{3.0, 7.0}, 2),
|
||||
new Spec("TdSequential", "multi_candle", new double[]{3.0, 7.0, 14.0, 28.0}, 3),
|
||||
new Spec("TdSetup", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("TdTrap", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Tema", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TermStructureBasis", "deriv", new double[]{}, 0),
|
||||
new Spec("ThreeDrives", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ThreeInside", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ThreeLineBreak", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("ThreeLineBreakBars", "bars_close", new double[]{3.0}, 0),
|
||||
new Spec("ThreeLineStrike", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ThreeOutside", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ThreeSoldiersOrCrows", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("ThreeStarsInSouth", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Thrusting", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TickBars", "bars_candle5", new double[]{2.0}, 0),
|
||||
new Spec("TickIndex", "cross", new double[]{}, 0),
|
||||
new Spec("Tii", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("TimeBasedStop", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TimeOfDayReturnProfile", "profile_bins", new double[]{24.0, 0.0}, 24),
|
||||
new Spec("TowerTopBottom", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TpoProfile", "profile_pricebins", new double[]{30.0, 50.0}, 52),
|
||||
new Spec("TradeImbalance", "trade", new double[]{20.0}, 0),
|
||||
new Spec("TradeSignAutocorrelation", "trade", new double[]{20.0}, 0),
|
||||
new Spec("TradeVolumeIndex", "scalar_candle", new double[]{2.0}, 0),
|
||||
new Spec("TrendLabel", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TrendStrengthIndex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Trendflex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TreynorRatio", "pairwise", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("Triangle", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Trima", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Trin", "cross", new double[]{}, 0),
|
||||
new Spec("TripleTopBottom", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Tristar", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Trix", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TrueRange", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("Tsf", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("TsfOscillator", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Tsi", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("Tsv", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TtmSqueeze", "multi_candle", new double[]{14.0, 2.0, 0.5}, 2),
|
||||
new Spec("TtmTrend", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TurnOfMonth", "scalar_candle", new double[]{3.0, 3.0, 0.0}, 0),
|
||||
new Spec("Tweezer", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TwiggsMoneyFlow", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("TwoCrows", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("TypicalPrice", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("UlcerIndex", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("UltimateOscillator", "scalar_candle", new double[]{3.0, 7.0, 14.0}, 0),
|
||||
new Spec("UniqueThreeRiver", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("UniversalOscillator", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("UpDownVolumeRatio", "cross", new double[]{}, 0),
|
||||
new Spec("UpsideGapThreeMethods", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("UpsideGapTwoCrows", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("UpsidePotentialRatio", "scalar_f64", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("ValueArea", "multi_candle", new double[]{20.0, 50.0, 0.7}, 3),
|
||||
new Spec("ValueAtRisk", "scalar_f64", new double[]{20.0, 0.95}, 0),
|
||||
new Spec("Variance", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("VarianceRatio", "pairwise", new double[]{60.0, 2.0}, 0),
|
||||
new Spec("VerticalHorizontalFilter", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Vidya", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("VolatilityCone", "multi_candle", new double[]{3.0, 7.0}, 5),
|
||||
new Spec("VolatilityOfVolatility", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("VolatilityRatio", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("VoltyStop", "scalar_candle", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("VolumeBars", "bars_candle5", new double[]{500.0}, 0),
|
||||
new Spec("VolumeByTimeProfile", "profile_bins", new double[]{24.0, 0.0}, 24),
|
||||
new Spec("VolumeOscillator", "scalar_candle", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("VolumePriceTrend", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("VolumeProfile", "profile_pricebins", new double[]{20.0, 50.0}, 52),
|
||||
new Spec("VolumeRsi", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("VolumeWeightedMacd", "multi_candle", new double[]{3.0, 7.0, 14.0}, 3),
|
||||
new Spec("VolumeWeightedSr", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("Vortex", "multi_candle", new double[]{14.0}, 2),
|
||||
new Spec("Vpin", "trade", new double[]{5000.0, 10.0}, 0),
|
||||
new Spec("Vwap", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("VwapStdDevBands", "multi_candle", new double[]{2.0}, 4),
|
||||
new Spec("Vwma", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Vzo", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("Wad", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("WavePm", "scalar_f64", new double[]{3.0, 7.0}, 0),
|
||||
new Spec("WaveTrend", "multi_candle", new double[]{3.0, 7.0, 14.0}, 2),
|
||||
new Spec("Wedge", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("WeightedClose", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("WickRatio", "scalar_candle", new double[]{}, 0),
|
||||
new Spec("WilliamsFractals", "multi_candle", new double[]{}, 2),
|
||||
new Spec("WilliamsR", "scalar_candle", new double[]{14.0}, 0),
|
||||
new Spec("WinRate", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("Wma", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("WoodiePivots", "multi_candle", new double[]{}, 5),
|
||||
new Spec("YangZhangVolatility", "scalar_candle", new double[]{20.0, 252.0}, 0),
|
||||
new Spec("YoyoExit", "scalar_candle", new double[]{14.0, 2.0}, 0),
|
||||
new Spec("ZScore", "scalar_f64", new double[]{14.0}, 0),
|
||||
new Spec("ZeroLagMacd", "multi_f64", new double[]{3.0, 7.0, 14.0}, 3),
|
||||
new Spec("ZigZag", "multi_candle", new double[]{0.02}, 2),
|
||||
new Spec("Zlema", "scalar_f64", new double[]{14.0}, 0),
|
||||
};
|
||||
|
||||
private static Path goldenDir() {
|
||||
java.io.File d = new java.io.File("").getAbsoluteFile();
|
||||
while (d != null) {
|
||||
java.io.File g = new java.io.File(d, "testdata/golden");
|
||||
if (g.isDirectory()) {
|
||||
return g.toPath();
|
||||
}
|
||||
d = d.getParentFile();
|
||||
}
|
||||
throw new IllegalStateException("testdata/golden not found");
|
||||
}
|
||||
|
||||
private static double cell(String s) {
|
||||
return switch (s) {
|
||||
case "nan" -> Double.NaN;
|
||||
case "inf" -> Double.POSITIVE_INFINITY;
|
||||
case "-inf" -> Double.NEGATIVE_INFINITY;
|
||||
default -> Double.parseDouble(s);
|
||||
};
|
||||
}
|
||||
|
||||
private static double[][] input() throws IOException {
|
||||
List<String> lines = Files.readAllLines(goldenDir().resolve("input.csv"));
|
||||
List<double[]> rows = new ArrayList<>();
|
||||
for (int i = 1; i < lines.size(); i++) {
|
||||
if (lines.get(i).isEmpty()) continue;
|
||||
String[] p = lines.get(i).split(",");
|
||||
double[] r = new double[p.length];
|
||||
for (int j = 0; j < p.length; j++) r[j] = Double.parseDouble(p[j]);
|
||||
rows.add(r);
|
||||
}
|
||||
return rows.toArray(new double[0][]);
|
||||
}
|
||||
|
||||
// Keep blank lines (a candle on which no bar closed) so rows stay aligned.
|
||||
private static double[][] fixture(String name) throws IOException {
|
||||
List<String> lines = Files.readAllLines(goldenDir().resolve("g_" + name + ".csv"));
|
||||
List<double[]> rows = new ArrayList<>();
|
||||
for (int i = 1; i < lines.size(); i++) {
|
||||
String ln = lines.get(i);
|
||||
if (ln.isEmpty()) {
|
||||
rows.add(new double[0]);
|
||||
continue;
|
||||
}
|
||||
String[] p = ln.split(",");
|
||||
double[] r = new double[p.length];
|
||||
for (int j = 0; j < p.length; j++) r[j] = cell(p[j]);
|
||||
rows.add(r);
|
||||
}
|
||||
return rows.toArray(new double[0][]);
|
||||
}
|
||||
|
||||
private static double[] nanRow(int n) {
|
||||
double[] r = new double[n];
|
||||
java.util.Arrays.fill(r, Double.NaN);
|
||||
return r;
|
||||
}
|
||||
|
||||
private static double[] derivFields(double[] r) {
|
||||
double o = r[0], h = r[1], l = r[2], c = r[3], v = r[4];
|
||||
return new double[]{
|
||||
(c - o) / c * 0.01, c, c - 0.5, c + 1.0, v * 10.0, v * 0.6, v * 0.4,
|
||||
v * 0.55, v * 0.45, h - c, c - l,
|
||||
};
|
||||
}
|
||||
|
||||
private static double[] crossList(double[] r, int which) {
|
||||
double o = r[0], c = r[3], v = r[4];
|
||||
double[] out = new double[5];
|
||||
for (int j = 0; j < 5; j++) {
|
||||
out[j] = switch (which) {
|
||||
case 0 -> (c - o) + j;
|
||||
case 1 -> v + j * 10.0;
|
||||
case 2 -> j % 2 == 0 ? 1.0 : 0.0; // newHigh
|
||||
case 3 -> j % 3 == 0 ? 1.0 : 0.0; // newLow
|
||||
case 4 -> j % 2 == 0 ? 1.0 : 0.0; // aboveMa
|
||||
default -> j % 3 == 0 ? 1.0 : 0.0; // onBuySignal
|
||||
};
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] obList(double[] r, int which) {
|
||||
double c = r[3], v = r[4];
|
||||
double[] out = new double[5];
|
||||
for (int k = 0; k < 5; k++) {
|
||||
double kf = k + 1;
|
||||
out[k] = switch (which) {
|
||||
case 0 -> c - 0.1 * kf;
|
||||
case 1 -> v / kf;
|
||||
case 2 -> c + 0.1 * kf;
|
||||
default -> v * 0.9 / kf;
|
||||
};
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] flattenRecord(Object o) throws Exception {
|
||||
RecordComponent[] rc = o.getClass().getRecordComponents();
|
||||
List<Double> list = new ArrayList<>();
|
||||
for (RecordComponent c : rc) {
|
||||
Object v = c.getAccessor().invoke(o);
|
||||
if (v instanceof double[] arr) {
|
||||
for (double d : arr) list.add(d);
|
||||
} else if (v instanceof Number num) {
|
||||
list.add(num.doubleValue());
|
||||
}
|
||||
}
|
||||
double[] out = new double[list.size()];
|
||||
for (int i = 0; i < out.length; i++) out[i] = list.get(i);
|
||||
return out;
|
||||
}
|
||||
|
||||
private static double[] flattenArray(Object arr) throws Exception {
|
||||
int len = Array.getLength(arr);
|
||||
List<Double> list = new ArrayList<>();
|
||||
for (int i = 0; i < len; i++) {
|
||||
for (double d : flattenRecord(Array.get(arr, i))) list.add(d);
|
||||
}
|
||||
double[] out = new double[list.size()];
|
||||
for (int i = 0; i < out.length; i++) out[i] = list.get(i);
|
||||
return out;
|
||||
}
|
||||
|
||||
private static Object construct(Spec s) throws Exception {
|
||||
Class<?> cls = Class.forName("org.wickra." + s.canonical());
|
||||
Constructor<?> ctor = cls.getConstructors()[0];
|
||||
Class<?>[] pt = ctor.getParameterTypes();
|
||||
Object[] args = new Object[pt.length];
|
||||
for (int i = 0; i < pt.length; i++) {
|
||||
double v = s.params()[i];
|
||||
if (pt[i] == int.class) args[i] = (int) Math.round(v);
|
||||
else if (pt[i] == long.class) args[i] = (long) Math.round(v);
|
||||
else args[i] = v;
|
||||
}
|
||||
return ctor.newInstance(args);
|
||||
}
|
||||
|
||||
private static Method updateMethod(Object ind) {
|
||||
for (Method m : ind.getClass().getMethods()) {
|
||||
if (m.getName().equals("update")) return m;
|
||||
}
|
||||
throw new IllegalStateException("no update on " + ind.getClass());
|
||||
}
|
||||
|
||||
private static double[] row(Spec s, Object ind, Method upd, double[] r, int i) throws Exception {
|
||||
double o = r[0], h = r[1], l = r[2], c = r[3], v = r[4];
|
||||
Object res = switch (s.arch()) {
|
||||
case "scalar_f64", "multi_f64" -> upd.invoke(ind, c);
|
||||
case "pairwise", "multi_pairwise" -> upd.invoke(ind, c, o);
|
||||
case "scalar_candle", "multi_candle", "profile_bins", "profile_pricebins" ->
|
||||
upd.invoke(ind, o, h, l, c, v, (long) i);
|
||||
case "trade" -> upd.invoke(ind, c, v, c >= o, (long) i);
|
||||
case "trademid" -> upd.invoke(ind, c, v, c >= o, (long) i, (h + l) / 2);
|
||||
case "ob" -> upd.invoke(ind, obList(r, 0), obList(r, 1), obList(r, 2), obList(r, 3));
|
||||
case "cross" -> upd.invoke(ind, crossList(r, 0), crossList(r, 1), crossList(r, 2),
|
||||
crossList(r, 3), crossList(r, 4), crossList(r, 5), (long) i);
|
||||
case "deriv", "deriv_multi" -> {
|
||||
double[] d = derivFields(r);
|
||||
yield upd.invoke(ind, d[0], d[1], d[2], d[3], d[4], d[5], d[6], d[7], d[8], d[9], d[10], (long) i);
|
||||
}
|
||||
case "bars_close" -> upd.invoke(ind, c, c, c, c, 1.0, 0L);
|
||||
case "bars_candle4" -> upd.invoke(ind, o, h, l, c, 1.0, 0L);
|
||||
case "bars_candle5" -> upd.invoke(ind, o, h, l, c, v, 0L);
|
||||
case "footprint" -> upd.invoke(ind, c, v, c >= o, (long) i);
|
||||
default -> throw new IllegalStateException("arch " + s.arch());
|
||||
};
|
||||
return switch (s.arch()) {
|
||||
case "scalar_f64", "scalar_candle", "pairwise", "trade", "trademid", "ob", "cross", "deriv" ->
|
||||
new double[]{((Number) res).doubleValue()};
|
||||
case "multi_f64", "multi_candle", "multi_pairwise", "deriv_multi", "profile_pricebins" ->
|
||||
res == null ? nanRow(s.width()) : flattenRecord(res);
|
||||
case "profile_bins" -> res == null ? nanRow(s.width()) : (double[]) res;
|
||||
default -> flattenArray(res); // bars_*, footprint
|
||||
};
|
||||
}
|
||||
|
||||
@TestFactory
|
||||
List<DynamicTest> golden() throws Exception {
|
||||
double[][] rows = input();
|
||||
List<DynamicTest> tests = new ArrayList<>();
|
||||
for (Spec s : SPECS) {
|
||||
tests.add(dynamicTest(s.canonical(), () -> {
|
||||
Object ind = construct(s);
|
||||
Method upd = updateMethod(ind);
|
||||
double[][] exp = fixture(s.canonical());
|
||||
assertTrue(exp.length == rows.length, s.canonical() + ": row count " + exp.length + " vs " + rows.length);
|
||||
for (int i = 0; i < rows.length; i++) {
|
||||
double[] got = row(s, ind, upd, rows[i], i);
|
||||
double[] want = exp[i];
|
||||
assertTrue(got.length == want.length,
|
||||
s.canonical() + " row " + i + ": arity " + got.length + " vs " + want.length);
|
||||
for (int k = 0; k < want.length; k++) {
|
||||
double w = want[k], g = got[k];
|
||||
if (Double.isNaN(w)) {
|
||||
assertTrue(Double.isNaN(g), s.canonical() + " row " + i + " col " + k + ": want NaN got " + g);
|
||||
} else if (Double.isInfinite(w)) {
|
||||
assertTrue(Double.isInfinite(g) && Math.signum(g) == Math.signum(w),
|
||||
s.canonical() + " row " + i + " col " + k + ": want " + w + " got " + g);
|
||||
} else {
|
||||
double tol = TOL * Math.max(1.0, Math.abs(w));
|
||||
assertTrue(Math.abs(g - w) <= tol,
|
||||
s.canonical() + " row " + i + " col " + k + ": got " + g + " want " + w);
|
||||
}
|
||||
}
|
||||
}
|
||||
}));
|
||||
}
|
||||
return tests;
|
||||
}
|
||||
}
|
||||
@@ -157,4 +157,51 @@ class GoldenTests {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// The four de-duplicated indicators, pinned against the Rust reference.
|
||||
|
||||
@Test
|
||||
void adOscillatorMatchesGolden() throws Exception {
|
||||
double[][] in = input();
|
||||
List<String[]> e = readCsv("ad_oscillator");
|
||||
try (AdOscillator ad = new AdOscillator()) {
|
||||
for (int i = 0; i < in.length; i++) {
|
||||
close(ad.update(in[i][0], in[i][1], in[i][2], in[i][3], in[i][4], i), cell(e.get(i)[0]), i, "ad_oscillator");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void intradayIntensityMatchesGolden() throws Exception {
|
||||
double[][] in = input();
|
||||
List<String[]> e = readCsv("intraday_intensity");
|
||||
try (IntradayIntensity ii = new IntradayIntensity()) {
|
||||
for (int i = 0; i < in.length; i++) {
|
||||
close(ii.update(in[i][0], in[i][1], in[i][2], in[i][3], in[i][4], i), cell(e.get(i)[0]), i, "intraday_intensity");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void awesomeOscillatorHistogramMatchesGolden() throws Exception {
|
||||
double[][] in = input();
|
||||
List<String[]> e = readCsv("awesome_oscillator_histogram");
|
||||
try (AwesomeOscillatorHistogram aoh = new AwesomeOscillatorHistogram(5, 34, 1)) {
|
||||
for (int i = 0; i < in.length; i++) {
|
||||
close(aoh.update(in[i][0], in[i][1], in[i][2], in[i][3], in[i][4], i), cell(e.get(i)[0]), i, "awesome_oscillator_histogram");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void averageDrawdownMatchesGolden() throws Exception {
|
||||
double[][] in = input();
|
||||
List<String[]> e = readCsv("average_drawdown");
|
||||
try (AverageDrawdown avg = new AverageDrawdown(20)) {
|
||||
for (int i = 0; i < in.length; i++) {
|
||||
// generator fed the close column as the equity-curve sample.
|
||||
close(avg.update(in[i][3]), cell(e.get(i)[0]), i, "average_drawdown");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,122 @@
|
||||
"""Build node_manifest.json: for every one of the 514 indicators, record the
|
||||
native class name, constructor parameter values, the ordered update argument
|
||||
names (parsed from index.d.ts, each flagged scalar/array) and how to read its
|
||||
output against the shared g_<Canonical>.csv fixtures. Run from repo root."""
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", "..", ".."))
|
||||
DTS = os.path.join(ROOT, "bindings", "node", "index.d.ts")
|
||||
GOLDEN = os.path.join(ROOT, "testdata", "golden")
|
||||
|
||||
|
||||
def camel(snake):
|
||||
head, *rest = snake.split("_")
|
||||
return head + "".join(p[:1].upper() + p[1:] for p in rest)
|
||||
|
||||
|
||||
def parse_args(sig):
|
||||
out = []
|
||||
for p in sig.split(","):
|
||||
p = p.strip()
|
||||
if not p:
|
||||
continue
|
||||
name = p.split(":")[0].strip().rstrip("?")
|
||||
typ = p.split(":", 1)[1].strip() if ":" in p else ""
|
||||
out.append({"name": name, "array": "Array" in typ})
|
||||
return out
|
||||
|
||||
|
||||
dts = open(DTS, encoding="utf-8").read()
|
||||
node_upd = {}
|
||||
for name, body in re.findall(r"export declare class (\w+) \{(.*?)\n\}", dts, re.S):
|
||||
um = re.search(r"\bupdate\(([^)]*)\)", body)
|
||||
node_upd[name] = parse_args(um.group(1)) if um else []
|
||||
|
||||
# constructor params: reuse the values pinned in the Python-side manifests.
|
||||
params = {}
|
||||
for fn in ("scalar_manifest", "multi_manifest"):
|
||||
for e in json.load(open(os.path.join(GOLDEN, fn + ".json"))):
|
||||
params[e["native"]] = e["params"]
|
||||
for fam in json.load(open(os.path.join(GOLDEN, "exotic_manifest.json"))).values():
|
||||
for e in fam:
|
||||
params[e["native"]] = e["params"]
|
||||
for e in json.load(open(os.path.join(GOLDEN, "profile_manifest.json"))):
|
||||
params[e["native"]] = e["params"]
|
||||
for e in json.load(open(os.path.join(GOLDEN, "bars_manifest.json"))):
|
||||
params[e["native"]] = e["params"]
|
||||
|
||||
# the 11 hand-written archetypes (separate, non-g_ fixtures) keep their own test;
|
||||
# everything else is g_<Canonical>.csv. Output shape per native:
|
||||
multi_specs = {e["native"]: e for e in json.load(open(os.path.join(GOLDEN, "multi_manifest.json")))}
|
||||
deriv_multi = {e["native"]: e for e in json.load(open(os.path.join(GOLDEN, "exotic_manifest.json")))["deriv"] if "n" in e}
|
||||
profile_specs = {e["native"]: e for e in json.load(open(os.path.join(GOLDEN, "profile_manifest.json")))}
|
||||
bars_specs = {e["native"]: e for e in json.load(open(os.path.join(GOLDEN, "bars_manifest.json")))}
|
||||
|
||||
# bar output field order (camelCase), mirroring gen_golden's per-bar tuple.
|
||||
BAR_FIELDS = {
|
||||
"RenkoBars": ["open", "close", "direction"],
|
||||
"KagiBars": ["start", "end", "direction"],
|
||||
"PointAndFigureBars": ["direction", "high", "low"],
|
||||
"RangeBars": ["open", "close", "direction"],
|
||||
"ThreeLineBreakBars": ["open", "close", "direction"],
|
||||
"ImbalanceBars": ["open", "high", "low", "close", "imbalance", "direction"],
|
||||
"RunBars": ["open", "high", "low", "close", "length", "direction"],
|
||||
"DollarBars": ["open", "high", "low", "close", "volume", "dollar"],
|
||||
"TickBars": ["open", "high", "low", "close", "volume"],
|
||||
"VolumeBars": ["open", "high", "low", "close", "volume"],
|
||||
"Footprint": ["price", "bidVol", "askVol"],
|
||||
}
|
||||
|
||||
|
||||
def header_fields(canon):
|
||||
with open(os.path.join(GOLDEN, "g_" + canon + ".csv"), encoding="utf-8") as f:
|
||||
return f.readline().strip().split(",")
|
||||
|
||||
|
||||
# canonical -> native, gathered from every Python-side manifest. The g_ fixture
|
||||
# is named by canonical (the Rust struct); the Node class is the native alias.
|
||||
canon_native = {}
|
||||
for fn in ("scalar_manifest", "multi_manifest"):
|
||||
for e in json.load(open(os.path.join(GOLDEN, fn + ".json"))):
|
||||
canon_native[e["canonical"]] = e["native"]
|
||||
for fam in json.load(open(os.path.join(GOLDEN, "exotic_manifest.json"))).values():
|
||||
for e in fam:
|
||||
canon_native[e["canonical"]] = e["native"]
|
||||
for e in json.load(open(os.path.join(GOLDEN, "profile_manifest.json"))):
|
||||
canon_native[e["canonical"]] = e["native"]
|
||||
for e in json.load(open(os.path.join(GOLDEN, "bars_manifest.json"))):
|
||||
canon_native[e["canonical"]] = e["native"]
|
||||
|
||||
out = []
|
||||
for canon in sorted(canon_native):
|
||||
native = canon_native[canon]
|
||||
if native not in node_upd:
|
||||
raise SystemExit(f"node class for {canon} (native {native}) not found in index.d.ts")
|
||||
ctor = params.get(native, [])
|
||||
# EaseOfMovement's volume divisor is an optional Rust constructor argument
|
||||
# (default 1e8) but a required Node constructor parameter; pass it explicitly.
|
||||
if native == "EaseOfMovement":
|
||||
ctor = [ctor[0], 100000000.0]
|
||||
entry = {"canonical": canon, "native": native, "ctor": ctor, "args": node_upd[native]}
|
||||
if native in bars_specs:
|
||||
entry["out"] = "footprint" if native == "Footprint" else "bars"
|
||||
entry["fields"] = BAR_FIELDS[native]
|
||||
elif native in profile_specs:
|
||||
ps = profile_specs[native]
|
||||
entry["out"] = "profile_" + ps["kind"]
|
||||
entry["width"] = ps["width"]
|
||||
if ps["kind"] == "pricebins":
|
||||
entry["arrayField"] = "counts" if native == "TpoProfile" else "bins"
|
||||
elif native in deriv_multi or native in multi_specs:
|
||||
entry["out"] = "multi"
|
||||
entry["fields"] = [camel(c) for c in header_fields(canon)]
|
||||
else:
|
||||
entry["out"] = "scalar"
|
||||
out.append(entry)
|
||||
|
||||
json.dump(out, open(os.path.join(GOLDEN, "node_manifest.json"), "w"), indent=1)
|
||||
print("node_manifest entries:", len(out))
|
||||
from collections import Counter
|
||||
print(Counter(e["out"] for e in out))
|
||||
@@ -0,0 +1,195 @@
|
||||
// Generic golden-fixture parity for the Node binding.
|
||||
//
|
||||
// Every one of the 514 indicators is reconstructed from `node_manifest.json`
|
||||
// (native class, constructor params, ordered update args), fed the synthetic
|
||||
// stream derived from the shared `testdata/golden/input.csv` — the exact same
|
||||
// construction the Rust `gen_golden` binary uses — and checked bit-for-bit
|
||||
// against the Rust-generated `g_<Canonical>.csv`. This pins the Node FFI to the
|
||||
// Rust reference for the whole indicator catalogue, not just a few archetypes.
|
||||
//
|
||||
// cd bindings/node && npm run build && npm test
|
||||
|
||||
const test = require('node:test');
|
||||
const assert = require('node:assert/strict');
|
||||
const fs = require('node:fs');
|
||||
const path = require('node:path');
|
||||
const wickra = require('..');
|
||||
|
||||
const GOLDEN = path.resolve(__dirname, '..', '..', '..', 'testdata', 'golden');
|
||||
|
||||
function cell(s) {
|
||||
if (s === 'nan') return NaN;
|
||||
if (s === 'inf') return Infinity;
|
||||
if (s === '-inf') return -Infinity;
|
||||
return Number(s);
|
||||
}
|
||||
|
||||
function readCsv(name) {
|
||||
// Split on \r?\n so a CRLF checkout (Windows core.autocrlf) parses identically
|
||||
// to LF — otherwise `cell('inf\r')` falls through to Number() and becomes NaN.
|
||||
const lines = fs.readFileSync(path.join(GOLDEN, name + '.csv'), 'utf8').split(/\r?\n/);
|
||||
lines.shift(); // header
|
||||
return lines.filter((l) => l.length > 0).map((l) => l.split(',').map(cell));
|
||||
}
|
||||
|
||||
// Bars keep blank lines (one row per candle, blank == no bar closed).
|
||||
function readBarRows(name) {
|
||||
const lines = fs.readFileSync(path.join(GOLDEN, name + '.csv'), 'utf8').split(/\r?\n/);
|
||||
lines.shift();
|
||||
// Drop only the single trailing-newline artifact, keeping legitimate blank
|
||||
// rows (a candle on which no bar closed) so rows stay aligned to the input.
|
||||
if (lines.length && lines[lines.length - 1] === '') lines.pop();
|
||||
return lines.map((l) => (l.length === 0 ? [] : l.split(',').map(cell)));
|
||||
}
|
||||
|
||||
const MANIFEST = JSON.parse(fs.readFileSync(path.join(GOLDEN, 'node_manifest.json'), 'utf8'));
|
||||
const ROWS = readCsv('input');
|
||||
|
||||
function derivFields(o, h, l, c, v) {
|
||||
return {
|
||||
fundingRate: ((c - o) / c) * 0.01,
|
||||
markPrice: c,
|
||||
indexPrice: c - 0.5,
|
||||
futuresPrice: c + 1.0,
|
||||
openInterest: v * 10.0,
|
||||
longSize: v * 0.6,
|
||||
shortSize: v * 0.4,
|
||||
takerBuyVolume: v * 0.55,
|
||||
takerSellVolume: v * 0.45,
|
||||
longLiquidation: h - c,
|
||||
shortLiquidation: c - l,
|
||||
};
|
||||
}
|
||||
|
||||
function resolveArg(arg, o, h, l, c, v, i) {
|
||||
const name = arg.name;
|
||||
if (arg.array) {
|
||||
switch (name) {
|
||||
case 'change':
|
||||
return [0, 1, 2, 3, 4].map((j) => c - o + j);
|
||||
case 'volume':
|
||||
return [0, 1, 2, 3, 4].map((j) => v + j * 10.0);
|
||||
case 'newHigh':
|
||||
return [0, 1, 2, 3, 4].map((j) => j % 2 === 0);
|
||||
case 'newLow':
|
||||
return [0, 1, 2, 3, 4].map((j) => j % 3 === 0);
|
||||
case 'aboveMa':
|
||||
return [0, 1, 2, 3, 4].map((j) => j % 2 === 0);
|
||||
case 'onBuySignal':
|
||||
return [0, 1, 2, 3, 4].map((j) => j % 3 === 0);
|
||||
case 'bidPx':
|
||||
return [0, 1, 2, 3, 4].map((k) => c - 0.1 * (k + 1));
|
||||
case 'bidSz':
|
||||
return [0, 1, 2, 3, 4].map((k) => v / (k + 1));
|
||||
case 'askPx':
|
||||
return [0, 1, 2, 3, 4].map((k) => c + 0.1 * (k + 1));
|
||||
case 'askSz':
|
||||
return [0, 1, 2, 3, 4].map((k) => (v * 0.9) / (k + 1));
|
||||
default:
|
||||
throw new Error('unknown array arg ' + name);
|
||||
}
|
||||
}
|
||||
switch (name) {
|
||||
case 'value':
|
||||
case 'close':
|
||||
case 'price':
|
||||
case 'x':
|
||||
case 'a':
|
||||
case 'asset':
|
||||
return c;
|
||||
case 'y':
|
||||
case 'b':
|
||||
case 'benchmark':
|
||||
case 'open':
|
||||
return o;
|
||||
case 'high':
|
||||
return h;
|
||||
case 'low':
|
||||
return l;
|
||||
case 'volume':
|
||||
case 'size':
|
||||
return v;
|
||||
case 'timestamp':
|
||||
return i;
|
||||
case 'isBuy':
|
||||
return c >= o;
|
||||
case 'mid':
|
||||
return (h + l) / 2.0;
|
||||
default: {
|
||||
const d = derivFields(o, h, l, c, v);
|
||||
if (name in d) return d[name];
|
||||
throw new Error('unknown scalar arg ' + name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function closeEq(got, want, label) {
|
||||
if (Number.isNaN(want)) {
|
||||
assert.ok(Number.isNaN(got), `${label}: want NaN got ${got}`);
|
||||
return;
|
||||
}
|
||||
if (!Number.isFinite(want)) {
|
||||
assert.ok(got === want, `${label}: want ${want} got ${got}`);
|
||||
return;
|
||||
}
|
||||
const tol = 1e-6 * Math.max(1.0, Math.abs(want));
|
||||
assert.ok(Math.abs(got - want) <= tol, `${label}: got ${got} want ${want}`);
|
||||
}
|
||||
|
||||
for (const spec of MANIFEST) {
|
||||
test(`golden: ${spec.canonical}`, () => {
|
||||
const Cls = wickra[spec.native];
|
||||
assert.ok(Cls, `missing Node class ${spec.native}`);
|
||||
const ind = new Cls(...spec.ctor);
|
||||
const isBars = spec.out === 'bars' || spec.out === 'footprint';
|
||||
const expected = isBars ? readBarRows('g_' + spec.canonical) : readCsv('g_' + spec.canonical);
|
||||
|
||||
for (let i = 0; i < ROWS.length; i++) {
|
||||
const [o, h, l, c, v] = ROWS[i];
|
||||
const args = spec.args.map((a) => resolveArg(a, o, h, l, c, v, i));
|
||||
const got = ind.update(...args);
|
||||
const want = expected[i];
|
||||
const label = `${spec.canonical} row ${i}`;
|
||||
|
||||
if (spec.out === 'scalar') {
|
||||
closeEq(got === null || got === undefined ? NaN : got, want[0], label);
|
||||
} else if (spec.out === 'multi') {
|
||||
if (got === null || got === undefined) {
|
||||
assert.ok(want.every(Number.isNaN), `${label}: want ${want} got null`);
|
||||
continue;
|
||||
}
|
||||
// napi serialises the output struct's fields in declaration order, which
|
||||
// matches the CSV column order — compare positionally to avoid relying on
|
||||
// the exact camelCase of each field name.
|
||||
const vals = Object.values(got);
|
||||
assert.equal(vals.length, want.length, `${label}: arity ${vals.length} vs ${want.length}`);
|
||||
vals.forEach((gv, k) => {
|
||||
closeEq(gv === null || gv === undefined ? NaN : gv, want[k], `${label} col ${k}`);
|
||||
});
|
||||
} else if (spec.out === 'profile_bins') {
|
||||
if (got === null || got === undefined) {
|
||||
assert.ok(want.every(Number.isNaN), `${label}: want all-NaN got null`);
|
||||
continue;
|
||||
}
|
||||
assert.equal(got.length, want.length, `${label}: width ${got.length} vs ${want.length}`);
|
||||
got.forEach((gv, k) => closeEq(gv, want[k], `${label} bin ${k}`));
|
||||
} else if (spec.out === 'profile_pricebins') {
|
||||
if (got === null || got === undefined) {
|
||||
assert.ok(want.every(Number.isNaN), `${label}: want all-NaN got null`);
|
||||
continue;
|
||||
}
|
||||
const flat = [got.priceLow, got.priceHigh, ...got[spec.arrayField]];
|
||||
assert.equal(flat.length, want.length, `${label}: width ${flat.length} vs ${want.length}`);
|
||||
flat.forEach((gv, k) => closeEq(gv, want[k], `${label} col ${k}`));
|
||||
} else {
|
||||
// bars / footprint: flatten array-of-objects in declared field order.
|
||||
const flat = [];
|
||||
for (const bar of got) {
|
||||
for (const f of spec.fields) flat.push(Number(bar[f]));
|
||||
}
|
||||
assert.equal(flat.length, want.length, `${label}: arity ${flat.length} vs ${want.length}`);
|
||||
flat.forEach((gv, k) => closeEq(gv, want[k], `${label} col ${k}`));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,70 @@
|
||||
"""Generic golden replay for the alt-chart bar builders and the footprint.
|
||||
|
||||
Each builder turns one candle into 0..n completed bars, so the fixture stores
|
||||
one CSV line per input candle holding every bar flattened (an empty line means
|
||||
no bar closed on that candle). Close-driven builders (Renko, Kagi, P&F, Range,
|
||||
Three-Line-Break) receive a flat candle, mirroring the binding's `update(close)`.
|
||||
Values are checked bit-for-bit against the Rust-generated `g_<Canonical>.csv`.
|
||||
"""
|
||||
import json
|
||||
import math
|
||||
import os
|
||||
|
||||
import pytest
|
||||
import wickra as ta
|
||||
|
||||
HERE = os.path.dirname(__file__)
|
||||
GOLDEN = os.path.normpath(os.path.join(HERE, "..", "..", "..", "testdata", "golden"))
|
||||
|
||||
|
||||
def _cell(s):
|
||||
return math.nan if s == "nan" else float(s)
|
||||
|
||||
|
||||
def _bar_rows(name):
|
||||
# Keep blank lines: one row per input candle, blank == no bar closed.
|
||||
with open(os.path.join(GOLDEN, name + ".csv")) as f:
|
||||
lines = f.read().splitlines()[1:]
|
||||
return [[] if not ln.strip() else [_cell(x) for x in ln.split(",")] for ln in lines]
|
||||
|
||||
|
||||
def _input():
|
||||
with open(os.path.join(GOLDEN, "input.csv")) as f:
|
||||
return [[float(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
with open(os.path.join(GOLDEN, "bars_manifest.json")) as _mf:
|
||||
MANIFEST = json.load(_mf)
|
||||
ROWS = _input()
|
||||
|
||||
|
||||
def _flatten(bars):
|
||||
out = []
|
||||
for bar in bars:
|
||||
out.extend(float(x) for x in bar)
|
||||
return out
|
||||
|
||||
|
||||
@pytest.mark.parametrize("spec", MANIFEST, ids=[m["canonical"] for m in MANIFEST])
|
||||
def test_bars_match_golden(spec):
|
||||
ind = getattr(ta, spec["native"])(*spec["params"])
|
||||
expected = _bar_rows("g_" + spec["canonical"])
|
||||
feed = spec["feed"]
|
||||
assert len(expected) == len(ROWS), f"{spec['canonical']}: {len(expected)} rows vs {len(ROWS)} inputs"
|
||||
for i, (o, h, l, c, v) in enumerate(ROWS):
|
||||
if feed == "close":
|
||||
produced = ind.update(c)
|
||||
elif feed == "candle4":
|
||||
produced = ind.update(o, h, l, c)
|
||||
elif feed == "candle5":
|
||||
produced = ind.update(o, h, l, c, v)
|
||||
else: # trade footprint
|
||||
produced = ind.update(c, v, c >= o)
|
||||
got = _flatten(produced)
|
||||
want = expected[i]
|
||||
assert len(got) == len(want), f"{spec['canonical']} row {i}: arity {len(got)} vs {len(want)}"
|
||||
for gv, w in zip(got, want):
|
||||
if math.isnan(w):
|
||||
assert math.isnan(gv), f"{spec['canonical']} row {i}: want NaN got {gv}"
|
||||
else:
|
||||
assert abs(gv - w) <= 1e-6 * max(1.0, abs(w)), f"{spec['canonical']} row {i}: got {gv} want {w}"
|
||||
@@ -0,0 +1,128 @@
|
||||
"""Generic golden replay for the exotic-input families: DerivativesTick,
|
||||
CrossSection, Trade, TradeQuote and OrderBook indicators.
|
||||
|
||||
Each family feeds a synthetic stream deterministically derived from the shared
|
||||
`testdata/golden/input.csv` OHLCV rows — the exact same construction the Rust
|
||||
`gen_golden` binary uses — and every value is checked bit-for-bit against the
|
||||
Rust-generated `g_<Canonical>.csv`. This pins the Python FFI for indicators
|
||||
whose inputs cannot be expressed as a plain close/candle/pair stream.
|
||||
"""
|
||||
import json
|
||||
import math
|
||||
import os
|
||||
|
||||
import pytest
|
||||
import wickra as ta
|
||||
|
||||
HERE = os.path.dirname(__file__)
|
||||
GOLDEN = os.path.normpath(os.path.join(HERE, "..", "..", "..", "testdata", "golden"))
|
||||
|
||||
|
||||
def _cell(s):
|
||||
return math.nan if s == "nan" else float(s)
|
||||
|
||||
|
||||
def _rows(name):
|
||||
with open(os.path.join(GOLDEN, name + ".csv")) as f:
|
||||
return [[_cell(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
def _input():
|
||||
with open(os.path.join(GOLDEN, "input.csv")) as f:
|
||||
return [[float(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
with open(os.path.join(GOLDEN, "exotic_manifest.json")) as _mf:
|
||||
MANIFEST = json.load(_mf)
|
||||
ROWS = _input()
|
||||
|
||||
|
||||
def _deriv_fields(o, h, l, c, v):
|
||||
return {
|
||||
"funding_rate": (c - o) / c * 0.01,
|
||||
"mark_price": c,
|
||||
"index_price": c - 0.5,
|
||||
"futures_price": c + 1.0,
|
||||
"open_interest": v * 10.0,
|
||||
"long_size": v * 0.6,
|
||||
"short_size": v * 0.4,
|
||||
"taker_buy_volume": v * 0.55,
|
||||
"taker_sell_volume": v * 0.45,
|
||||
"long_liquidation": h - c,
|
||||
"short_liquidation": c - l,
|
||||
}
|
||||
|
||||
|
||||
def _cross_lists(o, h, l, c, v):
|
||||
change = [(c - o) + j for j in range(5)]
|
||||
volume = [v + j * 10.0 for j in range(5)]
|
||||
new_high = [j % 2 == 0 for j in range(5)]
|
||||
new_low = [j % 3 == 0 for j in range(5)]
|
||||
above_ma = [j % 2 == 0 for j in range(5)]
|
||||
on_buy_signal = [j % 3 == 0 for j in range(5)]
|
||||
return change, volume, new_high, new_low, above_ma, on_buy_signal
|
||||
|
||||
|
||||
def _ob_lists(o, h, l, c, v):
|
||||
bid_px = [c - 0.1 * (k + 1) for k in range(5)]
|
||||
bid_sz = [v / (k + 1) for k in range(5)]
|
||||
ask_px = [c + 0.1 * (k + 1) for k in range(5)]
|
||||
ask_sz = [v * 0.9 / (k + 1) for k in range(5)]
|
||||
return bid_px, bid_sz, ask_px, ask_sz
|
||||
|
||||
|
||||
def _assert_scalar(got, want, canonical, i):
|
||||
got = math.nan if got is None else got
|
||||
if math.isnan(want):
|
||||
assert math.isnan(got), f"{canonical} row {i}: want NaN got {got}"
|
||||
elif math.isinf(want):
|
||||
assert math.isinf(got) and (got > 0) == (want > 0), f"{canonical} row {i}: got {got} want {want}"
|
||||
else:
|
||||
assert abs(got - want) <= 1e-6 * max(1.0, abs(want)), f"{canonical} row {i}: got {got} want {want}"
|
||||
|
||||
|
||||
def _specs(family):
|
||||
return [(family, s) for s in MANIFEST[family]]
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"family,spec",
|
||||
_specs("deriv") + _specs("cross") + _specs("trade") + _specs("trademid") + _specs("ob"),
|
||||
ids=[s["canonical"] for fam in ("deriv", "cross", "trade", "trademid", "ob") for s in MANIFEST[fam]],
|
||||
)
|
||||
def test_exotic_matches_golden(family, spec):
|
||||
ind = getattr(ta, spec["native"])(*spec["params"])
|
||||
expected = _rows("g_" + spec["canonical"])
|
||||
n = spec.get("n")
|
||||
for i, (o, h, l, c, v) in enumerate(ROWS):
|
||||
if family == "deriv":
|
||||
f = _deriv_fields(o, h, l, c, v)
|
||||
got = ind.update(*[f[a] for a in spec["args"]])
|
||||
elif family == "cross":
|
||||
change, volume, nh, nl, above_ma, on_buy = _cross_lists(o, h, l, c, v)
|
||||
extra = spec.get("extra")
|
||||
if extra == "above_ma":
|
||||
got = ind.update(change, volume, nh, nl, above_ma)
|
||||
elif extra == "on_buy_signal":
|
||||
got = ind.update(change, volume, nh, nl, on_buy)
|
||||
else:
|
||||
got = ind.update(change, volume, nh, nl)
|
||||
elif family == "trade":
|
||||
got = ind.update(c, v, c >= o)
|
||||
elif family == "trademid":
|
||||
got = ind.update(c, v, c >= o, (h + l) / 2.0)
|
||||
else: # ob
|
||||
bid_px, bid_sz, ask_px, ask_sz = _ob_lists(o, h, l, c, v)
|
||||
got = ind.update(bid_px, bid_sz, ask_px, ask_sz)
|
||||
|
||||
want = expected[i]
|
||||
if n: # multi-output (LiquidationFeatures)
|
||||
if got is None:
|
||||
assert all(math.isnan(w) for w in want), f"{spec['canonical']} row {i}: want {want} got None"
|
||||
continue
|
||||
vals = list(got)
|
||||
assert len(vals) == len(want), f"{spec['canonical']} row {i}: arity {len(vals)} vs {len(want)}"
|
||||
for gv, w in zip(vals, want):
|
||||
_assert_scalar(gv, w, spec["canonical"], i)
|
||||
else:
|
||||
_assert_scalar(got, want[0], spec["canonical"], i)
|
||||
@@ -0,0 +1,60 @@
|
||||
"""Generic golden replay for multi-output indicators: each entry in
|
||||
multi_manifest.json is reconstructed by its native name and every output field
|
||||
is checked against the Rust-generated g_<Canonical>.csv (one column per field).
|
||||
"""
|
||||
import json
|
||||
import math
|
||||
import os
|
||||
|
||||
import pytest
|
||||
import wickra as ta
|
||||
|
||||
HERE = os.path.dirname(__file__)
|
||||
GOLDEN = os.path.normpath(os.path.join(HERE, "..", "..", "..", "testdata", "golden"))
|
||||
|
||||
|
||||
def _cell(s):
|
||||
return math.nan if s == "nan" else float(s)
|
||||
|
||||
|
||||
def _rows(name):
|
||||
with open(os.path.join(GOLDEN, name + ".csv")) as f:
|
||||
return [[_cell(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
def _input():
|
||||
with open(os.path.join(GOLDEN, "input.csv")) as f:
|
||||
return [[float(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
with open(os.path.join(GOLDEN, "multi_manifest.json")) as _mf:
|
||||
MANIFEST = json.load(_mf)
|
||||
ROWS = _input()
|
||||
|
||||
|
||||
@pytest.mark.parametrize("spec", MANIFEST, ids=[m["canonical"] for m in MANIFEST])
|
||||
def test_multi_matches_golden(spec):
|
||||
ind = getattr(ta, spec["native"])(*spec["params"])
|
||||
expected = _rows("g_" + spec["canonical"])
|
||||
inp = spec["input"]
|
||||
for i, (o, h, l, c, v) in enumerate(ROWS):
|
||||
if inp == "f64":
|
||||
got = ind.update(c)
|
||||
elif inp == "Candle":
|
||||
got = ind.update((o, h, l, c, v, i))
|
||||
else:
|
||||
got = ind.update(c, o)
|
||||
want = expected[i]
|
||||
if got is None:
|
||||
assert all(math.isnan(w) for w in want), f"{spec['canonical']} row {i}: want {want} got None"
|
||||
continue
|
||||
vals = list(got)
|
||||
assert len(vals) == len(want), f"{spec['canonical']} row {i}: arity {len(vals)} vs {len(want)}"
|
||||
for gv, w in zip(vals, want):
|
||||
gv = math.nan if gv is None else gv
|
||||
if math.isnan(w):
|
||||
assert math.isnan(gv), f"{spec['canonical']} row {i}: want NaN got {gv}"
|
||||
elif math.isinf(w):
|
||||
assert math.isinf(gv) and (gv > 0) == (w > 0)
|
||||
else:
|
||||
assert abs(gv - w) <= 1e-6 * max(1.0, abs(w)), f"{spec['canonical']} row {i}: got {gv} want {w}"
|
||||
@@ -0,0 +1,61 @@
|
||||
"""Generic golden replay for the profile family: time/volume seasonality
|
||||
histograms (`bins`) and price-binned market profiles (`price_low, price_high,
|
||||
bins`). Each profile emits a fixed-width row once warm and `NaN`s during warmup.
|
||||
|
||||
The shared `testdata/golden/input.csv` candle series is replayed through the
|
||||
Python FFI and the flattened histogram is checked bit-for-bit against the
|
||||
Rust-generated `g_<Canonical>.csv`.
|
||||
"""
|
||||
import json
|
||||
import math
|
||||
import os
|
||||
|
||||
import pytest
|
||||
import wickra as ta
|
||||
|
||||
HERE = os.path.dirname(__file__)
|
||||
GOLDEN = os.path.normpath(os.path.join(HERE, "..", "..", "..", "testdata", "golden"))
|
||||
|
||||
|
||||
def _cell(s):
|
||||
return math.nan if s == "nan" else float(s)
|
||||
|
||||
|
||||
def _rows(name):
|
||||
with open(os.path.join(GOLDEN, name + ".csv")) as f:
|
||||
return [[_cell(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
def _input():
|
||||
with open(os.path.join(GOLDEN, "input.csv")) as f:
|
||||
return [[float(x) for x in line.split(",")] for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
with open(os.path.join(GOLDEN, "profile_manifest.json")) as _mf:
|
||||
MANIFEST = json.load(_mf)
|
||||
ROWS = _input()
|
||||
|
||||
|
||||
@pytest.mark.parametrize("spec", MANIFEST, ids=[m["canonical"] for m in MANIFEST])
|
||||
def test_profile_matches_golden(spec):
|
||||
ind = getattr(ta, spec["native"])(*spec["params"])
|
||||
expected = _rows("g_" + spec["canonical"])
|
||||
width = spec["width"]
|
||||
for i, (o, h, l, c, v) in enumerate(ROWS):
|
||||
got = ind.update((o, h, l, c, v, i))
|
||||
want = expected[i]
|
||||
assert len(want) == width, f"{spec['canonical']} row {i}: fixture width {len(want)} != {width}"
|
||||
if got is None:
|
||||
assert all(math.isnan(w) for w in want), f"{spec['canonical']} row {i}: want {want} got None"
|
||||
continue
|
||||
if spec["kind"] == "pricebins":
|
||||
price_low, price_high, bins = got
|
||||
vals = [price_low, price_high, *list(bins)]
|
||||
else:
|
||||
vals = list(got)
|
||||
assert len(vals) == width, f"{spec['canonical']} row {i}: arity {len(vals)} != {width}"
|
||||
for gv, w in zip(vals, want):
|
||||
if math.isnan(w):
|
||||
assert math.isnan(gv), f"{spec['canonical']} row {i}: want NaN got {gv}"
|
||||
else:
|
||||
assert abs(gv - w) <= 1e-6 * max(1.0, abs(w)), f"{spec['canonical']} row {i}: got {gv} want {w}"
|
||||
@@ -0,0 +1,67 @@
|
||||
"""Generic golden replay: every scalar indicator in scalar_manifest.json is
|
||||
constructed by its native name with the recorded params, fed the shared golden
|
||||
input, and checked bit-for-bit against the Rust-generated g_<Canonical>.csv.
|
||||
|
||||
This ties the Python binding to the Rust reference for the whole scalar-output
|
||||
tranche (not just the seven archetype representatives). Fixtures + manifest are
|
||||
produced by `cargo run -p wickra-examples --bin gen_golden`.
|
||||
"""
|
||||
import json
|
||||
import math
|
||||
import os
|
||||
|
||||
import numpy as np
|
||||
import pytest
|
||||
import wickra as ta
|
||||
|
||||
HERE = os.path.dirname(__file__)
|
||||
GOLDEN = os.path.normpath(os.path.join(HERE, "..", "..", "..", "testdata", "golden"))
|
||||
|
||||
|
||||
def _cell(s):
|
||||
return math.nan if s == "nan" else float(s)
|
||||
|
||||
|
||||
def _load(name):
|
||||
with open(os.path.join(GOLDEN, name + ".csv")) as f:
|
||||
return [_cell(line.strip()) for line in f.read().splitlines()[1:] if line.strip()]
|
||||
|
||||
|
||||
def _input():
|
||||
rows = []
|
||||
with open(os.path.join(GOLDEN, "input.csv")) as f:
|
||||
for line in f.read().splitlines()[1:]:
|
||||
if line.strip():
|
||||
rows.append([float(x) for x in line.split(",")])
|
||||
return rows
|
||||
|
||||
|
||||
with open(os.path.join(GOLDEN, "scalar_manifest.json")) as _mf:
|
||||
MANIFEST = json.load(_mf)
|
||||
ROWS = _input()
|
||||
|
||||
|
||||
@pytest.mark.parametrize("spec", MANIFEST, ids=[m["canonical"] for m in MANIFEST])
|
||||
def test_scalar_matches_golden(spec):
|
||||
cls = getattr(ta, spec["native"])
|
||||
ind = cls(*spec["params"])
|
||||
expected = _load("g_" + spec["canonical"])
|
||||
inp = spec["input"]
|
||||
for i, (o, h, l, c, v) in enumerate(ROWS):
|
||||
if inp == "f64":
|
||||
got = ind.update(c)
|
||||
elif inp == "Candle":
|
||||
got = ind.update((o, h, l, c, v, i))
|
||||
else: # pairwise (f64, f64): generator fed (close, open)
|
||||
got = ind.update(c, o)
|
||||
want = expected[i]
|
||||
got = math.nan if got is None else got
|
||||
if math.isnan(want):
|
||||
assert math.isnan(got), f"{spec['canonical']} row {i}: want NaN got {got}"
|
||||
elif math.isinf(want):
|
||||
assert math.isinf(got) and (got > 0) == (want > 0), (
|
||||
f"{spec['canonical']} row {i}: got {got} want {want}"
|
||||
)
|
||||
else:
|
||||
tol = 1e-6 * max(1.0, abs(want))
|
||||
assert abs(got - want) <= tol, f"{spec['canonical']} row {i}: got {got} want {want}"
|
||||
@@ -0,0 +1,27 @@
|
||||
"""Generate tests/testthat/golden_specs.R: the per-indicator spec list (canonical
|
||||
name, archetype, ctor params, output width) consumed by test-golden-all.R, which
|
||||
replays all 514 indicators against the Rust reference fixtures g_<Canonical>.csv.
|
||||
|
||||
Run from repo root: python bindings/r/gen_golden_test.py
|
||||
"""
|
||||
import json
|
||||
import os
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
MAN = json.load(open(os.path.join(ROOT, "testdata", "golden", "golden_manifest.json")))
|
||||
|
||||
lines = [
|
||||
"# Code generated by gen_golden_test.py. DO NOT EDIT.",
|
||||
"# Per-indicator golden spec: canonical name, archetype, ctor params, output width.",
|
||||
"GOLDEN_SPECS <- list(",
|
||||
]
|
||||
for e in MAN:
|
||||
n = e.get("n", e.get("width", 0))
|
||||
params = ",".join(repr(float(p)) for p in e["params"])
|
||||
lines.append(f' list(canon="{e["canonical"]}", arch="{e["arch"]}", params=c({params}), width={n}L),')
|
||||
lines[-1] = lines[-1].rstrip(",")
|
||||
lines.append(")")
|
||||
|
||||
dest = os.path.join(ROOT, "bindings", "r", "tests", "testthat", "golden_specs.R")
|
||||
open(dest, "w", encoding="utf-8").write("\n".join(lines) + "\n")
|
||||
print("wrote golden_specs.R with", len(MAN), "specs")
|
||||
+30
-15
@@ -7,6 +7,21 @@
|
||||
#include <stddef.h>
|
||||
#include "wickra.h"
|
||||
|
||||
/* Convert an R numeric vector of flags (non-zero == TRUE) into a C `bool*`
|
||||
* buffer (one byte per element). The cross-section indicators take their state
|
||||
* flags as `const bool*`; casting `wk_bool_vec(x)` would reinterpret the
|
||||
* 8-byte doubles as 1-byte bools and read every flag as false. The buffer is
|
||||
* allocated with R_alloc, so it lives until the enclosing .Call returns. */
|
||||
static bool *wk_bool_vec(SEXP x) {
|
||||
R_xlen_t n = Rf_xlength(x);
|
||||
bool *out = (bool *)R_alloc(n, sizeof(bool));
|
||||
double *src = REAL(x);
|
||||
for (R_xlen_t i = 0; i < n; i++) {
|
||||
out[i] = src[i] != 0.0;
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
static void abandoned_baby_fin(SEXP e) {
|
||||
struct AbandonedBaby *h = (struct AbandonedBaby *)R_ExternalPtrAddr(e);
|
||||
if (h) wickra_abandoned_baby_free(h);
|
||||
@@ -104,7 +119,7 @@ SEXP wk_absolute_breadth_index_new(void) {
|
||||
}
|
||||
SEXP wk_absolute_breadth_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct AbsoluteBreadthIndex *h = (struct AbsoluteBreadthIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_absolute_breadth_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_absolute_breadth_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_absolute_breadth_index_warmup_period(SEXP e) {
|
||||
struct AbsoluteBreadthIndex *h = (struct AbsoluteBreadthIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -260,7 +275,7 @@ SEXP wk_ad_volume_line_new(void) {
|
||||
}
|
||||
SEXP wk_ad_volume_line_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct AdVolumeLine *h = (struct AdVolumeLine *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_ad_volume_line_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_ad_volume_line_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_ad_volume_line_warmup_period(SEXP e) {
|
||||
struct AdVolumeLine *h = (struct AdVolumeLine *)R_ExternalPtrAddr(e);
|
||||
@@ -531,7 +546,7 @@ SEXP wk_advance_decline_new(void) {
|
||||
}
|
||||
SEXP wk_advance_decline_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct AdvanceDecline *h = (struct AdvanceDecline *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_advance_decline_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_advance_decline_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_advance_decline_warmup_period(SEXP e) {
|
||||
struct AdvanceDecline *h = (struct AdvanceDecline *)R_ExternalPtrAddr(e);
|
||||
@@ -562,7 +577,7 @@ SEXP wk_advance_decline_ratio_new(void) {
|
||||
}
|
||||
SEXP wk_advance_decline_ratio_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct AdvanceDeclineRatio *h = (struct AdvanceDeclineRatio *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_advance_decline_ratio_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_advance_decline_ratio_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_advance_decline_ratio_warmup_period(SEXP e) {
|
||||
struct AdvanceDeclineRatio *h = (struct AdvanceDeclineRatio *)R_ExternalPtrAddr(e);
|
||||
@@ -2059,7 +2074,7 @@ SEXP wk_breadth_thrust_new(SEXP a0) {
|
||||
}
|
||||
SEXP wk_breadth_thrust_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct BreadthThrust *h = (struct BreadthThrust *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_breadth_thrust_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_breadth_thrust_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_breadth_thrust_warmup_period(SEXP e) {
|
||||
struct BreadthThrust *h = (struct BreadthThrust *)R_ExternalPtrAddr(e);
|
||||
@@ -2131,7 +2146,7 @@ SEXP wk_bullish_percent_index_new(void) {
|
||||
}
|
||||
SEXP wk_bullish_percent_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct BullishPercentIndex *h = (struct BullishPercentIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_bullish_percent_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_bullish_percent_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_bullish_percent_index_warmup_period(SEXP e) {
|
||||
struct BullishPercentIndex *h = (struct BullishPercentIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -3462,7 +3477,7 @@ SEXP wk_cumulative_volume_index_new(void) {
|
||||
}
|
||||
SEXP wk_cumulative_volume_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct CumulativeVolumeIndex *h = (struct CumulativeVolumeIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_cumulative_volume_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_cumulative_volume_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_cumulative_volume_index_warmup_period(SEXP e) {
|
||||
struct CumulativeVolumeIndex *h = (struct CumulativeVolumeIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -7104,7 +7119,7 @@ SEXP wk_high_low_index_new(SEXP a0) {
|
||||
}
|
||||
SEXP wk_high_low_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct HighLowIndex *h = (struct HighLowIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_high_low_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_high_low_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_high_low_index_warmup_period(SEXP e) {
|
||||
struct HighLowIndex *h = (struct HighLowIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -10118,7 +10133,7 @@ SEXP wk_mc_clellan_oscillator_new(void) {
|
||||
}
|
||||
SEXP wk_mc_clellan_oscillator_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct McClellanOscillator *h = (struct McClellanOscillator *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_mc_clellan_oscillator_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_mc_clellan_oscillator_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_mc_clellan_oscillator_warmup_period(SEXP e) {
|
||||
struct McClellanOscillator *h = (struct McClellanOscillator *)R_ExternalPtrAddr(e);
|
||||
@@ -10149,7 +10164,7 @@ SEXP wk_mc_clellan_summation_index_new(void) {
|
||||
}
|
||||
SEXP wk_mc_clellan_summation_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct McClellanSummationIndex *h = (struct McClellanSummationIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_mc_clellan_summation_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_mc_clellan_summation_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_mc_clellan_summation_index_warmup_period(SEXP e) {
|
||||
struct McClellanSummationIndex *h = (struct McClellanSummationIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -10914,7 +10929,7 @@ SEXP wk_new_highs_new_lows_new(void) {
|
||||
}
|
||||
SEXP wk_new_highs_new_lows_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct NewHighsNewLows *h = (struct NewHighsNewLows *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_new_highs_new_lows_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_new_highs_new_lows_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_new_highs_new_lows_warmup_period(SEXP e) {
|
||||
struct NewHighsNewLows *h = (struct NewHighsNewLows *)R_ExternalPtrAddr(e);
|
||||
@@ -11870,7 +11885,7 @@ SEXP wk_percent_above_ma_new(void) {
|
||||
}
|
||||
SEXP wk_percent_above_ma_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct PercentAboveMa *h = (struct PercentAboveMa *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_percent_above_ma_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_percent_above_ma_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_percent_above_ma_warmup_period(SEXP e) {
|
||||
struct PercentAboveMa *h = (struct PercentAboveMa *)R_ExternalPtrAddr(e);
|
||||
@@ -17276,7 +17291,7 @@ SEXP wk_tick_index_new(void) {
|
||||
}
|
||||
SEXP wk_tick_index_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct TickIndex *h = (struct TickIndex *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_tick_index_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_tick_index_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_tick_index_warmup_period(SEXP e) {
|
||||
struct TickIndex *h = (struct TickIndex *)R_ExternalPtrAddr(e);
|
||||
@@ -17853,7 +17868,7 @@ SEXP wk_trin_new(void) {
|
||||
}
|
||||
SEXP wk_trin_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct Trin *h = (struct Trin *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_trin_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_trin_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_trin_warmup_period(SEXP e) {
|
||||
struct Trin *h = (struct Trin *)R_ExternalPtrAddr(e);
|
||||
@@ -18651,7 +18666,7 @@ SEXP wk_up_down_volume_ratio_new(void) {
|
||||
}
|
||||
SEXP wk_up_down_volume_ratio_update(SEXP e, SEXP a0, SEXP a1, SEXP a2, SEXP a3, SEXP a4, SEXP a5, SEXP a6) {
|
||||
struct UpDownVolumeRatio *h = (struct UpDownVolumeRatio *)R_ExternalPtrAddr(e);
|
||||
return Rf_ScalarReal(wickra_up_down_volume_ratio_update(h, (double *)REAL(a0), (double *)REAL(a1), (bool *)REAL(a2), (bool *)REAL(a3), (bool *)REAL(a4), (bool *)REAL(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
return Rf_ScalarReal(wickra_up_down_volume_ratio_update(h, (double *)REAL(a0), (double *)REAL(a1), wk_bool_vec(a2), wk_bool_vec(a3), wk_bool_vec(a4), wk_bool_vec(a5), (uintptr_t)Rf_xlength(a0), (int64_t)Rf_asReal(a6)));
|
||||
}
|
||||
SEXP wk_up_down_volume_ratio_warmup_period(SEXP e) {
|
||||
struct UpDownVolumeRatio *h = (struct UpDownVolumeRatio *)R_ExternalPtrAddr(e);
|
||||
|
||||
@@ -0,0 +1,518 @@
|
||||
# Code generated by gen_golden_test.py. DO NOT EDIT.
|
||||
# Per-indicator golden spec: canonical name, archetype, ctor params, output width.
|
||||
GOLDEN_SPECS <- list(
|
||||
list(canon="AbandonedBaby", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Abcd", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AbsoluteBreadthIndex", arch="cross", params=c(), width=0L),
|
||||
list(canon="AccelerationBands", arch="multi_candle", params=c(14.0,2.0), width=3L),
|
||||
list(canon="AcceleratorOscillator", arch="scalar_candle", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="AdOscillator", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AdVolumeLine", arch="cross", params=c(), width=0L),
|
||||
list(canon="AdaptiveCci", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="AdaptiveCycle", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="AdaptiveLaguerreFilter", arch="scalar_f64", params=c(20.0), width=0L),
|
||||
list(canon="AdaptiveRsi", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Adl", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AdvanceBlock", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AdvanceDecline", arch="cross", params=c(), width=0L),
|
||||
list(canon="AdvanceDeclineRatio", arch="cross", params=c(), width=0L),
|
||||
list(canon="Adx", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="Adxr", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Alligator", arch="multi_candle", params=c(3.0,7.0,14.0), width=3L),
|
||||
list(canon="Alma", arch="scalar_f64", params=c(9.0,0.85,6.0), width=0L),
|
||||
list(canon="Alpha", arch="pairwise", params=c(14.0,2.0), width=0L),
|
||||
list(canon="AmihudIlliquidity", arch="trade", params=c(20.0), width=0L),
|
||||
list(canon="AnchoredRsi", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="AnchoredVwap", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AndrewsPitchfork", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="Apo", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Aroon", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="AroonOscillator", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Atr", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="AtrBands", arch="multi_candle", params=c(14.0,2.0), width=3L),
|
||||
list(canon="AtrRatchet", arch="multi_candle", params=c(14.0,2.0,0.5), width=2L),
|
||||
list(canon="AtrTrailingStop", arch="scalar_candle", params=c(14.0,2.0), width=0L),
|
||||
list(canon="AutoFib", arch="multi_candle", params=c(), width=7L),
|
||||
list(canon="Autocorrelation", arch="scalar_f64", params=c(10.0,1.0), width=0L),
|
||||
list(canon="AutocorrelationPeriodogram", arch="scalar_f64", params=c(10.0,48.0), width=0L),
|
||||
list(canon="AverageDailyRange", arch="scalar_candle", params=c(14.0,0.0), width=0L),
|
||||
list(canon="AverageDrawdown", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="AvgPrice", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="AwesomeOscillator", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="AwesomeOscillatorHistogram", arch="scalar_candle", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="BalanceOfPower", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="BandpassFilter", arch="scalar_f64", params=c(20.0,0.3), width=0L),
|
||||
list(canon="Bat", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="BeltHold", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Beta", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="BetaNeutralSpread", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="BetterVolume", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="BipowerVariation", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="BodySizePct", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="BollingerBands", arch="multi_f64", params=c(20.0,2.0), width=4L),
|
||||
list(canon="BollingerBandwidth", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="BomarBands", arch="multi_f64", params=c(4.0,0.85), width=3L),
|
||||
list(canon="BreadthThrust", arch="cross", params=c(10.0), width=0L),
|
||||
list(canon="Breakaway", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="BullishPercentIndex", arch="cross", params=c(), width=0L),
|
||||
list(canon="BurkeRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Butterfly", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="CalendarSpread", arch="deriv", params=c(), width=0L),
|
||||
list(canon="CalmarRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Camarilla", arch="multi_candle", params=c(), width=9L),
|
||||
list(canon="CandleVolume", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="Cci", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="CenterOfGravity", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="CentralPivotRange", arch="multi_candle", params=c(), width=3L),
|
||||
list(canon="Cfo", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="ChaikinMoneyFlow", arch="scalar_candle", params=c(20.0), width=0L),
|
||||
list(canon="ChaikinOscillator", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="ChaikinVolatility", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="ChandeKrollStop", arch="multi_candle", params=c(3.0,2.0,7.0), width=2L),
|
||||
list(canon="ChandelierExit", arch="multi_candle", params=c(14.0,2.0), width=2L),
|
||||
list(canon="ChoppinessIndex", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="ClassicPivots", arch="multi_candle", params=c(), width=7L),
|
||||
list(canon="CloseVsOpen", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ClosingMarubozu", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Cmo", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="CoefficientOfVariation", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Cointegration", arch="multi_pairwise", params=c(40.0,1.0), width=3L),
|
||||
list(canon="CommonSenseRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="CompositeProfile", arch="multi_candle", params=c(20.0,24.0,0.7), width=3L),
|
||||
list(canon="ConcealingBabySwallow", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ConditionalValueAtRisk", arch="scalar_f64", params=c(20.0,0.95), width=0L),
|
||||
list(canon="ConnorsRsi", arch="scalar_f64", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="Coppock", arch="scalar_f64", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="CorrelationTrendIndicator", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Counterattack", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Crab", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="CumulativeVolumeDelta", arch="trade", params=c(), width=0L),
|
||||
list(canon="CumulativeVolumeIndex", arch="cross", params=c(), width=0L),
|
||||
list(canon="CupAndHandle", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="CyberneticCycle", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Cypher", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="DayOfWeekProfile", arch="profile_bins", params=c(0.0), width=7L),
|
||||
list(canon="Decycler", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="DecyclerOscillator", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Dema", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="DemandIndex", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="DemarkPivots", arch="multi_candle", params=c(), width=3L),
|
||||
list(canon="DepthSlope", arch="ob", params=c(), width=0L),
|
||||
list(canon="DerivativeOscillator", arch="scalar_f64", params=c(3.0,7.0,14.0,28.0), width=0L),
|
||||
list(canon="DetrendedStdDev", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="DisparityIndex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="DistanceSsd", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="Doji", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="DojiStar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="DollarBars", arch="bars_candle5", params=c(50000.0), width=0L),
|
||||
list(canon="Donchian", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="DonchianStop", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="DoubleBollinger", arch="multi_f64", params=c(20.0,1.0,2.0), width=5L),
|
||||
list(canon="DoubleTopBottom", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="DownsideGapThreeMethods", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Dpo", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="DragonflyDoji", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="DrawdownDuration", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="DumplingTop", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Dx", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="DynamicMomentumIndex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="EaseOfMovement", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="EffectiveSpread", arch="trademid", params=c(), width=0L),
|
||||
list(canon="EhlersStochastic", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Ehma", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="ElderImpulse", arch="scalar_f64", params=c(3.0,7.0,14.0,28.0), width=0L),
|
||||
list(canon="ElderRay", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="ElderSafeZone", arch="multi_candle", params=c(10.0,2.0), width=2L),
|
||||
list(canon="Ema", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="EmpiricalModeDecomposition", arch="scalar_f64", params=c(20.0,0.1), width=0L),
|
||||
list(canon="Engulfing", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Equivolume", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="EstimatedLeverageRatio", arch="deriv", params=c(), width=0L),
|
||||
list(canon="EvenBetterSinewave", arch="scalar_f64", params=c(40.0,10.0), width=0L),
|
||||
list(canon="EveningDojiStar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Evwma", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="EwmaVolatility", arch="scalar_f64", params=c(0.94), width=0L),
|
||||
list(canon="Expectancy", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="FallingThreeMethods", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Fama", arch="scalar_f64", params=c(0.5,0.05), width=0L),
|
||||
list(canon="FibArcs", arch="multi_candle", params=c(), width=3L),
|
||||
list(canon="FibChannel", arch="multi_candle", params=c(), width=4L),
|
||||
list(canon="FibConfluence", arch="multi_candle", params=c(), width=2L),
|
||||
list(canon="FibExtension", arch="multi_candle", params=c(), width=5L),
|
||||
list(canon="FibFan", arch="multi_candle", params=c(), width=3L),
|
||||
list(canon="FibProjection", arch="multi_candle", params=c(), width=4L),
|
||||
list(canon="FibRetracement", arch="multi_candle", params=c(), width=7L),
|
||||
list(canon="FibTimeZones", arch="multi_candle", params=c(), width=2L),
|
||||
list(canon="FibonacciPivots", arch="multi_candle", params=c(), width=7L),
|
||||
list(canon="FisherRsi", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="FisherTransform", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="FlagPennant", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Footprint", arch="footprint", params=c(1.0), width=0L),
|
||||
list(canon="ForceIndex", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="FractalChaosBands", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="Frama", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="FryPanBottom", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="FundingBasis", arch="deriv", params=c(), width=0L),
|
||||
list(canon="FundingImpliedApr", arch="deriv", params=c(1095.0), width=0L),
|
||||
list(canon="FundingRate", arch="deriv", params=c(), width=0L),
|
||||
list(canon="FundingRateMean", arch="deriv", params=c(20.0), width=0L),
|
||||
list(canon="FundingRateZScore", arch="deriv", params=c(20.0), width=0L),
|
||||
list(canon="GainLossRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="GainToPainRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="GapSideBySideWhite", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Garch11", arch="scalar_f64", params=c(2e-06,0.1,0.88), width=0L),
|
||||
list(canon="GarmanKlassVolatility", arch="scalar_candle", params=c(20.0,252.0), width=0L),
|
||||
list(canon="Gartley", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="GatorOscillator", arch="multi_candle", params=c(3.0,7.0,14.0), width=2L),
|
||||
list(canon="GeneralizedDema", arch="scalar_f64", params=c(5.0,0.7), width=0L),
|
||||
list(canon="GeometricMa", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="GoldenPocket", arch="multi_candle", params=c(), width=3L),
|
||||
list(canon="GrangerCausality", arch="pairwise", params=c(60.0,1.0), width=0L),
|
||||
list(canon="GravestoneDoji", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Hammer", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HangingMan", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Harami", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HaramiCross", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HasbrouckInformationShare", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="HeadAndShoulders", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HeikinAshi", arch="multi_candle", params=c(), width=4L),
|
||||
list(canon="HeikinAshiOscillator", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="HiLoActivator", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="HighLowIndex", arch="cross", params=c(10.0), width=0L),
|
||||
list(canon="HighLowRange", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HighLowVolumeNodes", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="HighWave", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HighpassFilter", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Hikkake", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HikkakeModified", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HilbertDominantCycle", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="HistoricalVolatility", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Hma", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="HoltWinters", arch="scalar_f64", params=c(0.5,0.1), width=0L),
|
||||
list(canon="HomingPigeon", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="HtDcPhase", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="HtPhasor", arch="multi_f64", params=c(), width=2L),
|
||||
list(canon="HtTrendMode", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="HurstChannel", arch="multi_candle", params=c(14.0,2.0), width=3L),
|
||||
list(canon="HurstExponent", arch="scalar_f64", params=c(100.0,4.0), width=0L),
|
||||
list(canon="Ichimoku", arch="multi_candle", params=c(9.0,26.0,52.0,26.0), width=5L),
|
||||
list(canon="IdenticalThreeCrows", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ImbalanceBars", arch="bars_candle4", params=c(5.0), width=0L),
|
||||
list(canon="InNeck", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Inertia", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="InformationRatio", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="InitialBalance", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="InstantaneousTrendline", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="IntradayIntensity", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="IntradayMomentumIndex", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="IntradayVolatilityProfile", arch="profile_bins", params=c(24.0,0.0), width=24L),
|
||||
list(canon="InverseFisherTransform", arch="scalar_f64", params=c(2.0), width=0L),
|
||||
list(canon="InvertedHammer", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="JarqueBera", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Jma", arch="scalar_f64", params=c(7.0,0.0,2.0), width=0L),
|
||||
list(canon="JumpIndicator", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="KRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="KagiBars", arch="bars_close", params=c(2.0), width=0L),
|
||||
list(canon="KalmanHedgeRatio", arch="multi_pairwise", params=c(0.01,0.001), width=3L),
|
||||
list(canon="Kama", arch="scalar_f64", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="KaseDevStop", arch="multi_candle", params=c(14.0,2.0), width=2L),
|
||||
list(canon="KasePermissionStochastic", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="KellyCriterion", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Keltner", arch="multi_candle", params=c(3.0,7.0,2.0), width=3L),
|
||||
list(canon="KendallTau", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="Kicking", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="KickingByLength", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Kst", arch="multi_f64", params=c(3.0,7.0,14.0,28.0,35.0,42.0,56.0,63.0,70.0), width=2L),
|
||||
list(canon="Kurtosis", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Kvo", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="KylesLambda", arch="trademid", params=c(20.0), width=0L),
|
||||
list(canon="LadderBottom", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="LaguerreRsi", arch="scalar_f64", params=c(0.5), width=0L),
|
||||
list(canon="LeadLagCrossCorrelation", arch="multi_pairwise", params=c(20.0,10.0), width=2L),
|
||||
list(canon="LinRegAngle", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="LinRegChannel", arch="multi_f64", params=c(14.0,2.0), width=3L),
|
||||
list(canon="LinRegIntercept", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="LinRegSlope", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="LinearRegression", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="LiquidationFeatures", arch="deriv_multi", params=c(), width=5L),
|
||||
list(canon="LogReturn", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="LongLeggedDoji", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="LongLine", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="LongShortRatio", arch="deriv", params=c(), width=0L),
|
||||
list(canon="M2Measure", arch="scalar_f64", params=c(14.0,2.0,0.5), width=0L),
|
||||
list(canon="MaEnvelope", arch="multi_f64", params=c(14.0,2.0), width=3L),
|
||||
list(canon="MacdExt", arch="multi_f64", params=c(12.0,0.0,26.0,0.0,9.0,0.0), width=3L),
|
||||
list(canon="MacdFix", arch="multi_f64", params=c(9.0), width=3L),
|
||||
list(canon="MacdHistogram", arch="scalar_f64", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="MacdIndicator", arch="multi_f64", params=c(12.0,26.0,9.0), width=3L),
|
||||
list(canon="Mama", arch="multi_f64", params=c(0.5,0.05), width=2L),
|
||||
list(canon="MarketFacilitationIndex", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MartinRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Marubozu", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MassIndex", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="MatHold", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MatchingLow", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MaxDrawdown", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="McClellanOscillator", arch="cross", params=c(), width=0L),
|
||||
list(canon="McClellanSummationIndex", arch="cross", params=c(), width=0L),
|
||||
list(canon="McGinleyDynamic", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="MedianAbsoluteDeviation", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="MedianChannel", arch="multi_f64", params=c(14.0,2.0), width=3L),
|
||||
list(canon="MedianMa", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="MedianPrice", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Mfi", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Microprice", arch="ob", params=c(), width=0L),
|
||||
list(canon="MidPoint", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="MidPrice", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="MinusDi", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="MinusDm", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="ModifiedMaStop", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="Mom", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="MorningDojiStar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MorningEveningStar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="MurreyMathLines", arch="multi_candle", params=c(14.0), width=9L),
|
||||
list(canon="NakedPoc", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Natr", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="NewHighsNewLows", arch="cross", params=c(), width=0L),
|
||||
list(canon="NewPriceLines", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Nrtr", arch="multi_candle", params=c(2.0), width=2L),
|
||||
list(canon="Nvi", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="OIPriceDivergence", arch="deriv", params=c(20.0), width=0L),
|
||||
list(canon="OIWeighted", arch="deriv", params=c(), width=0L),
|
||||
list(canon="Obv", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="OiToVolumeRatio", arch="deriv", params=c(), width=0L),
|
||||
list(canon="OmegaRatio", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="OnNeck", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="OpenInterestDelta", arch="deriv", params=c(), width=0L),
|
||||
list(canon="OpenInterestMomentum", arch="deriv", params=c(10.0), width=0L),
|
||||
list(canon="OpeningMarubozu", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="OpeningRange", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="OrderBookImbalanceFull", arch="ob", params=c(), width=0L),
|
||||
list(canon="OrderBookImbalanceTop1", arch="ob", params=c(), width=0L),
|
||||
list(canon="OrderBookImbalanceTopN", arch="ob", params=c(5.0), width=0L),
|
||||
list(canon="OrderFlowImbalance", arch="ob", params=c(20.0), width=0L),
|
||||
list(canon="OuHalfLife", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="OvernightGap", arch="scalar_candle", params=c(0.0), width=0L),
|
||||
list(canon="OvernightIntradayReturn", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="PainIndex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="PairSpreadZScore", arch="pairwise", params=c(20.0,20.0), width=0L),
|
||||
list(canon="PairwiseBeta", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="ParkinsonVolatility", arch="scalar_candle", params=c(20.0,252.0), width=0L),
|
||||
list(canon="PearsonCorrelation", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="PercentAboveMa", arch="cross", params=c(), width=0L),
|
||||
list(canon="PercentB", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="PercentageTrailingStop", arch="scalar_f64", params=c(2.0), width=0L),
|
||||
list(canon="PerpetualPremiumIndex", arch="deriv", params=c(), width=0L),
|
||||
list(canon="Pgo", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="PiercingDarkCloud", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Pin", arch="trade", params=c(20.0), width=0L),
|
||||
list(canon="PivotReversal", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="PlusDi", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="PlusDm", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Pmo", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="PointAndFigureBars", arch="bars_close", params=c(2.0,3.0), width=0L),
|
||||
list(canon="PolarizedFractalEfficiency", arch="scalar_f64", params=c(10.0,5.0), width=0L),
|
||||
list(canon="Ppo", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="PpoHistogram", arch="scalar_f64", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="ProfileShape", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="ProfitFactor", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="ProjectionBands", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="ProjectionOscillator", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Psar", arch="scalar_candle", params=c(0.02,0.02,0.2), width=0L),
|
||||
list(canon="Pvi", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Qqe", arch="multi_f64", params=c(3.0,7.0,2.0), width=2L),
|
||||
list(canon="Qstick", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="QuartileBands", arch="multi_f64", params=c(14.0), width=3L),
|
||||
list(canon="QuotedSpread", arch="ob", params=c(), width=0L),
|
||||
list(canon="RSquared", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RangeBars", arch="bars_close", params=c(2.0), width=0L),
|
||||
list(canon="RealizedSpread", arch="trademid", params=c(20.0), width=0L),
|
||||
list(canon="RealizedVolatility", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RecoveryFactor", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="RectangleRange", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Reflex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RegimeLabel", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="RelativeStrengthAB", arch="multi_pairwise", params=c(14.0,14.0), width=3L),
|
||||
list(canon="RenkoBars", arch="bars_close", params=c(2.0), width=0L),
|
||||
list(canon="RenkoTrailingStop", arch="scalar_f64", params=c(2.0), width=0L),
|
||||
list(canon="RickshawMan", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="RisingThreeMethods", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Rmi", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Roc", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Rocp", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Rocr", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Rocr100", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RogersSatchellVolatility", arch="scalar_candle", params=c(20.0,252.0), width=0L),
|
||||
list(canon="RollMeasure", arch="trade", params=c(20.0), width=0L),
|
||||
list(canon="RollingCorrelation", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="RollingCovariance", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="RollingIqr", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RollingMinMaxScaler", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RollingPercentileRank", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RollingQuantile", arch="scalar_f64", params=c(20.0,0.5), width=0L),
|
||||
list(canon="RollingVwap", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="RoofingFilter", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Rsi", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Rsx", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="RunBars", arch="bars_candle4", params=c(3.0), width=0L),
|
||||
list(canon="Rvi", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="RviVolatility", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Rwi", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="SampleEntropy", arch="scalar_f64", params=c(20.0,2.0,0.2), width=0L),
|
||||
list(canon="SarExt", arch="scalar_candle", params=c(2.0,0.5,0.5,0.5,0.5,0.5,0.5,0.5), width=0L),
|
||||
list(canon="SeasonalZScore", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="SeparatingLines", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="SessionHighLow", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="SessionRange", arch="multi_candle", params=c(14.0), width=3L),
|
||||
list(canon="SessionVwap", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="ShannonEntropy", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Shark", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="SharpeRatio", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="ShootingStar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ShortLine", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="SignedVolume", arch="trade", params=c(), width=0L),
|
||||
list(canon="SineWave", arch="scalar_f64", params=c(), width=0L),
|
||||
list(canon="SineWeightedMa", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="SinglePrints", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Skewness", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Sma", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Smi", arch="scalar_candle", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="Smma", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="SmoothedHeikinAshi", arch="multi_candle", params=c(14.0), width=4L),
|
||||
list(canon="SortinoRatio", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="SpearmanCorrelation", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="SpinningTop", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="SpreadAr1Coefficient", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="SpreadBollingerBands", arch="multi_pairwise", params=c(14.0,2.0), width=4L),
|
||||
list(canon="SpreadHurst", arch="pairwise", params=c(14.0), width=0L),
|
||||
list(canon="StalledPattern", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="StandardError", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="StandardErrorBands", arch="multi_f64", params=c(14.0,2.0), width=3L),
|
||||
list(canon="StarcBands", arch="multi_candle", params=c(3.0,7.0,2.0), width=3L),
|
||||
list(canon="Stc", arch="scalar_f64", params=c(10.0,23.0,10.0,0.5), width=0L),
|
||||
list(canon="StdDev", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="StepTrailingStop", arch="scalar_f64", params=c(2.0), width=0L),
|
||||
list(canon="SterlingRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="StickSandwich", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="StochRsi", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Stochastic", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="StochasticCci", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="SuperSmoother", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="SuperTrend", arch="multi_candle", params=c(14.0,2.0), width=2L),
|
||||
list(canon="T3", arch="scalar_f64", params=c(5.0,0.7), width=0L),
|
||||
list(canon="TailRatio", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TakerBuySellRatio", arch="deriv", params=c(), width=0L),
|
||||
list(canon="Takuri", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TasukiGap", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdCamouflage", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdClop", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdClopwin", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdCombo", arch="scalar_candle", params=c(3.0,7.0,14.0,28.0), width=0L),
|
||||
list(canon="TdCountdown", arch="scalar_candle", params=c(3.0,7.0,14.0,28.0), width=0L),
|
||||
list(canon="TdDWave", arch="scalar_candle", params=c(2.0), width=0L),
|
||||
list(canon="TdDeMarker", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TdDifferential", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdLines", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="TdMovingAverage", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="TdOpen", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdPressure", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TdPropulsion", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TdRangeProjection", arch="multi_candle", params=c(), width=2L),
|
||||
list(canon="TdRei", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TdRiskLevel", arch="multi_candle", params=c(3.0,7.0), width=2L),
|
||||
list(canon="TdSequential", arch="multi_candle", params=c(3.0,7.0,14.0,28.0), width=3L),
|
||||
list(canon="TdSetup", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="TdTrap", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Tema", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TermStructureBasis", arch="deriv", params=c(), width=0L),
|
||||
list(canon="ThreeDrives", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ThreeInside", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ThreeLineBreak", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="ThreeLineBreakBars", arch="bars_close", params=c(3.0), width=0L),
|
||||
list(canon="ThreeLineStrike", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ThreeOutside", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ThreeSoldiersOrCrows", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="ThreeStarsInSouth", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Thrusting", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TickBars", arch="bars_candle5", params=c(2.0), width=0L),
|
||||
list(canon="TickIndex", arch="cross", params=c(), width=0L),
|
||||
list(canon="Tii", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="TimeBasedStop", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TimeOfDayReturnProfile", arch="profile_bins", params=c(24.0,0.0), width=24L),
|
||||
list(canon="TowerTopBottom", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TpoProfile", arch="profile_pricebins", params=c(30.0,50.0), width=52L),
|
||||
list(canon="TradeImbalance", arch="trade", params=c(20.0), width=0L),
|
||||
list(canon="TradeSignAutocorrelation", arch="trade", params=c(20.0), width=0L),
|
||||
list(canon="TradeVolumeIndex", arch="scalar_candle", params=c(2.0), width=0L),
|
||||
list(canon="TrendLabel", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TrendStrengthIndex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Trendflex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TreynorRatio", arch="pairwise", params=c(14.0,2.0), width=0L),
|
||||
list(canon="Triangle", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Trima", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Trin", arch="cross", params=c(), width=0L),
|
||||
list(canon="TripleTopBottom", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Tristar", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Trix", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TrueRange", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="Tsf", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="TsfOscillator", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Tsi", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="Tsv", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TtmSqueeze", arch="multi_candle", params=c(14.0,2.0,0.5), width=2L),
|
||||
list(canon="TtmTrend", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TurnOfMonth", arch="scalar_candle", params=c(3.0,3.0,0.0), width=0L),
|
||||
list(canon="Tweezer", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TwiggsMoneyFlow", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="TwoCrows", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="TypicalPrice", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="UlcerIndex", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="UltimateOscillator", arch="scalar_candle", params=c(3.0,7.0,14.0), width=0L),
|
||||
list(canon="UniqueThreeRiver", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="UniversalOscillator", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="UpDownVolumeRatio", arch="cross", params=c(), width=0L),
|
||||
list(canon="UpsideGapThreeMethods", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="UpsideGapTwoCrows", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="UpsidePotentialRatio", arch="scalar_f64", params=c(14.0,2.0), width=0L),
|
||||
list(canon="ValueArea", arch="multi_candle", params=c(20.0,50.0,0.7), width=3L),
|
||||
list(canon="ValueAtRisk", arch="scalar_f64", params=c(20.0,0.95), width=0L),
|
||||
list(canon="Variance", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="VarianceRatio", arch="pairwise", params=c(60.0,2.0), width=0L),
|
||||
list(canon="VerticalHorizontalFilter", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Vidya", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="VolatilityCone", arch="multi_candle", params=c(3.0,7.0), width=5L),
|
||||
list(canon="VolatilityOfVolatility", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="VolatilityRatio", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="VoltyStop", arch="scalar_candle", params=c(14.0,2.0), width=0L),
|
||||
list(canon="VolumeBars", arch="bars_candle5", params=c(500.0), width=0L),
|
||||
list(canon="VolumeByTimeProfile", arch="profile_bins", params=c(24.0,0.0), width=24L),
|
||||
list(canon="VolumeOscillator", arch="scalar_candle", params=c(3.0,7.0), width=0L),
|
||||
list(canon="VolumePriceTrend", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="VolumeProfile", arch="profile_pricebins", params=c(20.0,50.0), width=52L),
|
||||
list(canon="VolumeRsi", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="VolumeWeightedMacd", arch="multi_candle", params=c(3.0,7.0,14.0), width=3L),
|
||||
list(canon="VolumeWeightedSr", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="Vortex", arch="multi_candle", params=c(14.0), width=2L),
|
||||
list(canon="Vpin", arch="trade", params=c(5000.0,10.0), width=0L),
|
||||
list(canon="Vwap", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="VwapStdDevBands", arch="multi_candle", params=c(2.0), width=4L),
|
||||
list(canon="Vwma", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Vzo", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="Wad", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="WavePm", arch="scalar_f64", params=c(3.0,7.0), width=0L),
|
||||
list(canon="WaveTrend", arch="multi_candle", params=c(3.0,7.0,14.0), width=2L),
|
||||
list(canon="Wedge", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="WeightedClose", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="WickRatio", arch="scalar_candle", params=c(), width=0L),
|
||||
list(canon="WilliamsFractals", arch="multi_candle", params=c(), width=2L),
|
||||
list(canon="WilliamsR", arch="scalar_candle", params=c(14.0), width=0L),
|
||||
list(canon="WinRate", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="Wma", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="WoodiePivots", arch="multi_candle", params=c(), width=5L),
|
||||
list(canon="YangZhangVolatility", arch="scalar_candle", params=c(20.0,252.0), width=0L),
|
||||
list(canon="YoyoExit", arch="scalar_candle", params=c(14.0,2.0), width=0L),
|
||||
list(canon="ZScore", arch="scalar_f64", params=c(14.0), width=0L),
|
||||
list(canon="ZeroLagMacd", arch="multi_f64", params=c(3.0,7.0,14.0), width=3L),
|
||||
list(canon="ZigZag", arch="multi_candle", params=c(0.02), width=2L),
|
||||
list(canon="Zlema", arch="scalar_f64", params=c(14.0), width=0L)
|
||||
)
|
||||
@@ -0,0 +1,121 @@
|
||||
# Generic golden-fixture parity for the whole 514-indicator catalogue: every
|
||||
# indicator is reconstructed by its constructor, fed the synthetic stream derived
|
||||
# from the shared testdata/golden input (identical to gen_golden's Rust
|
||||
# construction) and checked bit-for-bit against g_<Canonical>.csv. One reflective
|
||||
# runner flattens scalar, multi-output, profile and bar shapes.
|
||||
#
|
||||
# Like test-golden.R, the fixtures live at the repo root and are not bundled into
|
||||
# the standalone package, so packaged checks (r-universe / CRAN) skip; the parity
|
||||
# is enforced by the monorepo CI. Specs are generated by gen_golden_test.py.
|
||||
|
||||
find_golden_dir_all <- function() {
|
||||
d <- normalizePath(getwd(), winslash = "/", mustWork = FALSE)
|
||||
repeat {
|
||||
g <- file.path(d, "testdata", "golden")
|
||||
if (dir.exists(g)) return(g)
|
||||
parent <- dirname(d)
|
||||
if (identical(parent, d)) return(NULL)
|
||||
d <- parent
|
||||
}
|
||||
}
|
||||
|
||||
golden_dir_all <- find_golden_dir_all()
|
||||
|
||||
test_that("all 514 indicators match the Rust golden fixtures", {
|
||||
skip_if(is.null(golden_dir_all), "golden fixtures not bundled with the package")
|
||||
source(test_path("golden_specs.R"), local = TRUE)
|
||||
|
||||
gcell <- function(s) {
|
||||
if (s == "nan") NA_real_ else if (s == "inf") Inf else if (s == "-inf") -Inf else as.numeric(s)
|
||||
}
|
||||
read_rows <- function(name) {
|
||||
lines <- readLines(file.path(golden_dir_all, paste0(name, ".csv")))[-1]
|
||||
lapply(lines, function(l) {
|
||||
if (nchar(l) == 0) return(numeric(0))
|
||||
vapply(strsplit(l, ",", fixed = TRUE)[[1]], gcell, numeric(1), USE.NAMES = FALSE)
|
||||
})
|
||||
}
|
||||
input_rows <- lapply(
|
||||
readLines(file.path(golden_dir_all, "input.csv"))[-1],
|
||||
function(l) as.numeric(strsplit(l, ",", fixed = TRUE)[[1]])
|
||||
)
|
||||
|
||||
deriv_fields <- function(r) {
|
||||
o <- r[1]; h <- r[2]; l <- r[3]; c <- r[4]; v <- r[5]
|
||||
c((c - o) / c * 0.01, c, c - 0.5, c + 1.0, v * 10, v * 0.6, v * 0.4,
|
||||
v * 0.55, v * 0.45, h - c, c - l)
|
||||
}
|
||||
cross_lists <- function(r) {
|
||||
o <- r[1]; c <- r[4]; v <- r[5]; j <- 0:4
|
||||
list(change = (c - o) + j, volume = v + j * 10,
|
||||
newHigh = as.numeric(j %% 2 == 0), newLow = as.numeric(j %% 3 == 0),
|
||||
aboveMa = as.numeric(j %% 2 == 0), onBuy = as.numeric(j %% 3 == 0))
|
||||
}
|
||||
ob_lists <- function(r) {
|
||||
c <- r[4]; v <- r[5]; k <- 1:5
|
||||
list(bp = c - 0.1 * k, bs = v / k, ap = c + 0.1 * k, asz = v * 0.9 / k)
|
||||
}
|
||||
flatten <- function(o, arch, width) {
|
||||
if (arch %in% c("profile_bins")) {
|
||||
if (is.null(o) || length(o) == 0 || all(is.na(o))) return(rep(NA_real_, width))
|
||||
return(as.numeric(o))
|
||||
}
|
||||
if (arch == "profile_pricebins") {
|
||||
if (is.list(o)) return(c(o$price_low, o$price_high, as.numeric(o$values)))
|
||||
return(rep(NA_real_, width))
|
||||
}
|
||||
if (arch %in% c("bars_close", "bars_candle4", "bars_candle5", "footprint")) {
|
||||
if (is.null(o) || length(o) == 0) return(numeric(0))
|
||||
if (is.matrix(o)) return(as.numeric(t(o)))
|
||||
return(as.numeric(o))
|
||||
}
|
||||
as.numeric(o)
|
||||
}
|
||||
|
||||
compute <- function(spec, ind, r, i) {
|
||||
o <- r[1]; h <- r[2]; l <- r[3]; cl <- r[4]; v <- r[5]; ts <- as.integer(i - 1)
|
||||
out <- switch(spec$arch,
|
||||
scalar_f64 = update(ind, cl),
|
||||
multi_f64 = update(ind, cl),
|
||||
pairwise = , multi_pairwise = update(ind, cl, o),
|
||||
scalar_candle = , multi_candle = , profile_bins = , profile_pricebins =
|
||||
update(ind, o, h, l, cl, v, ts),
|
||||
trade = update(ind, cl, v, cl >= o, ts),
|
||||
trademid = update(ind, cl, v, cl >= o, ts, (h + l) / 2),
|
||||
ob = { L <- ob_lists(r); update(ind, L$bp, L$bs, L$ap, L$asz) },
|
||||
cross = { L <- cross_lists(r)
|
||||
update(ind, L$change, L$volume, L$newHigh, L$newLow, L$aboveMa, L$onBuy, ts) },
|
||||
deriv = , deriv_multi = { d <- deriv_fields(r)
|
||||
do.call(update, c(list(ind), as.list(d), list(ts))) },
|
||||
bars_close = update(ind, cl, cl, cl, cl, 1, 0L),
|
||||
bars_candle4 = update(ind, o, h, l, cl, 1, 0L),
|
||||
bars_candle5 = update(ind, o, h, l, cl, v, 0L),
|
||||
footprint = update(ind, cl, v, cl >= o, ts),
|
||||
stop("arch ", spec$arch)
|
||||
)
|
||||
flatten(out, spec$arch, spec$width)
|
||||
}
|
||||
|
||||
for (spec in GOLDEN_SPECS) {
|
||||
ind <- do.call(get(spec$canon), as.list(spec$params))
|
||||
exp <- read_rows(paste0("g_", spec$canon))
|
||||
for (i in seq_along(input_rows)) {
|
||||
got <- compute(spec, ind, input_rows[[i]], i)
|
||||
want <- exp[[i]]
|
||||
expect_equal(length(got), length(want),
|
||||
info = sprintf("%s row %d arity", spec$canon, i))
|
||||
for (k in seq_along(want)) {
|
||||
w <- want[k]; g <- got[k]
|
||||
if (is.na(w)) {
|
||||
expect_true(is.na(g), info = sprintf("%s row %d col %d: want NA", spec$canon, i, k))
|
||||
} else if (is.infinite(w)) {
|
||||
expect_true(is.infinite(g) && sign(g) == sign(w),
|
||||
info = sprintf("%s row %d col %d: want %g", spec$canon, i, k, w))
|
||||
} else {
|
||||
expect_lte(abs(g - w), 1e-6 * max(1, abs(w)),
|
||||
label = sprintf("%s row %d col %d (got %s want %g)", spec$canon, i, k, as.character(g), w))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
@@ -117,3 +117,37 @@ test_that("multi-output ADX matches golden", {
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
# The four de-duplicated indicators, pinned against the Rust reference.
|
||||
|
||||
test_that("de-duplicated candle indicators match golden", {
|
||||
skip_if_no_golden()
|
||||
golden_input <- read_golden_input()
|
||||
specs <- list(
|
||||
list("ad_oscillator", AdOscillator()),
|
||||
list("intraday_intensity", IntradayIntensity()),
|
||||
list("awesome_oscillator_histogram", AwesomeOscillatorHistogram(5, 34, 1))
|
||||
)
|
||||
for (spec in specs) {
|
||||
name <- spec[[1]]
|
||||
ind <- spec[[2]]
|
||||
exp <- read_golden(name)
|
||||
for (i in seq_len(nrow(golden_input))) {
|
||||
got <- update(ind, golden_input$open[i], golden_input$high[i], golden_input$low[i],
|
||||
golden_input$close[i], golden_input$volume[i], i - 1)
|
||||
expect_close(got, gcell(exp[i, 1]), i, name)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
test_that("AverageDrawdown matches golden", {
|
||||
skip_if_no_golden()
|
||||
golden_input <- read_golden_input()
|
||||
avg <- AverageDrawdown(20)
|
||||
exp <- read_golden("average_drawdown")
|
||||
for (i in seq_len(nrow(golden_input))) {
|
||||
# generator fed the close column as the equity-curve sample.
|
||||
got <- update(avg, golden_input$close[i])
|
||||
expect_close(got, gcell(exp[i, 1]), i, "average_drawdown")
|
||||
}
|
||||
})
|
||||
|
||||
@@ -0,0 +1,89 @@
|
||||
"""Generate wasm_manifest.json for the WASM golden replay: for every one of the
|
||||
514 indicators, record the JS class name, constructor params, the ordered update
|
||||
argument names (parsed from pkg/wickra_wasm.d.ts, each flagged array/bigint) and
|
||||
the output archetype (from golden_manifest.json). Run from repo root after
|
||||
`wasm-pack build --target nodejs`: python bindings/wasm/gen_golden_test.py
|
||||
"""
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
G = os.path.join(ROOT, "testdata", "golden")
|
||||
DTS = os.path.join(ROOT, "bindings", "wasm", "pkg", "wickra_wasm.d.ts")
|
||||
|
||||
# canonical -> native (JS class) and canonical -> (arch, n/width) from the manifests.
|
||||
native = {}
|
||||
arch = {}
|
||||
extra = {}
|
||||
for e in json.load(open(os.path.join(G, "scalar_manifest.json"))):
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = {"f64": "scalar_f64", "Candle": "scalar_candle", "(f64, f64)": "pairwise"}[e["input"]]
|
||||
for e in json.load(open(os.path.join(G, "multi_manifest.json"))):
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = {"f64": "multi_f64", "Candle": "multi_candle", "(f64, f64)": "multi_pairwise"}[e["input"]]
|
||||
extra[e["canonical"]] = {"n": e["n"]}
|
||||
ex = json.load(open(os.path.join(G, "exotic_manifest.json")))
|
||||
for e in ex["deriv"]:
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = "deriv_multi" if "n" in e else "deriv"
|
||||
if "n" in e:
|
||||
extra[e["canonical"]] = {"n": e["n"]}
|
||||
for fam, a in (("cross", "cross"), ("trade", "trade"), ("trademid", "trademid"), ("ob", "ob")):
|
||||
for e in ex[fam]:
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = a
|
||||
for e in json.load(open(os.path.join(G, "profile_manifest.json"))):
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = "profile_" + e["kind"]
|
||||
extra[e["canonical"]] = {"width": e["width"], **({"arrayField": "counts" if e["canonical"] == "TpoProfile" else "bins"} if e["kind"] == "pricebins" else {})}
|
||||
for e in json.load(open(os.path.join(G, "bars_manifest.json"))):
|
||||
native[e["canonical"]] = e["native"]
|
||||
arch[e["canonical"]] = "footprint" if e["canonical"] == "Footprint" else "bars"
|
||||
|
||||
# params per canonical (constructor values) — same as the other bindings.
|
||||
params = {}
|
||||
for fn in ("scalar_manifest", "multi_manifest"):
|
||||
for e in json.load(open(os.path.join(G, fn + ".json"))):
|
||||
params[e["canonical"]] = e["params"]
|
||||
for fam in json.load(open(os.path.join(G, "exotic_manifest.json"))).values():
|
||||
for e in fam:
|
||||
params[e["canonical"]] = e["params"]
|
||||
for e in json.load(open(os.path.join(G, "profile_manifest.json"))):
|
||||
params[e["canonical"]] = e["params"]
|
||||
for e in json.load(open(os.path.join(G, "bars_manifest.json"))):
|
||||
params[e["canonical"]] = e["params"]
|
||||
|
||||
# parse update args per JS class from the wasm .d.ts
|
||||
dts = open(DTS, encoding="utf-8").read()
|
||||
cls_args = {}
|
||||
for m in re.finditer(r"export class (\w+) \{(.*?)\n\}", dts, re.S):
|
||||
name, body = m.group(1), m.group(2)
|
||||
um = re.search(r"\bupdate\(([^)]*)\)", body)
|
||||
args = []
|
||||
if um and um.group(1).strip():
|
||||
for p in um.group(1).split(","):
|
||||
p = p.strip()
|
||||
nm = p.split(":")[0].strip()
|
||||
typ = p.split(":", 1)[1].strip() if ":" in p else ""
|
||||
args.append({"name": nm, "array": "Array" in typ, "bigint": "bigint" in typ})
|
||||
cls_args[name] = args
|
||||
|
||||
out = []
|
||||
for canon in sorted(native):
|
||||
js = native[canon]
|
||||
if js not in cls_args:
|
||||
raise SystemExit(f"WASM class {js} (for {canon}) not in d.ts")
|
||||
ctor = params.get(canon, [])
|
||||
# EaseOfMovement's volume divisor is an optional Rust constructor argument
|
||||
# (default 1e8) but a required WASM constructor parameter; pass it explicitly.
|
||||
if canon == "EaseOfMovement":
|
||||
ctor = [ctor[0], 100000000.0]
|
||||
e = {"canonical": canon, "js": js, "ctor": ctor,
|
||||
"args": cls_args[js], "out": arch[canon]}
|
||||
e.update(extra.get(canon, {}))
|
||||
out.append(e)
|
||||
|
||||
json.dump(out, open(os.path.join(G, "wasm_manifest.json"), "w"), indent=1)
|
||||
from collections import Counter
|
||||
print("wasm_manifest:", len(out), dict(Counter(e["out"] for e in out)))
|
||||
@@ -0,0 +1,156 @@
|
||||
// Generic golden-fixture parity for the WASM (wasm-bindgen) binding, run under
|
||||
// Node's test runner against the nodejs-target build in ../pkg.
|
||||
//
|
||||
// Every one of the 514 indicators is reconstructed from wasm_manifest.json (JS
|
||||
// class, constructor params, ordered update args parsed from the generated
|
||||
// .d.ts), fed the synthetic stream derived from the shared golden input — the
|
||||
// same construction gen_golden uses — and checked bit-for-bit against the Rust
|
||||
// reference fixtures g_<Canonical>.csv.
|
||||
//
|
||||
// wasm-pack build --target nodejs --out-dir pkg
|
||||
// node --test tests/
|
||||
|
||||
const test = require('node:test');
|
||||
const assert = require('node:assert/strict');
|
||||
const fs = require('node:fs');
|
||||
const path = require('node:path');
|
||||
const W = require('../pkg/wickra_wasm.js');
|
||||
|
||||
const GOLDEN = path.resolve(__dirname, '..', '..', '..', 'testdata', 'golden');
|
||||
|
||||
function cell(s) {
|
||||
if (s === 'nan') return NaN;
|
||||
if (s === 'inf') return Infinity;
|
||||
if (s === '-inf') return -Infinity;
|
||||
return Number(s);
|
||||
}
|
||||
|
||||
function readCsv(name) {
|
||||
const lines = fs.readFileSync(path.join(GOLDEN, name + '.csv'), 'utf8').split('\n');
|
||||
lines.shift();
|
||||
return lines.filter((l) => l.length > 0).map((l) => l.split(',').map(cell));
|
||||
}
|
||||
|
||||
function readBarRows(name) {
|
||||
const lines = fs.readFileSync(path.join(GOLDEN, name + '.csv'), 'utf8').split('\n');
|
||||
lines.shift();
|
||||
if (lines.length && lines[lines.length - 1] === '') lines.pop();
|
||||
return lines.map((l) => (l.length === 0 ? [] : l.split(',').map(cell)));
|
||||
}
|
||||
|
||||
const MANIFEST = JSON.parse(fs.readFileSync(path.join(GOLDEN, 'wasm_manifest.json'), 'utf8'));
|
||||
const ROWS = readCsv('input');
|
||||
|
||||
function deriv(o, h, l, c, v) {
|
||||
return {
|
||||
funding_rate: ((c - o) / c) * 0.01,
|
||||
mark_price: c,
|
||||
index_price: c - 0.5,
|
||||
futures_price: c + 1.0,
|
||||
open_interest: v * 10.0,
|
||||
long_size: v * 0.6,
|
||||
short_size: v * 0.4,
|
||||
taker_buy_volume: v * 0.55,
|
||||
taker_sell_volume: v * 0.45,
|
||||
long_liquidation: h - c,
|
||||
short_liquidation: c - l,
|
||||
};
|
||||
}
|
||||
|
||||
function resolveArg(arg, o, h, l, c, v, i) {
|
||||
const n = arg.name;
|
||||
if (arg.array) {
|
||||
const j5 = [0, 1, 2, 3, 4];
|
||||
switch (n) {
|
||||
case 'change': return Float64Array.from(j5.map((j) => c - o + j));
|
||||
case 'volume': return Float64Array.from(j5.map((j) => v + j * 10.0));
|
||||
case 'new_high': return Float64Array.from(j5.map((j) => (j % 2 === 0 ? 1 : 0)));
|
||||
case 'new_low': return Float64Array.from(j5.map((j) => (j % 3 === 0 ? 1 : 0)));
|
||||
case 'above_ma': return Float64Array.from(j5.map((j) => (j % 2 === 0 ? 1 : 0)));
|
||||
case 'on_buy_signal': return Float64Array.from(j5.map((j) => (j % 3 === 0 ? 1 : 0)));
|
||||
case 'bid_px': return Float64Array.from(j5.map((k) => c - 0.1 * (k + 1)));
|
||||
case 'bid_sz': return Float64Array.from(j5.map((k) => v / (k + 1)));
|
||||
case 'ask_px': return Float64Array.from(j5.map((k) => c + 0.1 * (k + 1)));
|
||||
case 'ask_sz': return Float64Array.from(j5.map((k) => (v * 0.9) / (k + 1)));
|
||||
default: throw new Error('array arg ' + n);
|
||||
}
|
||||
}
|
||||
if (arg.bigint) return BigInt(i);
|
||||
switch (n) {
|
||||
case 'value': case 'close': case 'price': case 'x': case 'a': case 'asset': return c;
|
||||
case 'y': case 'b': case 'open': case 'benchmark': return o;
|
||||
case 'high': return h;
|
||||
case 'low': return l;
|
||||
case 'volume': case 'size': return v;
|
||||
case 'is_buy': return c >= o;
|
||||
case 'mid': return (h + l) / 2.0;
|
||||
case 'timestamp': return BigInt(i);
|
||||
default: {
|
||||
const d = deriv(o, h, l, c, v);
|
||||
if (n in d) return d[n];
|
||||
throw new Error('scalar arg ' + n);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Recursively flatten a WASM output (number, object with field props, typed/array
|
||||
// of either) into a flat number list. Returns null for warmup (null/undefined).
|
||||
function flat(v) {
|
||||
if (v === null || v === undefined) return null;
|
||||
if (typeof v === 'number' || typeof v === 'bigint') return [Number(v)];
|
||||
if (Array.isArray(v) || ArrayBuffer.isView(v)) {
|
||||
const out = [];
|
||||
for (const e of v) { const f = flat(e); if (f) out.push(...f); }
|
||||
return out;
|
||||
}
|
||||
if (typeof v === 'object') {
|
||||
const out = [];
|
||||
for (const val of Object.values(v)) { const f = flat(val); if (f) out.push(...f); }
|
||||
return out;
|
||||
}
|
||||
return [Number(v)];
|
||||
}
|
||||
|
||||
function nanRow(n) {
|
||||
return Array.from({ length: n }, () => NaN);
|
||||
}
|
||||
|
||||
function widthOf(spec) {
|
||||
if (spec.out.startsWith('multi') || spec.out === 'deriv_multi') return spec.n;
|
||||
if (spec.out.startsWith('profile')) return spec.width;
|
||||
return 1; // scalar archetypes
|
||||
}
|
||||
|
||||
function closeEq(got, want, label) {
|
||||
if (Number.isNaN(want)) { assert.ok(Number.isNaN(got), `${label}: want NaN got ${got}`); return; }
|
||||
if (!Number.isFinite(want)) { assert.ok(got === want, `${label}: want ${want} got ${got}`); return; }
|
||||
const tol = 1e-6 * Math.max(1.0, Math.abs(want));
|
||||
assert.ok(Math.abs(got - want) <= tol, `${label}: got ${got} want ${want}`);
|
||||
}
|
||||
|
||||
for (const spec of MANIFEST) {
|
||||
test(`wasm golden: ${spec.canonical}`, () => {
|
||||
const Cls = W[spec.js];
|
||||
assert.ok(Cls, `missing WASM class ${spec.js}`);
|
||||
const ind = new Cls(...spec.ctor);
|
||||
const isBars = spec.out === 'bars' || spec.out === 'footprint';
|
||||
const expected = isBars ? readBarRows('g_' + spec.canonical) : readCsv('g_' + spec.canonical);
|
||||
|
||||
for (let i = 0; i < ROWS.length; i++) {
|
||||
const [o, h, l, c, v] = ROWS[i];
|
||||
const args = spec.args.map((a) => resolveArg(a, o, h, l, c, v, i));
|
||||
const raw = ind.update(...args);
|
||||
const want = expected[i];
|
||||
const label = `${spec.canonical} row ${i}`;
|
||||
|
||||
let got = flat(raw);
|
||||
if (isBars) {
|
||||
if (got === null) got = [];
|
||||
} else if (got === null) {
|
||||
got = nanRow(widthOf(spec));
|
||||
}
|
||||
assert.equal(got.length, want.length, `${label}: arity ${got.length} vs ${want.length}`);
|
||||
for (let k = 0; k < want.length; k++) closeEq(got[k], want[k], `${label} col ${k}`);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -78,6 +78,33 @@ if(OpenMP_C_FOUND)
|
||||
target_link_libraries(parallel_assets PRIVATE OpenMP::OpenMP_C)
|
||||
endif()
|
||||
|
||||
# Golden-fixture parity over the whole 514-indicator catalogue, built and run as
|
||||
# BOTH C (golden_test.c) and C++ (golden_test.cpp #includes the same source) to
|
||||
# prove the C ABI header is consumable from each language. The fixtures live at
|
||||
# the repo root; pass the absolute path as the test argument.
|
||||
get_filename_component(WICKRA_GOLDEN_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../testdata/golden" ABSOLUTE)
|
||||
foreach(gt_pair "golden_test:golden_test.c" "golden_test_cpp:golden_test.cpp")
|
||||
string(REPLACE ":" ";" gt_list "${gt_pair}")
|
||||
list(GET gt_list 0 gt_name)
|
||||
list(GET gt_list 1 gt_src)
|
||||
add_executable(${gt_name} ${gt_src})
|
||||
target_include_directories(${gt_name} PRIVATE "${WICKRA_INCLUDE_DIR}")
|
||||
target_link_libraries(${gt_name} PRIVATE "${WICKRA_LINK_LIB}")
|
||||
if(UNIX AND NOT APPLE)
|
||||
target_link_libraries(${gt_name} PRIVATE m)
|
||||
endif()
|
||||
if(WIN32)
|
||||
add_custom_command(TARGET ${gt_name} POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
"${WICKRA_RUNTIME}" "$<TARGET_FILE_DIR:${gt_name}>")
|
||||
endif()
|
||||
add_test(NAME ${gt_name} COMMAND ${gt_name} "${WICKRA_GOLDEN_DIR}")
|
||||
if(NOT WIN32)
|
||||
set_tests_properties(${gt_name} PROPERTIES
|
||||
ENVIRONMENT "LD_LIBRARY_PATH=${WICKRA_LIB_DIR};DYLD_LIBRARY_PATH=${WICKRA_LIB_DIR}")
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# Network examples — built (so they stay compilable) but not run in CI.
|
||||
add_wickra_example(fetch_btcusdt fetch_btcusdt.c FALSE) # downloads CSVs via curl
|
||||
add_wickra_example(live_binance live_binance.c FALSE) # polls Binance REST via curl
|
||||
|
||||
@@ -0,0 +1,340 @@
|
||||
"""Generate examples/c/golden_test.c: a value-parity test that replays the shared
|
||||
golden input through every one of the 514 indicators via the C ABI (wickra.h)
|
||||
and checks output bit-for-bit against the Rust reference fixtures
|
||||
g_<Canonical>.csv. The same source compiles under both a C compiler (the C
|
||||
binding) and a C++ compiler (the C++ binding) — wickra.h is `extern "C"`.
|
||||
|
||||
Run from repo root: python examples/c/gen_golden_test.py
|
||||
"""
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
|
||||
ROOT = os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||
G = os.path.join(ROOT, "testdata", "golden")
|
||||
HDR = open(os.path.join(ROOT, "bindings", "c", "include", "wickra.h"), encoding="utf-8").read()
|
||||
|
||||
# canonical -> C prefix, from the R wrappers (.wk_obj first arg == C symbol prefix).
|
||||
RSRC = open(os.path.join(ROOT, "bindings", "r", "R", "indicators.R"), encoding="utf-8").read()
|
||||
PREFIX = {m.group(1): m.group(2)
|
||||
for m in re.finditer(r"^(\w+) <- function\([^)]*\) \{.*?\.wk_obj\(\"([^\"]+)\"", RSRC, re.S | re.M)}
|
||||
|
||||
# wickra_* function signatures (return type, args), multiline-collapsed.
|
||||
SIG = {}
|
||||
for m in re.finditer(r"([A-Za-z_][\w ]*\*?)\s*(wickra_\w+)\(([^;]*?)\);", HDR, re.S):
|
||||
SIG[m.group(2)] = (re.sub(r"\s+", " ", m.group(1)).strip(), re.sub(r"\s+", " ", m.group(3)).strip())
|
||||
|
||||
# archetype + n/width per canonical
|
||||
spec = {}
|
||||
for e in json.load(open(os.path.join(G, "scalar_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": {"f64": "scalar_f64", "Candle": "scalar_candle", "(f64, f64)": "pairwise"}[e["input"]], "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "multi_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": {"f64": "multi_f64", "Candle": "multi_candle", "(f64, f64)": "multi_pairwise"}[e["input"]], "params": e["params"], "n": e["n"]}
|
||||
ex = json.load(open(os.path.join(G, "exotic_manifest.json")))
|
||||
for e in ex["deriv"]:
|
||||
spec[e["canonical"]] = {"arch": "deriv_multi" if "n" in e else "deriv", "params": e["params"], **({"n": e["n"]} if "n" in e else {})}
|
||||
for fam, a in (("cross", "cross"), ("trade", "trade"), ("trademid", "trademid"), ("ob", "ob")):
|
||||
for e in ex[fam]:
|
||||
spec[e["canonical"]] = {"arch": a, "params": e["params"]}
|
||||
for e in json.load(open(os.path.join(G, "profile_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": "profile_" + e["kind"], "params": e["params"], "width": e["width"]}
|
||||
for e in json.load(open(os.path.join(G, "bars_manifest.json"))):
|
||||
spec[e["canonical"]] = {"arch": "footprint" if e["canonical"] == "Footprint" else "bars_" + e["feed"], "params": e["params"]}
|
||||
|
||||
canons = sorted(os.path.basename(f)[2:-4] for f in __import__("glob").glob(os.path.join(G, "g_*.csv")))
|
||||
|
||||
BAR_FIELDS = {
|
||||
"RenkoBars": ["open", "close", "direction"], "KagiBars": ["start", "end", "direction"],
|
||||
"PointAndFigureBars": ["direction", "high", "low"], "RangeBars": ["open", "close", "direction"],
|
||||
"ThreeLineBreakBars": ["open", "close", "direction"],
|
||||
"ImbalanceBars": ["open", "high", "low", "close", "imbalance", "direction"],
|
||||
"RunBars": ["open", "high", "low", "close", "length", "direction"],
|
||||
"DollarBars": ["open", "high", "low", "close", "volume", "dollar"],
|
||||
"TickBars": ["open", "high", "low", "close", "volume"],
|
||||
"VolumeBars": ["open", "high", "low", "close", "volume"],
|
||||
"Footprint": ["price", "bid_vol", "ask_vol"],
|
||||
}
|
||||
|
||||
|
||||
# cbindgen appends '_' to struct fields that collide with C/C++ reserved words.
|
||||
_C_RESERVED = {"long", "short", "int", "char", "float", "double", "new", "class",
|
||||
"this", "delete", "register", "auto", "const", "void"}
|
||||
|
||||
|
||||
def c_field(name):
|
||||
return name + "_" if name in _C_RESERVED else name
|
||||
|
||||
|
||||
def csv_header(canon):
|
||||
with open(os.path.join(G, "g_" + canon + ".csv"), encoding="utf-8") as f:
|
||||
return f.readline().strip().split(",")
|
||||
|
||||
|
||||
def out_struct(prefix):
|
||||
"""The pointer-to-struct out param type of wickra_<prefix>_update, if any."""
|
||||
_, args = SIG["wickra_" + prefix + "_update"]
|
||||
m = re.search(r"struct (\w+) \*out", args)
|
||||
if m:
|
||||
return "struct " + m.group(1)
|
||||
m = re.search(r"struct (\w+) \*scalars", args)
|
||||
if m:
|
||||
return "struct " + m.group(1)
|
||||
return None
|
||||
|
||||
|
||||
def ctor_casts(prefix, params):
|
||||
_, args = SIG["wickra_" + prefix + "_new"]
|
||||
if not args:
|
||||
return ""
|
||||
types = [a.strip().rsplit(" ", 1)[0].strip() for a in args.split(",")]
|
||||
out = []
|
||||
for t, v in zip(types, params):
|
||||
if t in ("uintptr_t", "intptr_t", "size_t"):
|
||||
out.append(f"(uintptr_t){int(round(v))}")
|
||||
elif t in ("uint8_t",):
|
||||
out.append(f"(uint8_t){int(round(v))}")
|
||||
elif t in ("int32_t",):
|
||||
out.append(f"(int32_t){int(round(v))}")
|
||||
elif t in ("int64_t",):
|
||||
out.append(f"(int64_t){int(round(v))}")
|
||||
else:
|
||||
out.append(repr(float(v)))
|
||||
return ", ".join(out)
|
||||
|
||||
|
||||
def gen_check(canon):
|
||||
s = spec[canon]
|
||||
p = PREFIX[canon]
|
||||
a = s["arch"]
|
||||
new = f"wickra_{p}_new({ctor_casts(p, s['params'])})"
|
||||
upd = f"wickra_{p}_update"
|
||||
L = [f"static int check_{canon}(void) {{",
|
||||
f" struct {struct_name(p)} *h = {new};",
|
||||
f' if (!h) {{ printf("FAIL {canon}: new returned NULL\\n"); return 1; }}',
|
||||
f" double **exp; int rows = read_fixture(\"g_{canon}\", &exp);",
|
||||
" int fails = 0;",
|
||||
" for (int i = 0; i < N_INPUT; i++) {",
|
||||
" double o = IN[i][0], hi = IN[i][1], lo = IN[i][2], c = IN[i][3], v = IN[i][4];",
|
||||
" (void)o; (void)hi; (void)lo; (void)c; (void)v;",
|
||||
" double got[128]; int gn = 0;"]
|
||||
if a in ("scalar_f64", "multi_f64"):
|
||||
call_args = "h, c"
|
||||
elif a in ("pairwise", "multi_pairwise"):
|
||||
call_args = "h, c, o"
|
||||
elif a in ("scalar_candle", "multi_candle") or a.startswith("profile"):
|
||||
call_args = "h, o, hi, lo, c, v, (int64_t)i"
|
||||
elif a == "trade":
|
||||
call_args = "h, c, v, c >= o, (int64_t)i"
|
||||
elif a == "trademid":
|
||||
call_args = "h, c, v, c >= o, (int64_t)i, (hi + lo) / 2.0"
|
||||
elif a == "ob":
|
||||
L.append(" double bp[5], bs[5], ap[5], asz[5];")
|
||||
L.append(" for (int k = 0; k < 5; k++) { double kf = k + 1; bp[k] = c - 0.1*kf; bs[k] = v/kf; ap[k] = c + 0.1*kf; asz[k] = v*0.9/kf; }")
|
||||
call_args = "h, bp, bs, 5, ap, asz, 5"
|
||||
elif a == "cross":
|
||||
L.append(" double chg[5], vol[5]; bool nh[5], nl[5], am[5], ob[5];")
|
||||
L.append(" for (int j = 0; j < 5; j++) { chg[j] = (c-o)+j; vol[j] = v + j*10.0; nh[j] = (j%2==0); nl[j] = (j%3==0); am[j] = (j%2==0); ob[j] = (j%3==0); }")
|
||||
call_args = "h, chg, vol, nh, nl, am, ob, 5, (int64_t)i"
|
||||
elif a in ("deriv", "deriv_multi"):
|
||||
L.append(" double fr=(c-o)/c*0.01, mp=c, ip=c-0.5, fp=c+1.0, oi=v*10.0, ls=v*0.6, ss=v*0.4, tbv=v*0.55, tsv=v*0.45, ll=hi-c, sl=c-lo;")
|
||||
call_args = "h, fr, mp, ip, fp, oi, ls, ss, tbv, tsv, ll, sl, (int64_t)i"
|
||||
elif a == "bars_close":
|
||||
call_args = "h, c, c, c, c, 1.0, 0"
|
||||
elif a == "bars_candle4":
|
||||
call_args = "h, o, hi, lo, c, 1.0, 0"
|
||||
elif a == "bars_candle5":
|
||||
call_args = "h, o, hi, lo, c, v, 0"
|
||||
elif a == "footprint":
|
||||
call_args = "h, c, v, c >= o, (int64_t)i"
|
||||
else:
|
||||
raise SystemExit("arch " + a)
|
||||
|
||||
# output handling
|
||||
if a in ("scalar_f64", "scalar_candle", "pairwise", "trade", "trademid", "ob", "cross", "deriv"):
|
||||
L.append(f" got[gn++] = {upd}({call_args});")
|
||||
elif a in ("multi_f64", "multi_candle", "multi_pairwise", "deriv_multi"):
|
||||
st = out_struct(p)
|
||||
fields = csv_header(canon)
|
||||
L.append(f" {st} out;")
|
||||
L.append(f" if ({upd}({call_args}, &out)) {{")
|
||||
for f in fields:
|
||||
L.append(f" got[gn++] = out.{c_field(f)};")
|
||||
L.append(" } else {")
|
||||
L.append(f" for (int z = 0; z < {len(fields)}; z++) got[gn++] = NANV;")
|
||||
L.append(" }")
|
||||
elif a == "profile_bins":
|
||||
w = s["width"]
|
||||
L.append(" double vbuf[256];")
|
||||
L.append(f" intptr_t k = {upd}({call_args}, vbuf, 256);")
|
||||
L.append(f" if (k < 0) {{ for (int z = 0; z < {w}; z++) got[gn++] = NANV; }}")
|
||||
L.append(f" else {{ for (int z = 0; z < {w}; z++) got[gn++] = vbuf[z]; }}")
|
||||
elif a == "profile_pricebins":
|
||||
w = s["width"]
|
||||
st = out_struct(p)
|
||||
L.append(" double vbuf[256];")
|
||||
L.append(f" {st} sc;")
|
||||
L.append(f" intptr_t k = {upd}({call_args}, &sc, vbuf, 256);")
|
||||
L.append(f" if (k < 0) {{ for (int z = 0; z < {w}; z++) got[gn++] = NANV; }}")
|
||||
L.append(" else { got[gn++] = sc.price_low; got[gn++] = sc.price_high;")
|
||||
L.append(f" for (int z = 0; z < {w - 2}; z++) got[gn++] = vbuf[z]; }}")
|
||||
else: # bars_* / footprint
|
||||
elem = out_struct(p)
|
||||
fields = BAR_FIELDS[canon]
|
||||
cap = 256
|
||||
L.append(f" {elem} bbuf[{cap}];")
|
||||
if a == "footprint":
|
||||
L.append(f" intptr_t k = {upd}({call_args}, bbuf, {cap});")
|
||||
L.append(" if (k < 0) k = 0;")
|
||||
else:
|
||||
L.append(f" uintptr_t k = {upd}({call_args}, bbuf, {cap});")
|
||||
L.append(" for (uintptr_t b = 0; b < (uintptr_t)k; b++) {")
|
||||
for f in fields:
|
||||
L.append(f" got[gn++] = (double)bbuf[b].{f};")
|
||||
L.append(" }")
|
||||
|
||||
L.append(" fails += cmp_row(\"" + canon + "\", i, exp[i], EXPLEN[i], got, gn);")
|
||||
L.append(" }")
|
||||
L.append(" free_fixture(exp, rows);")
|
||||
L.append(f" wickra_{p}_free(h);")
|
||||
L.append(" return fails;")
|
||||
L.append("}")
|
||||
return "\n".join(L)
|
||||
|
||||
|
||||
def struct_name(prefix):
|
||||
ret, _ = SIG["wickra_" + prefix + "_new"]
|
||||
m = re.search(r"struct (\w+)", ret)
|
||||
return m.group(1)
|
||||
|
||||
|
||||
HEADER = r'''/* Generated by gen_golden_test.py. DO NOT EDIT.
|
||||
*
|
||||
* Value-parity for the whole 514-indicator catalogue through the Wickra C ABI.
|
||||
* The same source compiles as C (gcc) and C++ (g++) since wickra.h is extern "C".
|
||||
* Each indicator replays the shared golden input and is checked bit-for-bit
|
||||
* against the Rust reference fixtures testdata/golden/g_<Canonical>.csv. */
|
||||
#include <math.h>
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "wickra.h"
|
||||
|
||||
#define NANV (nan(""))
|
||||
#define MAXROWS 512
|
||||
#define MAXCOLS 256
|
||||
|
||||
static double IN[MAXROWS][8];
|
||||
static int N_INPUT = 0;
|
||||
static int EXPLEN[MAXROWS];
|
||||
|
||||
static const char *GDIR = NULL;
|
||||
|
||||
static double parse_cell(const char *s) {
|
||||
if (strcmp(s, "nan") == 0) return NANV;
|
||||
if (strcmp(s, "inf") == 0) return INFINITY;
|
||||
if (strcmp(s, "-inf") == 0) return -INFINITY;
|
||||
return atof(s);
|
||||
}
|
||||
|
||||
static int split_line(char *line, double *out, int max) {
|
||||
int n = 0;
|
||||
char *p = line;
|
||||
while (*p && n < max) {
|
||||
char *comma = strchr(p, ',');
|
||||
if (comma) *comma = '\0';
|
||||
out[n++] = parse_cell(p);
|
||||
if (!comma) break;
|
||||
p = comma + 1;
|
||||
}
|
||||
return n;
|
||||
}
|
||||
|
||||
static FILE *open_fixture(const char *name) {
|
||||
char path[1024];
|
||||
snprintf(path, sizeof(path), "%s/%s.csv", GDIR, name);
|
||||
return fopen(path, "r");
|
||||
}
|
||||
|
||||
static void load_input(void) {
|
||||
FILE *f = open_fixture("input");
|
||||
if (!f) { fprintf(stderr, "cannot open input.csv in %s\n", GDIR); exit(2); }
|
||||
char line[8192];
|
||||
int first = 1;
|
||||
while (fgets(line, sizeof(line), f)) {
|
||||
line[strcspn(line, "\r\n")] = '\0';
|
||||
if (first) { first = 0; continue; }
|
||||
if (line[0] == '\0') continue;
|
||||
N_INPUT += (split_line(line, IN[N_INPUT], 8) > 0);
|
||||
}
|
||||
fclose(f);
|
||||
}
|
||||
|
||||
/* Read a fixture, keeping blank rows (a candle on which no bar closed). */
|
||||
static int read_fixture(const char *name, double ***outp) {
|
||||
FILE *f = open_fixture(name);
|
||||
if (!f) { fprintf(stderr, "cannot open %s.csv\n", name); exit(2); }
|
||||
double **rows = (double **)malloc(sizeof(double *) * MAXROWS);
|
||||
int n = 0, first = 1;
|
||||
char line[8192];
|
||||
while (fgets(line, sizeof(line), f) && n < MAXROWS) {
|
||||
line[strcspn(line, "\r\n")] = '\0';
|
||||
if (first) { first = 0; continue; }
|
||||
double *vals = (double *)malloc(sizeof(double) * MAXCOLS);
|
||||
int c = (line[0] == '\0') ? 0 : split_line(line, vals, MAXCOLS);
|
||||
EXPLEN[n] = c;
|
||||
rows[n++] = vals;
|
||||
}
|
||||
fclose(f);
|
||||
*outp = rows;
|
||||
return n;
|
||||
}
|
||||
|
||||
static void free_fixture(double **rows, int n) {
|
||||
for (int i = 0; i < n; i++) free(rows[i]);
|
||||
free(rows);
|
||||
}
|
||||
|
||||
static int close_to(double g, double w) {
|
||||
if (isnan(w)) return isnan(g);
|
||||
if (isinf(w)) return isinf(g) && ((g > 0) == (w > 0));
|
||||
double tol = 1e-6 * (fabs(w) > 1.0 ? fabs(w) : 1.0);
|
||||
return fabs(g - w) <= tol;
|
||||
}
|
||||
|
||||
static int cmp_row(const char *name, int i, const double *want, int wn, const double *got, int gn) {
|
||||
if (wn != gn) {
|
||||
printf("FAIL %s row %d: arity %d vs %d\n", name, i, gn, wn);
|
||||
return 1;
|
||||
}
|
||||
for (int k = 0; k < wn; k++) {
|
||||
if (!close_to(got[k], want[k])) {
|
||||
printf("FAIL %s row %d col %d: got %g want %g\n", name, i, k, got[k], want[k]);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
'''
|
||||
|
||||
MAIN_HEAD = r'''
|
||||
int main(int argc, char **argv) {
|
||||
GDIR = (argc > 1) ? argv[1] : "testdata/golden";
|
||||
load_input();
|
||||
int total = 0, failed = 0;
|
||||
'''
|
||||
|
||||
out = [HEADER]
|
||||
for canon in canons:
|
||||
out.append(gen_check(canon))
|
||||
out.append(MAIN_HEAD)
|
||||
for canon in canons:
|
||||
out.append(f" total++; if (check_{canon}()) failed++;")
|
||||
out.append(r''' printf("\nC/C++ golden: %d passed, %d failed (of %d)\n", total - failed, failed, total);
|
||||
return failed ? 1 : 0;
|
||||
}''')
|
||||
|
||||
dest = os.path.join(ROOT, "examples", "c", "golden_test.c")
|
||||
open(dest, "w", encoding="utf-8").write("\n".join(out) + "\n")
|
||||
print("generated golden_test.c with", len(canons), "indicators")
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,4 @@
|
||||
// C++ build of the 514-indicator golden parity test. wickra.h is `extern "C"`,
|
||||
// so the generated C runner compiles unchanged under a C++ compiler; this target
|
||||
// proves the C++ binding consumes the same C ABI and computes identical values.
|
||||
#include "golden_test.c"
|
||||
File diff suppressed because it is too large
Load Diff
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
ad_oscillator
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-8.707352694334602
|
||||
-9.55383489048154
|
||||
-10.14583263837026
|
||||
-7.716297064947573
|
||||
-5.415123860960578
|
||||
-2.4582949833648513
|
||||
1.089975121991027
|
||||
4.696280572705112
|
||||
8.134366418062353
|
||||
11.139886165841459
|
||||
13.441608928194814
|
||||
14.831171905898678
|
||||
15.682268342180382
|
||||
15.9374382006224
|
||||
15.375320862892893
|
||||
11.844484625612038
|
||||
8.060314754372618
|
||||
4.217673873654952
|
||||
0.5154190742606168
|
||||
-2.897345501480764
|
||||
-5.727866727021226
|
||||
-7.735401540219346
|
||||
-8.752721804087948
|
||||
-9.182159376975637
|
||||
-6.2632569344388855
|
||||
-3.1449666933596028
|
||||
-0.30319497786799054
|
||||
2.9959756573154515
|
||||
6.422574509168438
|
||||
9.675090799346341
|
||||
12.465531880413298
|
||||
14.538632000083673
|
||||
15.690164238983918
|
||||
15.79822259186901
|
||||
15.242096487702092
|
||||
14.78004441080553
|
||||
11.364799581360547
|
||||
7.9100904036895905
|
||||
4.222306132949534
|
||||
0.5339213340415121
|
||||
-2.8476220551432476
|
||||
-5.631827518096841
|
||||
-7.747932992047389
|
||||
-9.797710430835835
|
||||
-11.339764291930237
|
||||
-9.268768456321464
|
||||
-6.970170355782635
|
||||
-3.9039149984445523
|
||||
-0.24018851807128883
|
||||
3.553124481651839
|
||||
7.187932205193405
|
||||
10.357360760324106
|
||||
12.796107189912675
|
||||
14.304138194947562
|
||||
14.76455851338833
|
||||
14.345553629020067
|
||||
13.857179803145186
|
||||
9.526827762286814
|
||||
5.950187351572687
|
||||
2.4261734293132875
|
||||
-1.0908438344866767
|
||||
-4.283755254915981
|
||||
-6.864403056782976
|
||||
-8.599321150467368
|
||||
-9.348752590786908
|
||||
-9.97346349734272
|
||||
-7.574008310030209
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
average_drawdown
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.12848591667244894
|
||||
0.11764684482941928
|
||||
0.05343916178664985
|
||||
0.04921355423392666
|
||||
0.04636884595497022
|
||||
0.04514688029877185
|
||||
0.045815749429085506
|
||||
0.048602879867116276
|
||||
0.10712469987165406
|
||||
0.11766221882444922
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.11714256410361094
|
||||
0.106819842069383
|
||||
0.048495266448839086
|
||||
0.04469198482259159
|
||||
0.04221729767595633
|
||||
0.04129261916801016
|
||||
0.04214212542806673
|
||||
0.04493167704509762
|
||||
0.09931745531053977
|
||||
0.10872826720736029
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.10753903894104662
|
||||
0.09766728005121854
|
||||
0.04432515342740658
|
||||
0.0408846402070768
|
||||
0.03872168033510641
|
||||
0.038038413171863426
|
||||
0.03902283524154844
|
||||
0.041793273597892346
|
||||
0.09261212521030097
|
||||
0.10105646093429439
|
||||
0.10395200934035767
|
||||
0.10395200934035767
|
||||
|
@@ -0,0 +1,81 @@
|
||||
awesome_oscillator_histogram
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-2.5465708339042976
|
||||
-2.3455680907694614
|
||||
-1.9183114349650765
|
||||
-1.2944880271234354
|
||||
-0.5275159653568977
|
||||
0.30966275885398886
|
||||
1.1321827319644342
|
||||
1.853304497311072
|
||||
2.3954107601774837
|
||||
2.7001719302630107
|
||||
2.736181583567415
|
||||
2.502786052996541
|
||||
2.0295153145464155
|
||||
1.371319641160568
|
||||
0.600557921537316
|
||||
-0.20278694033696354
|
||||
-0.9609784199580531
|
||||
-1.6069335072552065
|
||||
-2.0900573641307005
|
||||
-2.379022914620819
|
||||
-2.4616730624015304
|
||||
-2.3427633455721946
|
||||
-2.040565227680645
|
||||
-1.5833610703260206
|
||||
-1.0066024302738725
|
||||
-0.3510627241916069
|
||||
0.3381737686129185
|
||||
1.0124404584062603
|
||||
1.6206771076918614
|
||||
2.1117457548869396
|
||||
2.438216711865607
|
||||
2.5614779053997694
|
||||
2.4574975201079496
|
||||
2.122158747547033
|
||||
1.5749095562668458
|
||||
0.8595979048638469
|
||||
0.04178796738165147
|
||||
-0.7975047848210863
|
||||
-1.5710000605662628
|
||||
-2.1959628533200544
|
||||
-2.604933699888676
|
||||
-2.754602894965899
|
||||
-2.631338600597104
|
||||
-2.25246876630203
|
||||
-1.6631866243396303
|
||||
-0.9297348570175075
|
||||
|
Vendored
+91
@@ -0,0 +1,91 @@
|
||||
[
|
||||
{
|
||||
"canonical": "RenkoBars",
|
||||
"native": "RenkoBars",
|
||||
"params": [
|
||||
2.0
|
||||
],
|
||||
"feed": "close"
|
||||
},
|
||||
{
|
||||
"canonical": "KagiBars",
|
||||
"native": "KagiBars",
|
||||
"params": [
|
||||
2.0
|
||||
],
|
||||
"feed": "close"
|
||||
},
|
||||
{
|
||||
"canonical": "PointAndFigureBars",
|
||||
"native": "PointAndFigureBars",
|
||||
"params": [
|
||||
2.0,
|
||||
3
|
||||
],
|
||||
"feed": "close"
|
||||
},
|
||||
{
|
||||
"canonical": "RangeBars",
|
||||
"native": "RangeBars",
|
||||
"params": [
|
||||
2.0
|
||||
],
|
||||
"feed": "close"
|
||||
},
|
||||
{
|
||||
"canonical": "ThreeLineBreakBars",
|
||||
"native": "ThreeLineBreakBars",
|
||||
"params": [
|
||||
3
|
||||
],
|
||||
"feed": "close"
|
||||
},
|
||||
{
|
||||
"canonical": "ImbalanceBars",
|
||||
"native": "ImbalanceBars",
|
||||
"params": [
|
||||
5.0
|
||||
],
|
||||
"feed": "candle4"
|
||||
},
|
||||
{
|
||||
"canonical": "RunBars",
|
||||
"native": "RunBars",
|
||||
"params": [
|
||||
3
|
||||
],
|
||||
"feed": "candle4"
|
||||
},
|
||||
{
|
||||
"canonical": "DollarBars",
|
||||
"native": "DollarBars",
|
||||
"params": [
|
||||
50000.0
|
||||
],
|
||||
"feed": "candle5"
|
||||
},
|
||||
{
|
||||
"canonical": "TickBars",
|
||||
"native": "TickBars",
|
||||
"params": [
|
||||
2
|
||||
],
|
||||
"feed": "candle5"
|
||||
},
|
||||
{
|
||||
"canonical": "VolumeBars",
|
||||
"native": "VolumeBars",
|
||||
"params": [
|
||||
500.0
|
||||
],
|
||||
"feed": "candle5"
|
||||
},
|
||||
{
|
||||
"canonical": "Footprint",
|
||||
"native": "Footprint",
|
||||
"params": [
|
||||
1.0
|
||||
],
|
||||
"feed": "trade"
|
||||
}
|
||||
]
|
||||
Vendored
+364
@@ -0,0 +1,364 @@
|
||||
{
|
||||
"deriv": [
|
||||
{
|
||||
"canonical": "CalendarSpread",
|
||||
"native": "CalendarSpread",
|
||||
"params": [],
|
||||
"args": [
|
||||
"futures_price",
|
||||
"mark_price"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "EstimatedLeverageRatio",
|
||||
"native": "EstimatedLeverageRatio",
|
||||
"params": [],
|
||||
"args": [
|
||||
"open_interest",
|
||||
"long_size",
|
||||
"short_size"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "FundingBasis",
|
||||
"native": "FundingBasis",
|
||||
"params": [],
|
||||
"args": [
|
||||
"mark_price",
|
||||
"index_price"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "FundingImpliedApr",
|
||||
"native": "FundingImpliedApr",
|
||||
"params": [
|
||||
1095.0
|
||||
],
|
||||
"args": [
|
||||
"funding_rate"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "FundingRate",
|
||||
"native": "FundingRate",
|
||||
"params": [],
|
||||
"args": [
|
||||
"funding_rate"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "FundingRateMean",
|
||||
"native": "FundingRateMean",
|
||||
"params": [
|
||||
20
|
||||
],
|
||||
"args": [
|
||||
"funding_rate"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "FundingRateZScore",
|
||||
"native": "FundingRateZScore",
|
||||
"params": [
|
||||
20
|
||||
],
|
||||
"args": [
|
||||
"funding_rate"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "LongShortRatio",
|
||||
"native": "LongShortRatio",
|
||||
"params": [],
|
||||
"args": [
|
||||
"long_size",
|
||||
"short_size"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OpenInterestDelta",
|
||||
"native": "OpenInterestDelta",
|
||||
"params": [],
|
||||
"args": [
|
||||
"open_interest"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OIPriceDivergence",
|
||||
"native": "OIPriceDivergence",
|
||||
"params": [
|
||||
20
|
||||
],
|
||||
"args": [
|
||||
"open_interest",
|
||||
"mark_price"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OiToVolumeRatio",
|
||||
"native": "OiToVolumeRatio",
|
||||
"params": [],
|
||||
"args": [
|
||||
"open_interest",
|
||||
"taker_buy_volume",
|
||||
"taker_sell_volume"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OIWeighted",
|
||||
"native": "OIWeighted",
|
||||
"params": [],
|
||||
"args": [
|
||||
"mark_price",
|
||||
"open_interest"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OpenInterestMomentum",
|
||||
"native": "OpenInterestMomentum",
|
||||
"params": [
|
||||
10
|
||||
],
|
||||
"args": [
|
||||
"open_interest"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "PerpetualPremiumIndex",
|
||||
"native": "PerpetualPremiumIndex",
|
||||
"params": [],
|
||||
"args": [
|
||||
"mark_price",
|
||||
"index_price"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "TakerBuySellRatio",
|
||||
"native": "TakerBuySellRatio",
|
||||
"params": [],
|
||||
"args": [
|
||||
"taker_buy_volume",
|
||||
"taker_sell_volume"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "TermStructureBasis",
|
||||
"native": "TermStructureBasis",
|
||||
"params": [],
|
||||
"args": [
|
||||
"futures_price",
|
||||
"index_price"
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "LiquidationFeatures",
|
||||
"native": "LiquidationFeatures",
|
||||
"params": [],
|
||||
"args": [
|
||||
"long_liquidation",
|
||||
"short_liquidation"
|
||||
],
|
||||
"n": 5
|
||||
}
|
||||
],
|
||||
"cross": [
|
||||
{
|
||||
"canonical": "AbsoluteBreadthIndex",
|
||||
"native": "AbsoluteBreadthIndex",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "AdvanceDecline",
|
||||
"native": "AdvanceDecline",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "AdvanceDeclineRatio",
|
||||
"native": "AdvanceDeclineRatio",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "AdVolumeLine",
|
||||
"native": "AdVolumeLine",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "BreadthThrust",
|
||||
"native": "BreadthThrust",
|
||||
"params": [
|
||||
10
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "BullishPercentIndex",
|
||||
"native": "BullishPercentIndex",
|
||||
"params": [],
|
||||
"extra": "on_buy_signal"
|
||||
},
|
||||
{
|
||||
"canonical": "CumulativeVolumeIndex",
|
||||
"native": "CumulativeVolumeIndex",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "HighLowIndex",
|
||||
"native": "HighLowIndex",
|
||||
"params": [
|
||||
10
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "McClellanOscillator",
|
||||
"native": "McClellanOscillator",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "McClellanSummationIndex",
|
||||
"native": "McClellanSummationIndex",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "NewHighsNewLows",
|
||||
"native": "NewHighsNewLows",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "PercentAboveMa",
|
||||
"native": "PercentAboveMa",
|
||||
"params": [],
|
||||
"extra": "above_ma"
|
||||
},
|
||||
{
|
||||
"canonical": "TickIndex",
|
||||
"native": "TickIndex",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "Trin",
|
||||
"native": "Trin",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "UpDownVolumeRatio",
|
||||
"native": "UpDownVolumeRatio",
|
||||
"params": []
|
||||
}
|
||||
],
|
||||
"trade": [
|
||||
{
|
||||
"canonical": "AmihudIlliquidity",
|
||||
"native": "AmihudIlliquidity",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "CumulativeVolumeDelta",
|
||||
"native": "CumulativeVolumeDelta",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "Pin",
|
||||
"native": "Pin",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "RollMeasure",
|
||||
"native": "RollMeasure",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "SignedVolume",
|
||||
"native": "SignedVolume",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "TradeImbalance",
|
||||
"native": "TradeImbalance",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "TradeSignAutocorrelation",
|
||||
"native": "TradeSignAutocorrelation",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "Vpin",
|
||||
"native": "Vpin",
|
||||
"params": [
|
||||
5000.0,
|
||||
10
|
||||
]
|
||||
}
|
||||
],
|
||||
"trademid": [
|
||||
{
|
||||
"canonical": "KylesLambda",
|
||||
"native": "KylesLambda",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "RealizedSpread",
|
||||
"native": "RealizedSpread",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "EffectiveSpread",
|
||||
"native": "EffectiveSpread",
|
||||
"params": []
|
||||
}
|
||||
],
|
||||
"ob": [
|
||||
{
|
||||
"canonical": "DepthSlope",
|
||||
"native": "DepthSlope",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "Microprice",
|
||||
"native": "Microprice",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "OrderBookImbalanceFull",
|
||||
"native": "OrderBookImbalanceFull",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "OrderBookImbalanceTop1",
|
||||
"native": "OrderBookImbalanceTop1",
|
||||
"params": []
|
||||
},
|
||||
{
|
||||
"canonical": "OrderBookImbalanceTopN",
|
||||
"native": "OrderBookImbalanceTopN",
|
||||
"params": [
|
||||
5
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "OrderFlowImbalance",
|
||||
"native": "OrderFlowImbalance",
|
||||
"params": [
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
"canonical": "QuotedSpread",
|
||||
"native": "QuotedSpread",
|
||||
"params": []
|
||||
}
|
||||
]
|
||||
}
|
||||
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AbandonedBaby
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Abcd
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
-1
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
-1
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AbsoluteBreadthIndex
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
3
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
3
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
upper,middle,lower
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
112.00454229927934,107.082865308575,102.1633636879963
|
||||
111.903996698001,106.96031118542241,102.03702207594756
|
||||
111.48149095236647,106.55098952518925,101.67783115273905
|
||||
110.84753008292738,105.93612732359576,101.12981477034926
|
||||
110.1823135395352,105.21531190077062,100.40326913125591
|
||||
109.5036401798982,104.49759506253974,99.68310613110404
|
||||
108.96140873233165,103.89175182739567,99.03055716743253
|
||||
108.55757771159065,103.49656387805487,98.63355958617213
|
||||
108.37119784452737,103.39199568793734,98.57524233498944
|
||||
108.48123056464149,103.63205153291037,98.8947106702469
|
||||
109.13355090120591,104.23995145016349,99.41036676194948
|
||||
110.16562981720305,105.20605706144154,100.27299449048978
|
||||
111.46754612622676,106.48873254066868,101.51564231169665
|
||||
112.96480536016107,108.01806381828972,103.07772074367713
|
||||
114.59091724799116,109.7021037968819,104.84319176799882
|
||||
116.31238287778524,111.4350857115261,106.62930322893273
|
||||
118.02171523469391,113.10687095991703,108.31262995838041
|
||||
119.60041387832072,114.61278745568676,109.79025736162829
|
||||
120.86843833251953,115.86297967414018,111.04856243742181
|
||||
121.84199343121688,116.79043517866376,111.93416142447509
|
||||
122.39011307800129,117.35697064210828,112.49710053406037
|
||||
122.50576329657846,117.55664264968355,112.73761870284666
|
||||
122.28492982985878,117.41627860650068,112.6261751502832
|
||||
121.88410160023147,116.99308032537222,112.13535105079109
|
||||
121.32841892406745,116.36951435923494,111.41502979189917
|
||||
120.62769249435505,115.64594550958222,110.66031870509737
|
||||
119.88266208381762,114.93167153765809,109.99034859761083
|
||||
119.21334803236513,114.33515992096163,109.49959706481589
|
||||
118.84010683817569,113.9543587765253,109.15910992089735
|
||||
118.84698966435758,113.86794744733447,109.03065352633098
|
||||
119.18085830401883,114.12830831094557,109.25699419733856
|
||||
119.81567295627272,114.75684761770661,109.89580906685411
|
||||
120.76326521267524,115.742083334167,110.90944997004836
|
||||
122.03354824467185,117.04067079892921,112.20463572045877
|
||||
123.49186499228664,118.58127457216008,113.77854615433921
|
||||
125.15541127136517,120.2709406179764,115.44316740240318
|
||||
126.89365061452054,122.00339961162967,117.12777224548434
|
||||
128.6218453824203,123.66855966178939,118.70771114897195
|
||||
130.13799798652042,125.16234049131411,120.17901541980844
|
||||
131.34234704048916,126.39597061843133,121.46331658347619
|
||||
132.17765388899457,127.30391704882051,122.48228740200413
|
||||
132.7172572879352,127.84973914282192,123.08320478902942
|
||||
133.0219100353167,128.0293437492481,123.186349583904
|
||||
132.93455091218237,127.87135083438908,122.98973058574394
|
||||
132.4939509772264,127.43453694566097,122.56345976084957
|
||||
131.7887631702729,126.80258487767678,121.98496441162513
|
||||
131.0247690118917,126.07660853743191,121.25860807195049
|
||||
130.27164555235746,125.36612074013492,120.54153378663992
|
||||
129.71654667609008,124.7792507555816,119.87723904323487
|
||||
129.3572609063708,124.41308544252024,119.47022304519386
|
||||
129.28815104427278,124.34499676870873,119.38979732374698
|
||||
129.59013620461823,124.62573040346784,119.66083649483392
|
||||
130.21456383897035,125.27487275817427,120.3659767873086
|
||||
131.15508993875173,126.27910139046546,121.47771946198786
|
||||
132.48808298835723,127.59337505833837,122.8220665703464
|
||||
134.1585043208085,129.14495712015346,124.29662222632264
|
||||
135.91624586992114,130.83991288220435,125.9496633545152
|
||||
137.633736076585,132.57150050514548,127.68916465275844
|
||||
139.20567865090607,134.2297059345968,129.4023242200996
|
||||
140.5859255352183,135.71107012897224,130.93779292244716
|
||||
141.81250366072146,136.92793074753726,132.09525917422252
|
||||
142.754364932275,137.81625276622648,132.88840979194248
|
||||
143.28785588129955,138.34134853563094,133.37899646988078
|
||||
143.41286127577334,138.50097632541122,133.56914778640777
|
||||
143.2542302257144,138.3255405713923,133.39865072137914
|
||||
142.78440791301847,137.87537593786334,133.0076223601965
|
||||
142.13787741350674,137.23535780170852,132.42316873592566
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AcceleratorOscillator
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
3.2996426213220005
|
||||
4.84857752293012
|
||||
5.924729552970451
|
||||
6.4545834557331245
|
||||
6.417599965248506
|
||||
5.841491144321343
|
||||
4.793768911659682
|
||||
3.371784844238129
|
||||
1.693113062779183
|
||||
-0.11263924144573112
|
||||
-1.9104284181475686
|
||||
-3.565408328921929
|
||||
-4.948672473753007
|
||||
-5.944134608210268
|
||||
-6.457067844127186
|
||||
-6.42398764082675
|
||||
-5.822647879910184
|
||||
-4.680198146699931
|
||||
-3.077262896534226
|
||||
-1.1459856324778537
|
||||
0.9390716309573922
|
||||
2.977022592953248
|
||||
4.762184239467388
|
||||
6.108237527367101
|
||||
6.871445963232525
|
||||
6.969248178937781
|
||||
6.391155144004517
|
||||
5.200116229259413
|
||||
3.5241270343523365
|
||||
1.5395065973679496
|
||||
-0.5513672052550485
|
||||
-2.544280250134392
|
||||
-4.255694561664433
|
||||
-5.540493964000969
|
||||
-6.303047113055063
|
||||
-6.501064809232347
|
||||
-6.143054116879824
|
||||
-5.281144907173644
|
||||
-4.001499867843839
|
||||
-2.4143724895006917
|
||||
-0.6452508608341481
|
||||
1.172364605777252
|
||||
2.9028805802986506
|
||||
4.414169016213934
|
||||
5.583872284129307
|
||||
6.30723799169914
|
||||
6.506541398243506
|
||||
6.141237785716633
|
||||
5.217152119335765
|
||||
3.792521891431367
|
||||
1.9787464662015921
|
||||
-0.06568115261740415
|
||||
-2.148468704480384
|
||||
-4.063069029679891
|
||||
-5.6121489252116135
|
||||
-6.631657364309163
|
||||
-7.011766147952425
|
||||
-6.71127327720228
|
||||
-5.763057971508655
|
||||
-4.2696655766952825
|
||||
-2.3897786374432184
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdOscillator
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-8.707352694334602
|
||||
-9.55383489048154
|
||||
-10.14583263837026
|
||||
-7.716297064947573
|
||||
-5.415123860960578
|
||||
-2.4582949833648513
|
||||
1.089975121991027
|
||||
4.696280572705112
|
||||
8.134366418062353
|
||||
11.139886165841459
|
||||
13.441608928194814
|
||||
14.831171905898678
|
||||
15.682268342180382
|
||||
15.9374382006224
|
||||
15.375320862892893
|
||||
11.844484625612038
|
||||
8.060314754372618
|
||||
4.217673873654952
|
||||
0.5154190742606168
|
||||
-2.897345501480764
|
||||
-5.727866727021226
|
||||
-7.735401540219346
|
||||
-8.752721804087948
|
||||
-9.182159376975637
|
||||
-6.2632569344388855
|
||||
-3.1449666933596028
|
||||
-0.30319497786799054
|
||||
2.9959756573154515
|
||||
6.422574509168438
|
||||
9.675090799346341
|
||||
12.465531880413298
|
||||
14.538632000083673
|
||||
15.690164238983918
|
||||
15.79822259186901
|
||||
15.242096487702092
|
||||
14.78004441080553
|
||||
11.364799581360547
|
||||
7.9100904036895905
|
||||
4.222306132949534
|
||||
0.5339213340415121
|
||||
-2.8476220551432476
|
||||
-5.631827518096841
|
||||
-7.747932992047389
|
||||
-9.797710430835835
|
||||
-11.339764291930237
|
||||
-9.268768456321464
|
||||
-6.970170355782635
|
||||
-3.9039149984445523
|
||||
-0.24018851807128883
|
||||
3.553124481651839
|
||||
7.187932205193405
|
||||
10.357360760324106
|
||||
12.796107189912675
|
||||
14.304138194947562
|
||||
14.76455851338833
|
||||
14.345553629020067
|
||||
13.857179803145186
|
||||
9.526827762286814
|
||||
5.950187351572687
|
||||
2.4261734293132875
|
||||
-1.0908438344866767
|
||||
-4.283755254915981
|
||||
-6.864403056782976
|
||||
-8.599321150467368
|
||||
-9.348752590786908
|
||||
-9.97346349734272
|
||||
-7.574008310030209
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdVolumeLine
|
||||
5100
|
||||
10299.33466539753
|
||||
15594.043836551855
|
||||
20976.365073249373
|
||||
24291.57190051923
|
||||
27644.013195961597
|
||||
31023.624921751765
|
||||
34419.2598407483
|
||||
37819.13192166075
|
||||
41211.28621092421
|
||||
46765.93492433705
|
||||
52270.18312624685
|
||||
57707.91471652242
|
||||
63065.66540243315
|
||||
68333.1594775111
|
||||
73503.71948154103
|
||||
76621.23172456931
|
||||
79797.89405517736
|
||||
83030.6501881658
|
||||
86314.20755544862
|
||||
89641.248304041
|
||||
93002.72103576508
|
||||
98578.52207270983
|
||||
104175.36757452656
|
||||
109773.44987894449
|
||||
115352.91201627607
|
||||
120894.63934413614
|
||||
126381.02158791413
|
||||
131796.65490685028
|
||||
135036.0355606744
|
||||
138219.8602101341
|
||||
141344.78703097935
|
||||
144479.7517924345
|
||||
147673.2142014885
|
||||
150921.44820683007
|
||||
156349.94150618947
|
||||
161846.77543811404
|
||||
167396.12948601984
|
||||
172980.08932203558
|
||||
178579.36099472287
|
||||
184174.04011803455
|
||||
187556.25928503848
|
||||
190912.63895746498
|
||||
194232.95808682722
|
||||
197508.43324469475
|
||||
200732.06879026728
|
||||
203898.93576449735
|
||||
207006.36839213336
|
||||
212193.53178274486
|
||||
217476.7713473708
|
||||
222848.7819028155
|
||||
228298.71924661228
|
||||
233812.6324811551
|
||||
239374.0201919615
|
||||
242768.30106098144
|
||||
246168.29812294664
|
||||
249562.05144169205
|
||||
252937.84999939144
|
||||
256284.69857788205
|
||||
259592.7561033152
|
||||
264961.0425623154
|
||||
270240.1572034338
|
||||
275422.95929115795
|
||||
280539.7708147685
|
||||
285755.5257273193
|
||||
291065.6092457326
|
||||
294343.23130014475
|
||||
297665.34406713047
|
||||
301023.09261158743
|
||||
304406.20131242066
|
||||
307803.38351912913
|
||||
311202.79151494405
|
||||
314592.48884790885
|
||||
320139.8844339791
|
||||
325634.0104676668
|
||||
331059.15438774537
|
||||
336402.3537321723
|
||||
341653.9129105451
|
||||
346807.78973669483
|
||||
349935.36179176316
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdaptiveCci
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-122.65932429363109
|
||||
-133.88668580463195
|
||||
-113.02705394625994
|
||||
-77.66651779474725
|
||||
-48.732497663476664
|
||||
-21.18701458111578
|
||||
14.464476048711363
|
||||
63.7498974942403
|
||||
119.55850588636753
|
||||
158.12624691909662
|
||||
155.93668349002763
|
||||
119.4644501737837
|
||||
80.98977660363701
|
||||
50.12418566001646
|
||||
28.769451665108374
|
||||
15.945936381492855
|
||||
5.797635581633111
|
||||
-7.985894839175672
|
||||
-31.32180736058029
|
||||
-67.76349174063863
|
||||
-113.52265555723903
|
||||
-153.63031825456432
|
||||
-164.57812436122686
|
||||
-141.19950188039596
|
||||
-93.89399779495514
|
||||
-58.93580593705932
|
||||
-28.964575685198387
|
||||
8.479581679404008
|
||||
60.96327793734739
|
||||
119.727640109343
|
||||
160.25838783673703
|
||||
156.65003208401043
|
||||
120.9645229411653
|
||||
83.19083486418182
|
||||
52.21185642827945
|
||||
29.710899388112153
|
||||
15.90106536136664
|
||||
4.632431470611363
|
||||
-10.49668161617313
|
||||
-34.092332804631
|
||||
-68.85764305101857
|
||||
-110.91366692761622
|
||||
-145.53858818049181
|
||||
-152.27741914929015
|
||||
-123.91605869927966
|
||||
-81.6575011080737
|
||||
-50.227373446032985
|
||||
-22.602091834240422
|
||||
14.130027328942072
|
||||
67.64350671317011
|
||||
128.8601745865182
|
||||
168.11894618602497
|
||||
158.98336615249485
|
||||
116.42426303201626
|
||||
77.51768761909821
|
||||
47.73878698301638
|
||||
27.106145176706637
|
||||
14.448890581501455
|
||||
3.2412829210323824
|
||||
-12.9509083301616
|
||||
-38.7974683790103
|
||||
-75.92793042139692
|
||||
-118.57866433718134
|
||||
-151.41479497725533
|
||||
-156.55830047724308
|
||||
-130.46899939083355
|
||||
-87.59619020494708
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdaptiveCycle
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
10
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
11
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AdaptiveLaguerreFilter
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
70.36315138959995
|
||||
78.74037822895473
|
||||
85.2511055850559
|
||||
91.35623993456784
|
||||
96.75393648889109
|
||||
101.5184674632918
|
||||
105.78493292584325
|
||||
109.59267337985727
|
||||
112.84532232094348
|
||||
115.43688389641382
|
||||
117.34248629710474
|
||||
118.71019369671158
|
||||
119.6285401106491
|
||||
119.95470335454927
|
||||
119.63198931022981
|
||||
118.64724383936762
|
||||
117.03203518798995
|
||||
114.88737965830558
|
||||
112.51533439162829
|
||||
110.67595764168868
|
||||
109.92836088554839
|
||||
110.19512740947611
|
||||
111.33548760014536
|
||||
113.09087288002077
|
||||
115.21301966341899
|
||||
117.44854086808137
|
||||
119.50367382837953
|
||||
121.01360330671169
|
||||
122.44003487664212
|
||||
123.85938597996163
|
||||
125.03997921372257
|
||||
126.14207117364798
|
||||
127.12412582020283
|
||||
127.86474457202415
|
||||
128.4401133291739
|
||||
128.88138427555603
|
||||
129.02308234483806
|
||||
128.8356142768824
|
||||
128.44526498877397
|
||||
127.95435268490394
|
||||
127.36821878611492
|
||||
126.73752371917863
|
||||
126.1172553408605
|
||||
125.49445893321506
|
||||
124.944581234822
|
||||
124.71490944932616
|
||||
124.92704154993311
|
||||
125.94368398793198
|
||||
127.83627734198971
|
||||
130.30693864945556
|
||||
133.00924563039118
|
||||
135.27780029407577
|
||||
137.26001287517218
|
||||
138.97584508585103
|
||||
140.05428529486406
|
||||
140.45903219597125
|
||||
140.1933436307999
|
||||
139.327160620978
|
||||
138.02605504825928
|
||||
136.42776473287265
|
||||
134.8089415424083
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdaptiveRsi
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
46.84518809898698
|
||||
46.251508261108434
|
||||
47.16390505862828
|
||||
52.37840674196512
|
||||
59.99655348995708
|
||||
65.48173017151746
|
||||
67.87766558168431
|
||||
68.43252618174914
|
||||
69.44810126271067
|
||||
72.08923275029326
|
||||
75.98552161484294
|
||||
80.06100840049977
|
||||
83.23119418239398
|
||||
84.2021581284505
|
||||
64.18998557492546
|
||||
38.11253923390308
|
||||
24.206580981003462
|
||||
17.89126638064292
|
||||
15.14203902910592
|
||||
14.106875948739164
|
||||
13.864776873313172
|
||||
13.738263243026974
|
||||
13.541416546295668
|
||||
15.582834404230711
|
||||
25.551997416225987
|
||||
38.90351978905494
|
||||
47.87795916253466
|
||||
51.609552476213786
|
||||
52.41576532276687
|
||||
54.211150479807365
|
||||
58.63178532791585
|
||||
64.88830071694787
|
||||
71.18719210199839
|
||||
75.89718031499687
|
||||
77.06051801176152
|
||||
56.70404367017364
|
||||
33.03499604424107
|
||||
20.95990137747064
|
||||
15.559560905802472
|
||||
13.231276347511777
|
||||
12.369529816925409
|
||||
12.177638647512682
|
||||
12.057088772323254
|
||||
11.889220459392881
|
||||
14.35885131749288
|
||||
25.02300188856863
|
||||
38.60359057255842
|
||||
47.43890026667333
|
||||
51.00845544677639
|
||||
51.72909528131173
|
||||
53.6981191944954
|
||||
58.34293313057035
|
||||
64.76247938510097
|
||||
71.11470034710942
|
||||
75.7623864114642
|
||||
76.61451286201687
|
||||
54.87238337757311
|
||||
31.754916459579274
|
||||
20.25339618069728
|
||||
15.14160101060116
|
||||
12.951047969220278
|
||||
12.153552755102773
|
||||
11.985049462216475
|
||||
11.857867615700993
|
||||
11.700250095535777
|
||||
14.57777691287174
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Adl
|
||||
333.3333333333333
|
||||
587.469676284863
|
||||
746.681856548535
|
||||
772.153119497146
|
||||
610.038433924341
|
||||
334.4744473662835
|
||||
54.2091273279641
|
||||
-208.29753141933998
|
||||
-427.1711246545661
|
||||
-531.0152129735706
|
||||
-425.7814575313156
|
||||
-218.5866956835259
|
||||
50.11272016402873
|
||||
361.7112327407009
|
||||
611.4105453303878
|
||||
720.3662064954124
|
||||
673.5295760026064
|
||||
481.80062857551377
|
||||
158.70068139778397
|
||||
-129.889283477591
|
||||
-365.5677042872865
|
||||
-521.2254595472434
|
||||
-519.1250236675922
|
||||
-333.6937625669905
|
||||
-85.01753291738578
|
||||
190.18075952672433
|
||||
471.370101273559
|
||||
713.6426286531366
|
||||
765.2156727431039
|
||||
654.2693034702239
|
||||
437.127987752305
|
||||
135.00533364490457
|
||||
-153.74542546397385
|
||||
-355.06929881269167
|
||||
-444.00152074404275
|
||||
-360.8020461135121
|
||||
-99.49409085725023
|
||||
182.30234196937204
|
||||
454.53637831178025
|
||||
696.1168445937468
|
||||
863.5143925551931
|
||||
828.590153670103
|
||||
656.274435408461
|
||||
410.38451690257807
|
||||
114.53595695361508
|
||||
-192.94098694811032
|
||||
-361.1129271451715
|
||||
-381.40582427334715
|
||||
-248.28402591513859
|
||||
24.808963821476567
|
||||
330.4563800146842
|
||||
590.3159189010076
|
||||
784.3398907418045
|
||||
864.1606112551432
|
||||
730.0966410278963
|
||||
501.0239122163847
|
||||
234.15055048353526
|
||||
-47.20141395248396
|
||||
-318.296312591874
|
||||
-448.3573646076187
|
||||
-395.42992091150387
|
||||
-218.60193516559048
|
||||
49.789135579036724
|
||||
370.8715732562906
|
||||
610.3733487454008
|
||||
750.9789503536324
|
||||
745.9765727661561
|
||||
551.5872128968012
|
||||
272.9342803720846
|
||||
-5.675917425997227
|
||||
-263.15532575372094
|
||||
-470.11007471398796
|
||||
-532.1418578899545
|
||||
-404.67318016913936
|
||||
-185.33679765818127
|
||||
91.73355055592063
|
||||
408.6054983955447
|
||||
634.893433571831
|
||||
719.2201222699915
|
||||
646.7650424131407
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdvanceBlock
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AdvanceDecline
|
||||
5
|
||||
10
|
||||
15
|
||||
20
|
||||
23
|
||||
26
|
||||
29
|
||||
32
|
||||
35
|
||||
38
|
||||
43
|
||||
48
|
||||
53
|
||||
58
|
||||
63
|
||||
68
|
||||
71
|
||||
74
|
||||
77
|
||||
80
|
||||
83
|
||||
86
|
||||
91
|
||||
96
|
||||
101
|
||||
106
|
||||
111
|
||||
116
|
||||
121
|
||||
124
|
||||
127
|
||||
130
|
||||
133
|
||||
136
|
||||
139
|
||||
144
|
||||
149
|
||||
154
|
||||
159
|
||||
164
|
||||
169
|
||||
172
|
||||
175
|
||||
178
|
||||
181
|
||||
184
|
||||
187
|
||||
190
|
||||
195
|
||||
200
|
||||
205
|
||||
210
|
||||
215
|
||||
220
|
||||
223
|
||||
226
|
||||
229
|
||||
232
|
||||
235
|
||||
238
|
||||
243
|
||||
248
|
||||
253
|
||||
258
|
||||
263
|
||||
268
|
||||
271
|
||||
274
|
||||
277
|
||||
280
|
||||
283
|
||||
286
|
||||
289
|
||||
294
|
||||
299
|
||||
304
|
||||
309
|
||||
314
|
||||
319
|
||||
322
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AdvanceDeclineRatio
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
4
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
5
|
||||
4
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
plus_di,minus_di,adx
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
39.5757019682593,10.51553170206367,30.912276792040817
|
||||
37.536261624936586,10.906948307963743,32.63069750889788
|
||||
35.215165462446194,12.883060473369223,33.61637662813429
|
||||
32.86410166086221,15.606658308025656,33.758337048896145
|
||||
30.70333902684003,18.50628500756431,33.11744953242373
|
||||
28.583754140794692,21.990805693589266,31.683067176177246
|
||||
26.55934622279741,25.269437743189002,29.597761510222966
|
||||
24.849750313093512,27.34663879718962,27.82532441495794
|
||||
23.505186308008465,28.419972295720065,26.513882262566277
|
||||
22.24831894567969,28.255382095825222,25.469626589930424
|
||||
21.991214452481188,26.24217101526044,24.279889509686143
|
||||
23.0167314852192,24.206077112686202,22.725510472977113
|
||||
25.270075861089534,22.49633154108633,21.51703781909767
|
||||
28.167925277844184,20.797978949255484,21.055190823958306
|
||||
32.199512135355,19.002819811263755,21.39222118044018
|
||||
36.67556284467224,17.08189161927664,22.467654445091764
|
||||
39.66767810504092,15.312333278446436,24.027003737037383
|
||||
41.25710485757308,13.864063299710923,25.86050681733179
|
||||
41.90255145462447,12.778588478409224,27.8177163877859
|
||||
42.395628716412624,11.937994453509367,29.834786399099126
|
||||
41.39315313749411,11.291691494482587,31.784798356703554
|
||||
38.98369312390027,10.942263455121635,33.52631517717672
|
||||
36.80520205991526,11.790866997951634,34.808291852450445
|
||||
34.33471861125097,14.165199105275695,35.29246448522293
|
||||
31.575896425438806,17.056390539549085,34.90412360474046
|
||||
29.011655429985023,19.499990165743316,33.81146999165209
|
||||
26.941362744011517,21.41861333571675,32.21208520671275
|
||||
25.293388618220902,23.528371409730532,30.16945244226847
|
||||
23.70108159294569,26.085794270270323,28.356623123061247
|
||||
21.9818825371455,26.753559469925122,27.030505691607747
|
||||
20.4556018343849,25.575479039846915,25.894230469505597
|
||||
19.315305653157523,24.149775639951073,24.839117763267886
|
||||
20.15346427198841,22.836532180755725,23.510691119817217
|
||||
22.621623373749483,21.279561359099215,22.049713637827605
|
||||
26.102172398824052,19.564946484191104,21.497230627213543
|
||||
29.5794011460886,17.914862734831026,21.71599192763469
|
||||
33.103914522491884,16.421886804841026,22.570814571368153
|
||||
36.988461875248944,14.998303176938437,23.980008725527608
|
||||
39.75301194225335,13.75986552582622,25.73669586768207
|
||||
41.37315229671887,12.777991517838071,27.67023180773477
|
||||
42.48135161688847,11.981093863498268,29.693955639647385
|
||||
42.62294720176041,11.257736731480932,31.730983563876975
|
||||
40.47684671425082,10.451870979556956,33.67554918447296
|
||||
37.62379013468778,11.104415435913893,35.1575133843429
|
||||
35.445073236866044,12.840589537363048,35.99012453099969
|
||||
33.361147221464314,15.58241905716853,36.014040954862004
|
||||
30.784559395666363,20.10967847345435,34.9397977135121
|
||||
28.101022653590128,23.891333482064333,33.02243689823779
|
||||
25.724805235133402,26.22784634752717,30.732853434649453
|
||||
23.898483996930594,27.16675703876092,28.994806129209827
|
||||
22.507592062957475,27.59047661188655,27.648453495608493
|
||||
21.169522519356338,26.35196828602853,26.452526680749255
|
||||
21.224977830554703,24.775436644747092,25.11436900225873
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Adxr
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
25.983733807999563
|
||||
27.01145934466903
|
||||
28.04201553661303
|
||||
28.892670392966764
|
||||
29.488978174877758
|
||||
29.750391781981573
|
||||
29.716273954661048
|
||||
29.805061385830747
|
||||
30.0200987198715
|
||||
30.138959221190433
|
||||
29.786176997454536
|
||||
28.814817038858788
|
||||
27.664253905374878
|
||||
26.633638015335528
|
||||
25.780836811354327
|
||||
25.412138784076504
|
||||
25.528754714322567
|
||||
25.87736864341869
|
||||
26.328417075526893
|
||||
26.67273875945817
|
||||
26.917255997265578
|
||||
27.511772902195133
|
||||
28.262141890042567
|
||||
28.93163952829554
|
||||
29.442066165134037
|
||||
29.77408292966708
|
||||
29.94115850722376
|
||||
29.931704040957925
|
||||
30.04380334346911
|
||||
30.353027438040357
|
||||
30.525871926924246
|
||||
30.414621147133786
|
||||
29.76236603733961
|
||||
28.49475567566985
|
||||
27.25983376272567
|
||||
26.224422681142073
|
||||
25.78281035028899
|
||||
25.814231110568052
|
||||
26.094611274215662
|
||||
26.39230040499675
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
jaw,teeth,lips
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
103.1558507984203,105.79078781985666,107.03252484838644
|
||||
101.40633091517769,104.66457400969036,106.38072244126543
|
||||
100.12134766492898,103.6484036032248,105.75005520720586
|
||||
99.45126641946796,102.85736079255639,105.20441583015872
|
||||
99.48179732233366,102.38386055477191,104.80001892286633
|
||||
100.23050496668327,102.29015479771627,104.58058330376035
|
||||
101.65091352849612,102.60466563405991,104.57423668578618
|
||||
103.64240261318041,103.32191065527263,104.79217554984066
|
||||
106.06357089840077,104.40533877149676,105.22887068691215
|
||||
108.74678086098042,105.79217620216004,105.86346569399983
|
||||
111.51210232882211,107.39940035392367,106.66198566332166
|
||||
114.17965210558982,109.13016482609532,107.58004037730764
|
||||
116.58013494644592,110.88029851210429,108.56583039522552
|
||||
118.5639933186376,112.54478587652095,109.56339322863947
|
||||
120.0098081380237,114.02430757656022,110.51611069636495
|
||||
120.83241224927542,115.2319237044486,111.37050425175165
|
||||
120.99065964425567,116.09981380870111,112.08026497907055
|
||||
120.49411603245278,116.5857016658648,112.61031953834029
|
||||
119.4073343437952,116.67828299452412,112.94056606892171
|
||||
117.85007687184077,116.40075141358238,113.068780058851
|
||||
115.99199777822656,115.81147829607036,113.01214145400436
|
||||
114.04094344984783,115.0011006527875,112.80690526393907
|
||||
112.22506977279107,114.08570376220037,112.50593506070611
|
||||
110.77020629693173,113.19638598834503,112.17411679531374
|
||||
109.87504142164983,112.46614680016516,111.88201642929747
|
||||
109.68748175918653,112.01560617646442,111.69846971536622
|
||||
110.2857400647586,111.93941339066988,111.6830259268331
|
||||
111.66723663953537,112.29524430472975,111.87925477413708
|
||||
113.74731238301733,113.09698995690853,112.30984113812596
|
||||
116.3682399561194,114.31314783482495,112.97414499271152
|
||||
119.3173733891288,115.87064675201391,113.84853751145694
|
||||
122.35182077950905,117.66351372462186,114.88940737208642
|
||||
125.22604604819371,119.5650827047563,116.03834231590618
|
||||
127.71848843366506,121.44198134759222,117.22870166509915
|
||||
129.65367446726884,123.16799066000424,118.39265487005467
|
||||
130.91727906545398,124.63606174597852,119.46778582660964
|
||||
131.46294056512707,125.76723343433491,120.40253423645706
|
||||
131.3110527086312,126.51581108594984,121.16001586211293
|
||||
130.5409511975122,126.87080209871046,121.72006817019587
|
||||
129.27865975228482,126.85412706487041,122.07964021959832
|
||||
127.68255537687806,126.516444145041,122.2518335343459
|
||||
125.92898676471277,125.93150205866118,122.26397753477707
|
||||
124.19918786337472,125.18980034466652,122.15509271520004
|
||||
122.66800277469706,124.39206209504869,121.9729884210673
|
||||
121.49422604547935,123.64272073676229,121.77110871863705
|
||||
120.81196235036562,123.04339419724455,121.60513202160142
|
||||
120.72241993610164,122.68624289872014,121.52928938488516
|
||||
121.28594722651424,122.64720845709432,121.59241170077475
|
||||
122.51476018956932,122.97937669403505,121.83383844469651
|
||||
124.3674708609567,123.70702176684883,122.27948514177044
|
||||
126.74697821540099,124.82116050362607,122.93852141195036
|
||||
129.5033313462492,126.27757151852889,123.80120114023575
|
||||
132.44273182319031,127.99813741260654,124.83836768572408
|
||||
135.34294646502107,129.87602860347457,126.00301111879254
|
||||
137.9742186094954,131.78470493132735,127.23399338876766
|
||||
140.12355045260327,133.59006338954046,128.46172344234276
|
||||
141.619267087984,135.1644400994269,129.6152217935144
|
||||
142.35231222129144,136.40072044063825,130.62973470025668
|
||||
142.29091393695515,137.2246342874446,131.45390489082996
|
||||
141.48610487842447,137.60347035514724,132.05551788158235
|
||||
140.06694707154648,137.54992194123912,132.42502599416864
|
||||
138.22594097035088,137.12049434505636,132.57637619229655
|
||||
136.1966718318972,136.408728517904,132.54507314677466
|
||||
134.2269530937761,135.53426953213685,132.3838190375432
|
||||
132.55133261814115,134.62938697995605,132.15640993963805
|
||||
131.3667293962986,133.82483497604997,131.93077515485058
|
||||
130.81421235028907,133.23688401636713,131.77208966223768
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Alma
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
111.94970536775864
|
||||
111.06893157832275
|
||||
109.531823102842
|
||||
107.52034877441032
|
||||
105.25885111498506
|
||||
102.9940064860489
|
||||
100.97279022390286
|
||||
99.42041506842905
|
||||
98.52021357977716
|
||||
98.39726158677666
|
||||
99.10720553565477
|
||||
100.63129175872405
|
||||
102.87804168366374
|
||||
105.69142334193903
|
||||
108.86478923984795
|
||||
112.1593355636855
|
||||
115.32543381320428
|
||||
118.12492937208509
|
||||
120.35241515052857
|
||||
121.85357998883293
|
||||
122.5389928137129
|
||||
122.39209124972787
|
||||
121.47066108695326
|
||||
119.90167444845366
|
||||
117.86994774868424
|
||||
115.6016325936173
|
||||
113.344014331317
|
||||
111.3434227882747
|
||||
109.82322835964058
|
||||
108.96388899707799
|
||||
108.88683043739061
|
||||
109.64359960308988
|
||||
111.211260069327
|
||||
113.49444090641407
|
||||
116.33385588093464
|
||||
119.5205320205802
|
||||
122.81447654739276
|
||||
125.96611471786073
|
||||
128.7385835914609
|
||||
130.92889029169768
|
||||
132.3860447551969
|
||||
133.02454722438065
|
||||
132.83202568617187
|
||||
131.87034102707568
|
||||
130.27006118442495
|
||||
128.21879790140275
|
||||
125.94444792877846
|
||||
123.69483568689546
|
||||
121.71557584828516
|
||||
120.22813331047199
|
||||
119.41004039625565
|
||||
119.37903842005129
|
||||
120.18256020693593
|
||||
121.79349305965133
|
||||
124.11260065510152
|
||||
126.97738752954433
|
||||
130.17661431441516
|
||||
133.469167119997
|
||||
136.6055955210909
|
||||
139.35039522057332
|
||||
141.50304494686682
|
||||
142.91591842192776
|
||||
143.5074713769954
|
||||
143.26952565926126
|
||||
142.26799976190287
|
||||
140.63702052140982
|
||||
138.56694196674394
|
||||
136.28734156085395
|
||||
134.0465127296497
|
||||
132.08928554974582
|
||||
130.63515680688343
|
||||
129.858683001776
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Alpha
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
14.386988504259108
|
||||
13.212421186224432
|
||||
11.059484167373768
|
||||
9.378054556781706
|
||||
8.399884543745003
|
||||
8.016946768685571
|
||||
8.099402185312371
|
||||
8.291176266683564
|
||||
7.558724707776705
|
||||
5.202340033703678
|
||||
2.451829402762627
|
||||
0.25887933802150087
|
||||
-1.4479733958672654
|
||||
-2.8887317600775617
|
||||
-4.172750429834551
|
||||
-5.330900180496997
|
||||
-6.374715779067529
|
||||
-7.350691609157877
|
||||
-8.384458743551846
|
||||
-9.619541816548775
|
||||
-10.601166759253317
|
||||
-9.4077033263966
|
||||
-5.912515646884714
|
||||
-2.5587806683637524
|
||||
-0.022901584994329482
|
||||
2.034671716680407
|
||||
3.9978951583982507
|
||||
6.213520292133154
|
||||
8.777758936854312
|
||||
10.721639944676696
|
||||
10.630197517242905
|
||||
9.269248545074035
|
||||
7.953873394486493
|
||||
7.000172358166907
|
||||
6.302472469098049
|
||||
5.7117937708544275
|
||||
5.101595700035176
|
||||
4.358738041624505
|
||||
3.3598841600793037
|
||||
1.9313318181200145
|
||||
-0.1944772116095237
|
||||
-3.1605286690629697
|
||||
-5.97631973474688
|
||||
-7.327220506491372
|
||||
-8.02511402561214
|
||||
-8.964410433519063
|
||||
-10.380897183042563
|
||||
-12.484423093463292
|
||||
-15.707646976153043
|
||||
-20.02134341138259
|
||||
-21.89029822972246
|
||||
-17.495198620003336
|
||||
-11.654845563859709
|
||||
-7.424633000110333
|
||||
-4.440210083568232
|
||||
-2.090722760144132
|
||||
-0.029194921427318832
|
||||
1.9477690623565422
|
||||
4.013745476626099
|
||||
6.3927342458997884
|
||||
9.401867422537336
|
||||
13.276709429133177
|
||||
17.224306925384937
|
||||
18.624049314196938
|
||||
16.689263612105634
|
||||
13.943912605469578
|
||||
11.943688847666905
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AmihudIlliquidity
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.00000015985561350029384
|
||||
0.00000015696771188449567
|
||||
0.0000001555303792060817
|
||||
0.00000015538151277346344
|
||||
0.00000015631093229344765
|
||||
0.00000015809693251091022
|
||||
0.00000016052029367231717
|
||||
0.0000001589845131230261
|
||||
0.0000001559508516581196
|
||||
0.0000001529768427906417
|
||||
0.0000001503460729755366
|
||||
0.00000014837206402589596
|
||||
0.00000014715332162105188
|
||||
0.00000014682375710095578
|
||||
0.00000014767538776327616
|
||||
0.0000001499189726303614
|
||||
0.00000015031723686424412
|
||||
0.00000014574211468297434
|
||||
0.0000001409279960850948
|
||||
0.00000013651731571450798
|
||||
0.00000013297737589390889
|
||||
0.00000013055309718846065
|
||||
0.00000012929133299478467
|
||||
0.00000012910138377497164
|
||||
0.0000001298184766752888
|
||||
0.00000013125189141704328
|
||||
0.0000001332132144884893
|
||||
0.0000001355275978678928
|
||||
0.0000001339382914458526
|
||||
0.00000013125540514859396
|
||||
0.0000001283947371727404
|
||||
0.0000001254650121375988
|
||||
0.00000012291775713992313
|
||||
0.0000001212427271966849
|
||||
0.0000001207208654452996
|
||||
0.00000012149003808330404
|
||||
0.00000012348242710816948
|
||||
0.00000012357281072705215
|
||||
0.0000001201625871252808
|
||||
0.00000011678172900066989
|
||||
0.00000011388044089483085
|
||||
0.00000011176347314797874
|
||||
0.00000011056397954223913
|
||||
0.00000011020000128947351
|
||||
0.00000011025821093960333
|
||||
0.00000011070122212135205
|
||||
0.00000011154097038302432
|
||||
0.00000011282328820660005
|
||||
0.00000011461652067341232
|
||||
0.00000011296405147780249
|
||||
0.0000001106418496468457
|
||||
0.0000001083644320663171
|
||||
0.00000010636813977636837
|
||||
0.00000010489751222331263
|
||||
0.00000010417655889480471
|
||||
0.0000001043649585629421
|
||||
0.0000001055082619108371
|
||||
0.00000010750148029927503
|
||||
0.00000010738588531942057
|
||||
0.00000010453775579601958
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AnchoredRsi
|
||||
nan
|
||||
100
|
||||
100
|
||||
100
|
||||
100
|
||||
100
|
||||
100
|
||||
95.45605806313631
|
||||
86.52492002723935
|
||||
76.2638987205537
|
||||
66.81339372303415
|
||||
59.09916610759193
|
||||
53.29425407866635
|
||||
49.26964373016562
|
||||
46.84518809898699
|
||||
45.900691177151764
|
||||
46.50528672246023
|
||||
48.70488186940023
|
||||
52.032522011350665
|
||||
55.868698509204336
|
||||
59.67658744590001
|
||||
63.107208604442455
|
||||
65.9882922251125
|
||||
68.26641756325883
|
||||
69.95095010799662
|
||||
71.07592996619353
|
||||
71.67905841266892
|
||||
71.79263953008521
|
||||
70.92265776658282
|
||||
69.10610410124812
|
||||
66.68393947179895
|
||||
64.0284164122834
|
||||
61.46618054019408
|
||||
59.24380602867859
|
||||
57.5283318973131
|
||||
56.42553580651971
|
||||
56.001811453875014
|
||||
56.235171246003276
|
||||
57.0197593102381
|
||||
58.25880410351491
|
||||
59.798202212884654
|
||||
61.46661465071019
|
||||
63.10896422759926
|
||||
64.60450896314175
|
||||
65.87040024864744
|
||||
66.85647878026009
|
||||
67.53708615883738
|
||||
67.9036280460956
|
||||
67.95962807553119
|
||||
67.45633000604468
|
||||
66.43268012478919
|
||||
65.05131179571976
|
||||
63.501006648347214
|
||||
61.96478307287452
|
||||
60.59929220857238
|
||||
59.52658585180274
|
||||
58.83480409912063
|
||||
58.58312494864277
|
||||
58.74029304760523
|
||||
59.226372611328344
|
||||
59.99306654026555
|
||||
60.95989959911936
|
||||
62.0311011972887
|
||||
63.11189099784742
|
||||
64.11997874250162
|
||||
64.99114252964489
|
||||
65.6800659729537
|
||||
66.1585047045479
|
||||
66.4126719187185
|
||||
66.44111366160692
|
||||
66.0741861792892
|
||||
65.35121215660126
|
||||
64.37803148650991
|
||||
63.28003637922312
|
||||
62.183572731291854
|
||||
61.202193427563614
|
||||
60.429076438381514
|
||||
59.934583730106105
|
||||
59.76688110283679
|
||||
59.8917532366135
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AnchoredVwap
|
||||
99.66666666666667
|
||||
101.43186355934736
|
||||
103.1418467346444
|
||||
104.72524251435041
|
||||
106.11658814601071
|
||||
107.26197807148026
|
||||
108.12392454778578
|
||||
108.68473286603445
|
||||
108.94788218474959
|
||||
108.93719496319889
|
||||
108.6939142335673
|
||||
108.27212140087826
|
||||
107.73315655203712
|
||||
107.13980697732005
|
||||
106.55099511684338
|
||||
106.01754191953432
|
||||
105.574488719377
|
||||
105.24403046718167
|
||||
105.0532260289652
|
||||
105.01668973808685
|
||||
105.13625480053574
|
||||
105.40178194132667
|
||||
105.79291824018027
|
||||
106.281534783261
|
||||
106.83455123904943
|
||||
107.41687731587024
|
||||
107.99424420127528
|
||||
108.53574454861608
|
||||
109.01593726593835
|
||||
109.41640368389328
|
||||
109.72667224007039
|
||||
109.94446831076806
|
||||
110.07829451614217
|
||||
110.13781541771121
|
||||
110.13654676966519
|
||||
110.09446794810344
|
||||
110.03604107972293
|
||||
109.98753674805292
|
||||
109.97402298898915
|
||||
110.01646326126956
|
||||
110.12936768851321
|
||||
110.3193480654346
|
||||
110.58476263894983
|
||||
110.91644060152191
|
||||
111.29929375327781
|
||||
111.71449283739537
|
||||
112.14183166129912
|
||||
112.56192604713692
|
||||
112.97175975899731
|
||||
113.35701680111218
|
||||
113.70418291569361
|
||||
114.0038205912578
|
||||
114.25128187847953
|
||||
114.44692254399716
|
||||
114.59582753713786
|
||||
114.7071101701647
|
||||
114.79288203685903
|
||||
114.86700832886702
|
||||
114.94376872046713
|
||||
115.03654251078153
|
||||
115.15663068517345
|
||||
115.3123159645159
|
||||
115.50824177852617
|
||||
115.74673529012439
|
||||
116.03442015889951
|
||||
116.36702355054167
|
||||
116.73595465861783
|
||||
117.12895426065779
|
||||
117.53127179630778
|
||||
117.92724246665307
|
||||
118.30204758751894
|
||||
118.64339224639716
|
||||
118.94283972962145
|
||||
119.19660258528434
|
||||
119.4056914713997
|
||||
119.57544065225956
|
||||
119.71453548143946
|
||||
119.83373933276083
|
||||
119.94454255354819
|
||||
120.060012943307
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
median,upper,lower
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
138.13379981168666,153.5903388831148,122.67726074025849
|
||||
139.30589937241328,154.76243844384143,123.84936030098511
|
||||
140.4779989331399,155.93453800456805,125.02145986171173
|
||||
141.65009849386652,157.10663756529468,126.19355942243835
|
||||
142.82219805459314,158.2787371260213,127.36565898316498
|
||||
143.99429761531977,159.45083668674792,128.53775854389158
|
||||
145.16639717604642,160.62293624747457,129.70985810461826
|
||||
146.33849673677304,161.7950358082012,130.88195766534488
|
||||
147.51059629749966,162.9671353689278,132.0540572260715
|
||||
148.68269585822628,164.13923492965444,133.22615678679813
|
||||
149.8547954189529,165.31133449038106,134.39825634752475
|
||||
116.38708046816012,131.99293946067135,100.78122147564889
|
||||
116.16761465158264,131.77347364409388,100.56175565907141
|
||||
115.94814883500517,131.5540078275164,100.34228984249394
|
||||
115.72868301842769,131.33454201093892,100.12282402591646
|
||||
115.50921720185022,131.11507619436145,99.90335820933899
|
||||
115.28975138527275,130.89561037778398,99.68389239276152
|
||||
115.07028556869527,130.6761445612065,99.46442657618404
|
||||
114.8508197521178,130.45667874462902,99.24496075960657
|
||||
114.63135393554032,130.23721292805155,99.02549494302909
|
||||
149.90312728485273,164.58343115980426,135.22282340990122
|
||||
151.1865172964635,165.86682117141504,136.506213421512
|
||||
152.4699073080743,167.15021118302582,137.7896034331228
|
||||
153.7532973196851,168.4336011946366,139.07299344473358
|
||||
155.0366873312959,169.71699120624743,140.3563834563444
|
||||
156.3200773429067,171.0003812178582,141.6397734679552
|
||||
157.60346735451748,172.28377122946898,142.92316347956597
|
||||
158.88685736612828,173.56716124107982,144.20655349117678
|
||||
160.17024737773906,174.8505512526906,145.48994350278755
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Apo
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
3.7012739364605096
|
||||
2.8847777801619685
|
||||
1.8736290337854626
|
||||
0.765036373877777
|
||||
-0.33696510075722585
|
||||
-1.3302592716584911
|
||||
-2.1233990496681514
|
||||
-2.643515874936071
|
||||
-2.842644233118577
|
||||
-2.7018727014259554
|
||||
-2.2329355172898318
|
||||
-1.4770923173072958
|
||||
-0.5013890907210765
|
||||
0.6073706179847704
|
||||
1.7504092924981336
|
||||
2.8258211305865757
|
||||
3.7376915861189843
|
||||
4.404677560865807
|
||||
4.767282854940035
|
||||
4.793179765664334
|
||||
4.480102057977561
|
||||
3.856051324024037
|
||||
2.9767986263964445
|
||||
1.9209048414712981
|
||||
0.7827047048393894
|
||||
-0.3361185888392413
|
||||
-1.3356155121889373
|
||||
-2.126497700802304
|
||||
-2.6381132934775877
|
||||
-2.824757659991434
|
||||
-2.6697557651722406
|
||||
-2.1869514793122704
|
||||
-1.419470780852464
|
||||
-0.43586931695936926
|
||||
0.6759915614169643
|
||||
1.8167932622175442
|
||||
2.884631838707918
|
||||
3.7841208048447044
|
||||
4.434911755464242
|
||||
4.778871672124524
|
||||
4.785275789087777
|
||||
4.453552157572545
|
||||
3.8133327455611834
|
||||
2.921806509345913
|
||||
1.85861087963238
|
||||
0.718717990969509
|
||||
-0.39604889322816916
|
||||
-1.3861109473328668
|
||||
-2.1630288617662075
|
||||
-2.657402861884563
|
||||
-2.825071982224358
|
||||
-2.651058833324072
|
||||
-2.150907486793429
|
||||
-1.3692949692966465
|
||||
-0.3760403965244876
|
||||
0.7401317606929894
|
||||
1.8795171692881922
|
||||
2.9403379252089508
|
||||
3.82783407056084
|
||||
4.462728218496949
|
||||
4.788307166129613
|
||||
4.775487916077651
|
||||
4.425415574035384
|
||||
3.769361059913706
|
||||
2.8659277697137497
|
||||
1.7958167087099923
|
||||
0.6546177110066083
|
||||
-0.4557293156457263
|
||||
-1.4360403782011701
|
||||
-2.198747209018677
|
||||
-2.6757194784072453
|
||||
-2.82435067406567
|
||||
-2.6313640139317727
|
||||
-2.113998421581357
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
up,down
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
42.857142857142854,100
|
||||
35.714285714285715,100
|
||||
28.571428571428573,92.85714285714286
|
||||
21.428571428571427,85.71428571428571
|
||||
14.285714285714286,78.57142857142857
|
||||
7.142857142857143,71.42857142857143
|
||||
0,64.28571428571429
|
||||
0,57.142857142857146
|
||||
100,50
|
||||
100,42.857142857142854
|
||||
100,35.714285714285715
|
||||
100,28.571428571428573
|
||||
100,21.428571428571427
|
||||
92.85714285714286,14.285714285714286
|
||||
85.71428571428571,7.142857142857143
|
||||
78.57142857142857,0
|
||||
71.42857142857143,0
|
||||
64.28571428571429,0
|
||||
57.142857142857146,0
|
||||
50,0
|
||||
42.857142857142854,0
|
||||
35.714285714285715,100
|
||||
28.571428571428573,100
|
||||
21.428571428571427,100
|
||||
14.285714285714286,92.85714285714286
|
||||
7.142857142857143,85.71428571428571
|
||||
0,78.57142857142857
|
||||
0,71.42857142857143
|
||||
0,64.28571428571429
|
||||
100,57.142857142857146
|
||||
100,50
|
||||
100,42.857142857142854
|
||||
100,35.714285714285715
|
||||
100,28.571428571428573
|
||||
100,21.428571428571427
|
||||
92.85714285714286,14.285714285714286
|
||||
85.71428571428571,7.142857142857143
|
||||
78.57142857142857,0
|
||||
71.42857142857143,0
|
||||
64.28571428571429,0
|
||||
57.142857142857146,0
|
||||
50,0
|
||||
42.857142857142854,100
|
||||
35.714285714285715,100
|
||||
28.571428571428573,92.85714285714286
|
||||
21.428571428571427,85.71428571428571
|
||||
14.285714285714286,78.57142857142857
|
||||
7.142857142857143,71.42857142857143
|
||||
0,64.28571428571429
|
||||
0,57.142857142857146
|
||||
100,50
|
||||
100,42.857142857142854
|
||||
100,35.714285714285715
|
||||
100,28.571428571428573
|
||||
100,21.428571428571427
|
||||
100,14.285714285714286
|
||||
92.85714285714286,7.142857142857143
|
||||
85.71428571428571,0
|
||||
78.57142857142857,0
|
||||
71.42857142857143,0
|
||||
64.28571428571429,0
|
||||
57.142857142857146,0
|
||||
50,0
|
||||
42.857142857142854,100
|
||||
35.714285714285715,100
|
||||
28.571428571428573,92.85714285714286
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AroonOscillator
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-57.142857142857146
|
||||
-64.28571428571428
|
||||
-64.28571428571429
|
||||
-64.28571428571428
|
||||
-64.28571428571428
|
||||
-64.28571428571429
|
||||
-64.28571428571429
|
||||
-57.142857142857146
|
||||
50
|
||||
57.142857142857146
|
||||
64.28571428571428
|
||||
71.42857142857143
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
71.42857142857143
|
||||
64.28571428571429
|
||||
57.142857142857146
|
||||
50
|
||||
42.857142857142854
|
||||
-64.28571428571428
|
||||
-71.42857142857143
|
||||
-78.57142857142857
|
||||
-78.57142857142857
|
||||
-78.57142857142857
|
||||
-78.57142857142857
|
||||
-71.42857142857143
|
||||
-64.28571428571429
|
||||
42.857142857142854
|
||||
50
|
||||
57.142857142857146
|
||||
64.28571428571428
|
||||
71.42857142857143
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
78.57142857142857
|
||||
71.42857142857143
|
||||
64.28571428571429
|
||||
57.142857142857146
|
||||
50
|
||||
-57.142857142857146
|
||||
-64.28571428571428
|
||||
-64.28571428571429
|
||||
-64.28571428571428
|
||||
-64.28571428571428
|
||||
-64.28571428571429
|
||||
-64.28571428571429
|
||||
-57.142857142857146
|
||||
50
|
||||
57.142857142857146
|
||||
64.28571428571428
|
||||
71.42857142857143
|
||||
78.57142857142857
|
||||
85.71428571428571
|
||||
85.71428571428572
|
||||
85.71428571428571
|
||||
78.57142857142857
|
||||
71.42857142857143
|
||||
64.28571428571429
|
||||
57.142857142857146
|
||||
50
|
||||
-57.142857142857146
|
||||
-64.28571428571428
|
||||
-64.28571428571429
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Atr
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
3.917642936098542
|
||||
3.871756865753318
|
||||
3.8256550237571303
|
||||
3.775585219414474
|
||||
3.7359112048078584
|
||||
3.751806385408204
|
||||
3.844730678370346
|
||||
3.9663267478375337
|
||||
4.065925146592011
|
||||
4.103990051025662
|
||||
4.122277884333844
|
||||
4.120405500552875
|
||||
4.1099068422738645
|
||||
4.067219182386907
|
||||
3.965656623010464
|
||||
3.883731209815142
|
||||
3.8454426000158177
|
||||
3.827649810828608
|
||||
3.8056867488416217
|
||||
3.7971798302715882
|
||||
3.795930185925992
|
||||
3.768312827006575
|
||||
3.700099728786484
|
||||
3.6306300896424184
|
||||
3.63084862338228
|
||||
3.6560272497167245
|
||||
3.6536783654804816
|
||||
3.670527021756155
|
||||
3.731163563648225
|
||||
3.855191519830406
|
||||
3.994403105040647
|
||||
4.097289247845801
|
||||
4.128368657741341
|
||||
4.103844480606131
|
||||
4.0291518193306395
|
||||
3.972922779511551
|
||||
3.9077919971718877
|
||||
3.8900842871217334
|
||||
3.9281940607734454
|
||||
3.970355102352287
|
||||
3.970344885666312
|
||||
3.9271768651715058
|
||||
3.891868629198634
|
||||
3.896746818914544
|
||||
3.888594808948336
|
||||
3.8241554941261624
|
||||
3.755340593345057
|
||||
3.742402894117046
|
||||
3.779811441067645
|
||||
3.833276428397188
|
||||
3.8832337640008086
|
||||
3.9482678364884123
|
||||
3.9963590513965954
|
||||
3.9961613679725096
|
||||
3.957618048219805
|
||||
3.9111378825809897
|
||||
3.9118754285284236
|
||||
3.9079875306228926
|
||||
3.8519602816708205
|
||||
3.8003043443211753
|
||||
3.824279210324508
|
||||
3.89030736805505
|
||||
3.946176568396809
|
||||
3.944383618517461
|
||||
3.889018639116889
|
||||
3.8395240928112067
|
||||
3.792174559624793
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
upper,middle,lower
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
nan,nan,nan
|
||||
107.45762428035735,99.62233840816026,91.78705253596317
|
||||
106.02775600737075,98.28424227586412,90.54072854435748
|
||||
105.37600887086329,97.72469882334903,90.07338877583477
|
||||
105.58952435047054,98.0383539116416,90.48718347281265
|
||||
106.71367558633838,99.24185317672267,91.77003076710696
|
||||
108.77596789525653,101.27235512444012,93.76874235362372
|
||||
111.68260593076432,103.99314457402363,96.30368321728294
|
||||
115.1384985136858,107.20584501801073,99.27319152233567
|
||||
118.79998929802753,110.6681390048435,102.53628871165947
|
||||
122.3233937371851,114.11541363513378,105.90743353308245
|
||||
125.52895341254967,117.28439764388199,109.03984187521431
|
||||
128.17748963959727,119.93667863849153,111.69586763738577
|
||||
130.0998134522951,121.87999976774739,113.66018608319966
|
||||
131.11987181851987,122.98543345374605,114.85099508897224
|
||||
131.13021135447178,123.19889810845086,115.26758486242993
|
||||
130.31345150051308,122.5459890808828,114.77852666125253
|
||||
128.82057750085346,121.12969230082183,113.4388071007902
|
||||
126.77648447407479,119.12118485241757,111.46588523076035
|
||||
124.35591773275388,116.74454423507063,109.13317073738739
|
||||
121.85109184831337,114.2567321877702,106.66237252722702
|
||||
119.51650143409877,111.92464106224679,104.33278069039481
|
||||
117.53787877807773,110.00125312406458,102.46462747005143
|
||||
116.10324185785626,108.7030424002833,101.30284294271033
|
||||
115.45189787861992,108.19063769933508,100.92937752005025
|
||||
115.81617136472467,108.55447411796011,101.29277687119556
|
||||
117.11876924278668,109.80671474335324,102.4946602439198
|
||||
119.18752089177063,111.88016416080967,104.57280742984871
|
||||
121.97532486350796,114.63427081999565,107.29321677648333
|
||||
125.33000921363842,117.86768208634197,110.40535495904552
|
||||
129.04661351187218,121.33623047221137,113.62584743255056
|
||||
132.76355060145823,124.77474439137693,116.78593818129563
|
||||
136.11531364276385,127.92073514707224,119.72615665138063
|
||||
138.7945815809989,130.5378442655162,122.28110695003353
|
||||
140.6446456556533,132.43695669444105,124.2292677332288
|
||||
141.55139752614045,133.49309388747918,125.4347902488179
|
||||
141.60242332451588,133.65657776549278,125.71073220646969
|
||||
140.77305230577312,132.95746831142935,125.14188431708558
|
||||
139.28304697581464,131.50287840157117,123.7227098273277
|
||||
137.32379385285304,129.46740573130614,121.61101760975926
|
||||
135.01824672769902,127.07753652299444,119.13682631828986
|
||||
132.53210395759075,124.59141418625812,116.65072441492549
|
||||
130.13013386635836,122.27578013601534,114.42142640567234
|
||||
128.16588383470605,120.38214657630877,112.5984093179115
|
||||
126.91782330201404,119.12432966418496,111.33083602635587
|
||||
126.43653956708025,118.65934994918358,110.88216033128691
|
||||
126.72171718354599,119.07340619529367,111.42509520704135
|
||||
127.88485668877826,120.37417550208815,112.86349431539804
|
||||
129.97493332051732,122.49012753228324,115.00532174404914
|
||||
132.83653698586798,125.27691410373268,117.71729122159739
|
||||
136.19681623942813,128.53026338263376,120.86371052583938
|
||||
139.7706944060697,132.0042268780681,124.23775935006648
|
||||
143.32968496117576,135.43314928819893,127.53661361522211
|
||||
146.5481167999892,138.555398697196,130.56268059440282
|
||||
149.12906011101606,141.13673737507105,133.14441463912604
|
||||
150.90648163291854,142.99124553647894,135.07600944003934
|
||||
151.8202047665887,143.9979290014267,136.17565323626474
|
||||
151.935278102078,144.11152724502116,136.28777638796433
|
||||
151.18253144660633,143.36655638536055,135.55058132411477
|
||||
149.57814652484404,141.8742259615024,134.17030539816074
|
||||
147.41311360519177,139.81250491654941,132.21189622790706
|
||||
145.0587825826475,137.41022416199849,129.76166574134947
|
||||
142.7072505300425,134.9266357939324,127.14602105782231
|
||||
140.52060801218852,132.6282548753949,124.73590173860129
|
||||
138.6538196765925,130.76505243955756,122.87628520252264
|
||||
137.32616360003695,129.54812632180318,121.7700890435694
|
||||
136.80989260441592,129.13084441879352,121.45179623317111
|
||||
137.179493910278,129.59514479102842,122.01079567177884
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
value,direction
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
nan,nan
|
||||
91.78705253596317,1
|
||||
93.72293096883983,1
|
||||
95.6357584807184,1
|
||||
97.52355109042563,1
|
||||
106.71367558633838,-1
|
||||
104.83777239363428,-1
|
||||
96.30368321728294,1
|
||||
98.28684659120171,1
|
||||
100.31980916449771,1
|
||||
102.37180419001055,1
|
||||
104.43294313217747,1
|
||||
106.4931458824539,1
|
||||
108.54809930359083,1
|
||||
110.58170889478428,1
|
||||
112.56453720628951,1
|
||||
114.50640281119709,1
|
||||
116.429124111205,1
|
||||
118.3429490166193,1
|
||||
124.35591773275388,-1
|
||||
122.45732781761808,-1
|
||||
120.55936272465509,-1
|
||||
118.6752063111518,-1
|
||||
116.82515644675856,-1
|
||||
115.00984140193735,-1
|
||||
113.1944170902462,-1
|
||||
111.36640346538785,-1
|
||||
104.57280742984871,1
|
||||
106.40807094072679,1
|
||||
108.2736527225509,1
|
||||
110.20124848246611,1
|
||||
112.19845003498644,1
|
||||
114.24709465890933,1
|
||||
116.31127898778,1
|
||||
118.36320122808307,1
|
||||
120.3777771377484,1
|
||||
122.36423852750417,1
|
||||
124.31813452609012,1
|
||||
126.26317666965099,1
|
||||
128.2272737000377,1
|
||||
135.01824672769902,-1
|
||||
133.03307428486588,-1
|
||||
131.0694858522801,-1
|
||||
129.12355153768078,-1
|
||||
127.17517812822351,-1
|
||||
125.23088072374934,-1
|
||||
123.31880297668626,-1
|
||||
121.44113268001372,-1
|
||||
115.00532174404914,1
|
||||
116.89522746458296,1
|
||||
118.81186567878156,1
|
||||
120.75348256078196,1
|
||||
122.72761647902617,1
|
||||
124.72579600472446,1
|
||||
126.72387668871072,1
|
||||
128.70268571282062,1
|
||||
130.65825465411112,1
|
||||
132.61419236837534,1
|
||||
134.5681861336868,1
|
||||
136.4941662745222,1
|
||||
138.39431844668277,1
|
||||
145.0587825826475,-1
|
||||
143.11362889861996,-1
|
||||
141.14054061442155,-1
|
||||
139.16834880516282,-1
|
||||
137.22383948560437,-1
|
||||
135.30407743919878,-1
|
||||
133.40799015938637,-1
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AtrTrailingStop
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
91.78705253596317
|
||||
91.78705253596317
|
||||
91.78705253596317
|
||||
91.78705253596317
|
||||
91.78705253596317
|
||||
93.76874235362372
|
||||
96.30368321728294
|
||||
99.27319152233567
|
||||
102.53628871165947
|
||||
105.90743353308245
|
||||
109.03984187521431
|
||||
111.69586763738577
|
||||
113.66018608319966
|
||||
114.85099508897224
|
||||
115.26758486242993
|
||||
115.26758486242993
|
||||
115.26758486242993
|
||||
115.26758486242993
|
||||
115.26758486242993
|
||||
121.85109184831337
|
||||
119.51650143409877
|
||||
117.53787877807773
|
||||
116.10324185785626
|
||||
115.45189787861992
|
||||
115.45189787861992
|
||||
115.45189787861992
|
||||
115.45189787861992
|
||||
115.45189787861992
|
||||
110.40535495904552
|
||||
113.62584743255056
|
||||
116.78593818129563
|
||||
119.72615665138063
|
||||
122.28110695003353
|
||||
124.2292677332288
|
||||
125.4347902488179
|
||||
125.71073220646969
|
||||
125.71073220646969
|
||||
125.71073220646969
|
||||
125.71073220646969
|
||||
125.71073220646969
|
||||
132.53210395759075
|
||||
130.13013386635836
|
||||
128.16588383470605
|
||||
126.91782330201404
|
||||
126.43653956708025
|
||||
126.43653956708025
|
||||
126.43653956708025
|
||||
126.43653956708025
|
||||
126.43653956708025
|
||||
120.86371052583938
|
||||
124.23775935006648
|
||||
127.53661361522211
|
||||
130.56268059440282
|
||||
133.14441463912604
|
||||
135.07600944003934
|
||||
136.17565323626474
|
||||
136.28777638796433
|
||||
136.28777638796433
|
||||
136.28777638796433
|
||||
136.28777638796433
|
||||
136.28777638796433
|
||||
142.7072505300425
|
||||
140.52060801218852
|
||||
138.6538196765925
|
||||
137.32616360003695
|
||||
136.80989260441592
|
||||
136.80989260441592
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
level_0,level_236,level_382,level_500,level_618,level_786,level_1000
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
nan,nan,nan,nan,nan,nan,nan
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
95.93821562552817,100.47556131711858,103.28256331276349,105.55123615855868,107.81990900435389,111.04988390345214,115.1642566915892
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
124.2878498649492,117.59733618444584,113.45828958549036,110.11303274523868,106.767775904987,102.00503735276428,95.93821562552817
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
135.065460892756,128.2692287081258,124.06477998373596,120.66666389142087,117.26854779910578,112.43055200665717,106.26786689008574
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
146.57143212166807,139.65283986732902,135.3726938116786,131.91339768450908,128.45410155733956,123.52900198645413,117.25536324735009
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
Autocorrelation
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.6350373907840188
|
||||
0.5405958230224509
|
||||
0.5715509867319618
|
||||
0.6847209376927287
|
||||
0.7382107181033117
|
||||
0.7579207987906323
|
||||
0.762822432921618
|
||||
0.7572980491605352
|
||||
0.7363889001173629
|
||||
0.6799889443191299
|
||||
0.5648879977703694
|
||||
0.54489228047915
|
||||
0.6396550255535112
|
||||
0.6974753084777462
|
||||
0.7246269314937726
|
||||
0.737356237098341
|
||||
0.7424339180343317
|
||||
0.7421497527004213
|
||||
0.7363829456099225
|
||||
0.7224953185679739
|
||||
0.692943015254534
|
||||
0.6302595069491079
|
||||
0.5367533355339029
|
||||
0.578450958314291
|
||||
0.6892271578296308
|
||||
0.7399336462425192
|
||||
0.758500447439642
|
||||
0.7627917441846417
|
||||
0.7566305617172937
|
||||
0.7344628307695249
|
||||
0.6750260473147637
|
||||
0.5585359164341555
|
||||
0.5495761556376604
|
||||
0.6441109481859122
|
||||
0.6995996374123962
|
||||
0.7256276173803344
|
||||
0.737808053951148
|
||||
0.7425514974267139
|
||||
0.7419828113973262
|
||||
0.735860098072037
|
||||
0.7213607302420498
|
||||
0.690526496586784
|
||||
0.625324582684563
|
||||
0.5334303166974939
|
||||
0.585517119455116
|
||||
0.6935137858338126
|
||||
0.7415627500956398
|
||||
0.7590385074166992
|
||||
0.7627302918469656
|
||||
0.7559165686210035
|
||||
0.7324268451189209
|
||||
0.6698284783594914
|
||||
0.5525700479734488
|
||||
0.5545816350091717
|
||||
0.6484051513599884
|
||||
0.701634870935319
|
||||
0.7265871731416474
|
||||
0.7382375020131329
|
||||
0.7426529432973633
|
||||
0.741799024970625
|
||||
0.7353121322341262
|
||||
0.720177679673926
|
||||
0.6880037896027371
|
||||
0.6202378952393583
|
||||
0.5306891887744772
|
||||
0.5926832075977227
|
||||
0.6975877865016052
|
||||
0.7431028082864907
|
||||
0.7595363725248612
|
||||
0.7626379258822382
|
||||
0.7551541640582837
|
||||
|
@@ -0,0 +1,81 @@
|
||||
AutocorrelationPeriodogram
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
21.370134797170195
|
||||
21.740355712706783
|
||||
21.746722633874473
|
||||
21.740310825815456
|
||||
21.738725576107456
|
||||
21.749343751613182
|
||||
21.766185715939745
|
||||
21.75280720655723
|
||||
21.730273225340735
|
||||
21.40113988450871
|
||||
21.4057206919317
|
||||
21.75019334383562
|
||||
21.79086264109681
|
||||
21.81280419301341
|
||||
21.82788909151058
|
||||
21.844734772756343
|
||||
21.855934020583508
|
||||
21.837309938261576
|
||||
21.805673317865626
|
||||
21.777167581422532
|
||||
21.443409700389537
|
||||
21.445501400132258
|
||||
21.79881307579408
|
||||
21.8119294822053
|
||||
21.817181956120407
|
||||
21.823218785838115
|
||||
21.835956629473383
|
||||
21.82597746701043
|
||||
21.796450877056287
|
||||
21.762894634740192
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AverageDailyRange
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AverageDrawdown
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.11634127345040222
|
||||
0.12821030145315085
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.1331735000951348
|
||||
0.12848591667244894
|
||||
0.11764684482941928
|
||||
0.10157868991104642
|
||||
0.08163145656350326
|
||||
0.059639073995000014
|
||||
0.03790405604273088
|
||||
0.019048334089855002
|
||||
0.005693114578271463
|
||||
0.005299633662253274
|
||||
0.016795651904350065
|
||||
0.033098617914940426
|
||||
0.052389704554812816
|
||||
0.07258316476831601
|
||||
0.0915126451559611
|
||||
0.10712469987165406
|
||||
0.11766221882444922
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.12182138508985806
|
||||
0.11714256410361094
|
||||
0.106819842069383
|
||||
0.09175989280684736
|
||||
0.07327028934655701
|
||||
0.053091790499189634
|
||||
0.0333617631244852
|
||||
0.016459952712424047
|
||||
0.0047138027568846995
|
||||
0.005230640090830808
|
||||
0.01611368029862617
|
||||
0.03134280485272303
|
||||
0.04922347521153511
|
||||
0.06782429814370941
|
||||
0.08514955133331055
|
||||
0.09931745531053977
|
||||
0.10872826720736029
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.11220718102346297
|
||||
0.10753903894104662
|
||||
0.09766728005121854
|
||||
0.08348090178429443
|
||||
0.06624448981419782
|
||||
0.047612143066346396
|
||||
0.02957601401364172
|
||||
0.014311064191176653
|
||||
0.003903314430496008
|
||||
0.005169405070518737
|
||||
0.015524790599955774
|
||||
0.029831217603866415
|
||||
0.046500812330085135
|
||||
0.06373460629192022
|
||||
0.07968323276528869
|
||||
0.09261212521030097
|
||||
0.10105646093429439
|
||||
0.10395200934035767
|
||||
0.10395200934035767
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
AvgPrice
|
||||
99.5
|
||||
103.0164107856682
|
||||
106.37627358101629
|
||||
109.29790049544098
|
||||
111.52846427794583
|
||||
112.875521673814
|
||||
113.23347255708218
|
||||
112.60032201013415
|
||||
111.08145361594332
|
||||
108.8791967020537
|
||||
106.26936898786705
|
||||
103.56820817142187
|
||||
101.0947104237263
|
||||
99.13404459529625
|
||||
97.90729114869247
|
||||
97.55138116443152
|
||||
98.1111039285459
|
||||
99.54285912806507
|
||||
101.72792025538247
|
||||
104.49173065212182
|
||||
107.62538078254896
|
||||
110.90590746884149
|
||||
114.11320078613974
|
||||
117.0427452645055
|
||||
119.51475165912528
|
||||
121.3811006281581
|
||||
122.53171006302097
|
||||
122.90143777679592
|
||||
122.47762047177889
|
||||
121.30715443421617
|
||||
119.50102880884698
|
||||
117.23377096648008
|
||||
114.73556192793188
|
||||
112.27583959099815
|
||||
110.13883479309037
|
||||
108.59332241867756
|
||||
107.86047934521304
|
||||
108.08471167108598
|
||||
109.31236243425991
|
||||
111.4822566759027
|
||||
114.43022978908895
|
||||
117.90746386998124
|
||||
121.6100951023235
|
||||
125.21564025514759
|
||||
128.42071556026957
|
||||
130.97449658556297
|
||||
132.70337320460774
|
||||
133.52404653447638
|
||||
133.4444882618243
|
||||
132.55426356447325
|
||||
131.00727699563942
|
||||
129.00074817527417
|
||||
126.75407686183011
|
||||
124.49034662606454
|
||||
122.42184954038225
|
||||
120.73959006069859
|
||||
119.60563259734175
|
||||
119.14667258704391
|
||||
119.44743496013818
|
||||
120.54333510757368
|
||||
122.41300180733944
|
||||
124.9723861156795
|
||||
128.0728922037315
|
||||
131.50599292428956
|
||||
135.0160376079457
|
||||
138.3215327770725
|
||||
141.14337574868256
|
||||
143.23676289844406
|
||||
144.42221413881902
|
||||
144.61070035874553
|
||||
143.81840248790633
|
||||
142.16811736828257
|
||||
139.8764867613631
|
||||
137.22863145779047
|
||||
134.54392876795973
|
||||
132.13813355498985
|
||||
130.28751561753393
|
||||
129.20009166687123
|
||||
128.99752295261356
|
||||
129.70917825826996
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
AwesomeOscillator
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
4.570384735666252
|
||||
3.0561960735193736
|
||||
1.3060244118088917
|
||||
-0.5029613190631039
|
||||
-2.1806316349272805
|
||||
-3.5478673393119635
|
||||
-4.45972306302761
|
||||
-4.8239605326770345
|
||||
-4.611928464809438
|
||||
-3.860170724834589
|
||||
-2.662851979440731
|
||||
-1.1567326730114758
|
||||
0.49834529769209723
|
||||
2.1399322681608766
|
||||
3.621058126238438
|
||||
4.823442008798722
|
||||
5.664624488465435
|
||||
6.099225791599579
|
||||
6.115713017257008
|
||||
5.7307491018189864
|
||||
4.983264118814745
|
||||
3.929865635050632
|
||||
2.642270392028422
|
||||
1.2063775184159056
|
||||
-0.2782755010444333
|
||||
-1.700370951480437
|
||||
-2.941539115447682
|
||||
-3.8848111682511757
|
||||
-4.426560895042215
|
||||
-4.4905029143506
|
||||
-4.041336078802331
|
||||
-3.095141337885565
|
||||
-1.7238315423742847
|
||||
-0.051814538997348336
|
||||
1.755588138704951
|
||||
3.5108177967705103
|
||||
5.027224984104208
|
||||
6.143053104704535
|
||||
6.742326922060116
|
||||
6.769203490096643
|
||||
6.233526397720709
|
||||
5.206948615972465
|
||||
3.8107042616057925
|
||||
2.197548410777671
|
||||
0.5312485539522243
|
||||
-1.0328599437079902
|
||||
-2.3633384078653137
|
||||
-3.3623590198364894
|
||||
-3.9692970894536757
|
||||
-4.159140565860511
|
||||
-3.9375741515588345
|
||||
-3.334927744300842
|
||||
-2.4008870804206026
|
||||
-1.201070754973344
|
||||
0.18446919732400602
|
||||
1.6617572146048616
|
||||
3.123994988128942
|
||||
4.454940551834056
|
||||
5.535772236746325
|
||||
6.25568607305982
|
||||
6.525284065794352
|
||||
6.290702816278866
|
||||
5.545716409745864
|
||||
4.338947257621982
|
||||
2.7739114688308177
|
||||
1.0008201986038898
|
||||
-0.7993872839936955
|
||||
-2.4367284429525
|
||||
-3.736291195848054
|
||||
-4.560873609806407
|
||||
-4.828409641147431
|
||||
-4.5213585575528725
|
||||
-3.6867152703922557
|
||||
-2.4270217468478847
|
||||
|
@@ -0,0 +1,81 @@
|
||||
AwesomeOscillatorHistogram
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-0.9493266094278141
|
||||
1.7672459352793481
|
||||
4.358600076656543
|
||||
6.602187110662683
|
||||
8.296344652184288
|
||||
9.27861644113095
|
||||
9.442987181842355
|
||||
8.753826167727667
|
||||
7.25419885683786
|
||||
5.0665482432504945
|
||||
2.3845764783962977
|
||||
-0.5436382784689613
|
||||
-3.4398844131397794
|
||||
-6.024743436412052
|
||||
-8.047619021280653
|
||||
-9.313944923149322
|
||||
-9.705960567267766
|
||||
-9.194367129485144
|
||||
-7.8395445596312925
|
||||
-5.782563640816335
|
||||
-3.227675980109794
|
||||
-0.4190478382801217
|
||||
2.384954592075786
|
||||
4.936675586288629
|
||||
7.020602423104549
|
||||
8.46957444157708
|
||||
9.175065513168391
|
||||
9.09175978422364
|
||||
8.237265156648007
|
||||
6.688051325128271
|
||||
4.572584632754555
|
||||
2.0622813941775746
|
||||
-0.639506865491029
|
||||
-3.310544480839141
|
||||
-5.724885228158627
|
||||
-7.6699583626310215
|
||||
-8.964799135663043
|
||||
-9.477980849005377
|
||||
-9.143214002480718
|
||||
-7.970274245069987
|
||||
-6.049057200396703
|
||||
-3.545191401367603
|
||||
-0.6867092734768505
|
||||
2.2573921410563855
|
||||
5.004523682794101
|
||||
7.28854601676781
|
||||
8.888622473659666
|
||||
9.653061836115356
|
||||
9.51501349919954
|
||||
8.498087823482493
|
||||
6.711485620389652
|
||||
4.335747942904732
|
||||
1.601499796426907
|
||||
-1.235657687979156
|
||||
-3.92076039317206
|
||||
-6.222630824411269
|
||||
-7.952404629276373
|
||||
-8.976299109386929
|
||||
-9.222487507138581
|
||||
-8.682707819907705
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
BalanceOfPower
|
||||
0.3333333333333333
|
||||
0.24918578562417015
|
||||
0.1532445561608729
|
||||
0.024109914758360565
|
||||
-0.15126369246092533
|
||||
-0.25417582811797773
|
||||
-0.2563705799388135
|
||||
-0.238958499833379
|
||||
-0.19898370712725183
|
||||
-0.09462869525070507
|
||||
0.09646244971146158
|
||||
0.191696193537678
|
||||
0.251698133657637
|
||||
0.29632302023341184
|
||||
0.24160580444005647
|
||||
0.1074394752043461
|
||||
-0.04656481238909804
|
||||
-0.18695156649433217
|
||||
-0.30940801019469627
|
||||
-0.2719504613058267
|
||||
-0.21909709777835693
|
||||
-0.14317865093203458
|
||||
0.0019179256746909683
|
||||
0.1686706139360438
|
||||
0.2261481511924474
|
||||
0.2511179797823408
|
||||
0.2583640495061432
|
||||
0.22489355230909897
|
||||
0.04851072393034144
|
||||
-0.10602062779905451
|
||||
-0.21123897147261406
|
||||
-0.29963302122758023
|
||||
-0.28542416318247493
|
||||
-0.19524129928924822
|
||||
-0.08474486500729668
|
||||
0.07807035681224662
|
||||
0.242093752144673
|
||||
0.2585594827839427
|
||||
0.24820936374708588
|
||||
0.21964769214967206
|
||||
0.15232695504569738
|
||||
-0.031921304253094404
|
||||
-0.15874904242960208
|
||||
-0.229067283671274
|
||||
-0.27950011753293874
|
||||
-0.2953068046022972
|
||||
-0.16450528334957878
|
||||
-0.020242744866534435
|
||||
0.13084089121639847
|
||||
0.2634385178724825
|
||||
0.28987746987489366
|
||||
0.2428622264031086
|
||||
0.17919013792356872
|
||||
0.07307732461055456
|
||||
-0.12208792348704414
|
||||
-0.20824812068932066
|
||||
-0.24307226671835522
|
||||
-0.2576641629334006
|
||||
-0.25048433157799066
|
||||
-0.1216259848690068
|
||||
0.050232123962901463
|
||||
0.17071256189429312
|
||||
0.2640188090274396
|
||||
0.32000647838387675
|
||||
0.2340825348195698
|
||||
0.13493603424139705
|
||||
-0.004722755729112378
|
||||
-0.1809893451226458
|
||||
-0.2566062991560634
|
||||
-0.25458511111195226
|
||||
-0.23427222899952724
|
||||
-0.18817443846542414
|
||||
-0.05656914016469241
|
||||
0.11699965213355376
|
||||
0.20331039833065437
|
||||
0.2601529201580851
|
||||
0.3021742327768193
|
||||
0.21963053062292107
|
||||
0.08342772449640856
|
||||
-0.07179523248890883
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
BandpassFilter
|
||||
0
|
||||
0
|
||||
0.574012005267825
|
||||
1.5051939265432086
|
||||
2.54458305256959
|
||||
3.448198884988975
|
||||
4.009823523581662
|
||||
4.086218622606344
|
||||
3.6126423309268434
|
||||
2.607740442938282
|
||||
1.168078854019702
|
||||
-0.5463516323519935
|
||||
-2.333481351676574
|
||||
-3.9746162574859554
|
||||
-5.2610044847335145
|
||||
-6.018577471206315
|
||||
-6.128272491000966
|
||||
-5.539922414953268
|
||||
-4.278443350086661
|
||||
-2.4418821924935603
|
||||
-0.19172160457823573
|
||||
2.263398771828806
|
||||
4.688766487722294
|
||||
6.847281187751889
|
||||
8.523334458966975
|
||||
9.544513179170929
|
||||
9.799013460090258
|
||||
9.247104067761713
|
||||
7.925575961060641
|
||||
5.944799417755753
|
||||
3.4787170957550906
|
||||
0.7487650319430692
|
||||
-1.9967257897032682
|
||||
-4.505686285402234
|
||||
-6.5458419377839485
|
||||
-7.926421068127718
|
||||
-8.516023442252639
|
||||
-8.255001910353016
|
||||
-7.161225160735305
|
||||
-5.328704114314367
|
||||
-2.9192213921929238
|
||||
-0.14774288552589354
|
||||
2.737044853919084
|
||||
5.475288254175229
|
||||
7.819552786063573
|
||||
9.557295088306667
|
||||
10.530181529467578
|
||||
10.648504146188172
|
||||
9.899392260794748
|
||||
8.348081342219519
|
||||
6.132128774337021
|
||||
3.4491025141962037
|
||||
0.5388560394682242
|
||||
-2.3380110321146
|
||||
-4.9235660024931995
|
||||
-6.98572284815168
|
||||
-8.339104774759921
|
||||
-8.861715715702925
|
||||
-8.505924735201422
|
||||
-7.302778765807896
|
||||
-5.359258231660181
|
||||
-2.848723133656547
|
||||
0.004592589919308665
|
||||
2.9456477338629767
|
||||
5.711422895881837
|
||||
8.054466679915556
|
||||
9.765050346980752
|
||||
10.689947540292025
|
||||
10.746158408897616
|
||||
9.928350350366278
|
||||
8.309350104598916
|
||||
6.033643709739312
|
||||
3.3044662669350995
|
||||
0.3656366484755811
|
||||
-2.520237984148214
|
||||
-5.095238650435061
|
||||
-7.129192802756659
|
||||
-8.440252827993273
|
||||
-8.9111551990596
|
||||
-8.499706985123517
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Bat
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
BeltHold
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
Beta
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.863916838203187
|
||||
0.8748124702967537
|
||||
0.8946057997263253
|
||||
0.9097376510155167
|
||||
0.9181565067334678
|
||||
0.9210003489201404
|
||||
0.9195962060547169
|
||||
0.9174932266003597
|
||||
0.9249257951689157
|
||||
0.9487138883457331
|
||||
0.9763919596319081
|
||||
0.9982565294377046
|
||||
1.0148263315283022
|
||||
1.0281782404141946
|
||||
1.0394064955543543
|
||||
1.0489488974748693
|
||||
1.0571321057638519
|
||||
1.0646183197218162
|
||||
1.0727296033664908
|
||||
1.0828615929930323
|
||||
1.0911561042681732
|
||||
1.0810543255482563
|
||||
1.051331614898589
|
||||
1.0227697126979647
|
||||
1.000995295766229
|
||||
0.9829715985782936
|
||||
0.9653406036335549
|
||||
0.9451174989027369
|
||||
0.9216191753734285
|
||||
0.9037866100777762
|
||||
0.9045216485189498
|
||||
0.9169748362729095
|
||||
0.929308980343615
|
||||
0.9386370921780702
|
||||
0.9457999485962022
|
||||
0.951969735684252
|
||||
0.9580843792885625
|
||||
0.9649552887069828
|
||||
0.9734937015559431
|
||||
0.985056253647133
|
||||
1.0018005474479652
|
||||
1.0249593111810618
|
||||
1.0468858332211455
|
||||
1.0574227426531946
|
||||
1.0631260338233803
|
||||
1.0711199209001776
|
||||
1.0832778096850664
|
||||
1.1012401382548238
|
||||
1.1284177503347732
|
||||
1.1643894947830498
|
||||
1.1798991232740288
|
||||
1.1435110876247687
|
||||
1.095047907967375
|
||||
1.059823640813714
|
||||
1.0350251002237765
|
||||
1.0158073630345508
|
||||
0.9994517629356037
|
||||
0.9843614479943972
|
||||
0.9691469518976262
|
||||
0.9520208340373357
|
||||
0.9305011010160512
|
||||
0.9027103937239579
|
||||
0.8742867284782383
|
||||
0.8641903901829808
|
||||
0.8780799337451082
|
||||
0.8976243091278221
|
||||
0.9115993363797762
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
BetaNeutralSpread
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-0.2585415378308795
|
||||
-0.4993116528757753
|
||||
-0.660554122723326
|
||||
-0.8417739990935189
|
||||
-0.9940127336318625
|
||||
-1.0136166410863723
|
||||
-0.8157621367727188
|
||||
-0.3808238960257313
|
||||
0.1596130472267845
|
||||
0.5518223092989984
|
||||
0.7417041911235884
|
||||
0.789122513596169
|
||||
0.6831847429618989
|
||||
0.4125921646233337
|
||||
0.015090992115048607
|
||||
-0.4262627257469802
|
||||
-0.8066162386151916
|
||||
-1.0262602291343086
|
||||
-1.0104824422158742
|
||||
-0.719242507129934
|
||||
-0.18556011997246458
|
||||
0.3562680792260551
|
||||
0.6659803367819421
|
||||
0.8162022867167025
|
||||
0.8573083669292458
|
||||
0.7729728569854899
|
||||
0.578717507402132
|
||||
0.35381569734282436
|
||||
0.23071822337757908
|
||||
0.2650729582560416
|
||||
0.29453297370702103
|
||||
0.26840219208467886
|
||||
0.32102803646179723
|
||||
0.5036817552249317
|
||||
0.7659099549699704
|
||||
1.015512035626415
|
||||
1.1601762104641011
|
||||
1.1361193390621622
|
||||
0.9273813212856226
|
||||
0.5750470861860606
|
||||
0.17624462791634699
|
||||
-0.14090234706588944
|
||||
-0.32253088596095836
|
||||
-0.41626106949441066
|
||||
-0.3752988114551812
|
||||
-0.1631002766338696
|
||||
0.15646143011794322
|
||||
0.4558538117537978
|
||||
0.5639725731245022
|
||||
0.28621373100585856
|
||||
-0.32161659706252976
|
||||
-0.6999940972494301
|
||||
-0.8122706308072907
|
||||
-0.9131042111880561
|
||||
-1.0062556863712473
|
||||
-1.0158739869142437
|
||||
-0.8906931691027467
|
||||
-0.6265605860162111
|
||||
-0.26784717689341164
|
||||
0.09757070069628071
|
||||
0.34693849029537205
|
||||
0.34661785105078025
|
||||
0.05441147972820204
|
||||
-0.3111523192098957
|
||||
-0.5273831067767674
|
||||
-0.6894593989888449
|
||||
-0.8720990395464128
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
BetterVolume
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
-0.020006687804093315
|
||||
0.016853857336572298
|
||||
-0.039443721655550545
|
||||
-0.02244504158427907
|
||||
-0.025223946621270255
|
||||
0.08243871347885245
|
||||
-0.1082071684180308
|
||||
-0.14337788080854064
|
||||
0.00879243827398124
|
||||
0.31169646376078275
|
||||
0.15356652604555243
|
||||
-0.09429715058979049
|
||||
-0.1650695688447683
|
||||
-0.041544613501317995
|
||||
0.19786477636369748
|
||||
0.12344598883300695
|
||||
-0.0554132978177585
|
||||
-0.13953855277459903
|
||||
-0.05463281738826853
|
||||
-0.06774565586944081
|
||||
-0.12254177308123027
|
||||
-0.0099180855454859
|
||||
0.13103136419730332
|
||||
0.17867605288326305
|
||||
-0.07104363874158026
|
||||
-0.16360008983517416
|
||||
-0.06084539357512253
|
||||
0.20894317692883313
|
||||
0.25818479748558976
|
||||
-0.03352744693200438
|
||||
-0.15591433946317967
|
||||
-0.09024685095461416
|
||||
0.0730477105083932
|
||||
-0.03359007850841267
|
||||
-0.006209593457099372
|
||||
-0.047048932532378185
|
||||
0.03392770071710849
|
||||
-0.042080046900217716
|
||||
-0.14900204143948015
|
||||
-0.07466800960162501
|
||||
0.17526521130147488
|
||||
0.29157674859368754
|
||||
-0.008991353415500614
|
||||
-0.15938925130449477
|
||||
-0.11440099146902272
|
||||
0.10374770261998767
|
||||
0.14908511137403035
|
||||
0.03996789138168244
|
||||
-0.11990695568209042
|
||||
-0.10133381248716367
|
||||
-0.00406065257849475
|
||||
-0.11650997912640504
|
||||
-0.07609861291022613
|
||||
0.1260437678106
|
||||
0.17069801225265457
|
||||
0.01881666800862214
|
||||
-0.14723455991083556
|
||||
-0.12618577181329726
|
||||
0.08176882388289486
|
||||
0.33022657457227655
|
||||
0.06718419079012339
|
||||
-0.13098662573354236
|
||||
-0.14191904426459834
|
||||
0.018126709904739413
|
||||
-0.0022183788156834305
|
||||
-0.03569350419843753
|
||||
-0.03535812024691565
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
BipowerVariation
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
nan
|
||||
0.007714317161982309
|
||||
0.0062145762915002505
|
||||
0.005055925760075394
|
||||
0.004413365533571286
|
||||
0.004509607622819985
|
||||
0.005315124158263795
|
||||
0.006562355683354122
|
||||
0.007976745659640407
|
||||
0.009157869299122543
|
||||
0.009855166494125319
|
||||
0.01000102549806265
|
||||
0.009716198072767076
|
||||
0.0092475022543884
|
||||
0.00885982271749398
|
||||
0.008753022199498785
|
||||
0.008821311674973997
|
||||
0.009065210455553202
|
||||
0.009206353710855401
|
||||
0.0090447957832399
|
||||
0.008475495253598897
|
||||
0.007517898517010254
|
||||
0.006309639581562646
|
||||
0.0050779484609337604
|
||||
0.00414070344112324
|
||||
0.0036366010217849408
|
||||
0.0037456683217484757
|
||||
0.004435655246026971
|
||||
0.005483728195503344
|
||||
0.0066539207541450795
|
||||
0.007621693995782195
|
||||
0.008185407520850327
|
||||
0.008295670297527777
|
||||
0.008057397001252235
|
||||
0.007676101993368076
|
||||
0.007368119518318543
|
||||
0.007290088930196527
|
||||
0.007355792145932586
|
||||
0.007564861164309522
|
||||
0.007684383082253087
|
||||
0.007548043380736373
|
||||
0.007067741053187536
|
||||
0.006260469459591064
|
||||
0.005244893253273746
|
||||
0.004216393896626487
|
||||
0.003445642329481183
|
||||
0.003045608105953257
|
||||
0.0031627884884795174
|
||||
0.003763277919738434
|
||||
0.0046591553527013775
|
||||
0.005642564165698592
|
||||
0.006447307785190299
|
||||
0.006908866913841917
|
||||
0.006991486504657669
|
||||
0.0067877514311543985
|
||||
0.006471659359592264
|
||||
0.006222839305862642
|
||||
0.0061647329564093216
|
||||
0.006228520362098688
|
||||
0.006409678459244259
|
||||
0.006510814215342929
|
||||
0.00639161325444207
|
||||
0.0059779024956309644
|
||||
0.005285696100470746
|
||||
0.004419182286526892
|
||||
0.0035484581956077735
|
||||
0.002905784962653635
|
||||
|
Vendored
+81
@@ -0,0 +1,81 @@
|
||||
BodySizePct
|
||||
0.3333333333333333
|
||||
0.24918578562417015
|
||||
0.1532445561608729
|
||||
0.024109914758360565
|
||||
0.15126369246092533
|
||||
0.25417582811797773
|
||||
0.2563705799388135
|
||||
0.238958499833379
|
||||
0.19898370712725183
|
||||
0.09462869525070507
|
||||
0.09646244971146158
|
||||
0.191696193537678
|
||||
0.251698133657637
|
||||
0.29632302023341184
|
||||
0.24160580444005647
|
||||
0.1074394752043461
|
||||
0.04656481238909804
|
||||
0.18695156649433217
|
||||
0.30940801019469627
|
||||
0.2719504613058267
|
||||
0.21909709777835693
|
||||
0.14317865093203458
|
||||
0.0019179256746909683
|
||||
0.1686706139360438
|
||||
0.2261481511924474
|
||||
0.2511179797823408
|
||||
0.2583640495061432
|
||||
0.22489355230909897
|
||||
0.04851072393034144
|
||||
0.10602062779905451
|
||||
0.21123897147261406
|
||||
0.29963302122758023
|
||||
0.28542416318247493
|
||||
0.19524129928924822
|
||||
0.08474486500729668
|
||||
0.07807035681224662
|
||||
0.242093752144673
|
||||
0.2585594827839427
|
||||
0.24820936374708588
|
||||
0.21964769214967206
|
||||
0.15232695504569738
|
||||
0.031921304253094404
|
||||
0.15874904242960208
|
||||
0.229067283671274
|
||||
0.27950011753293874
|
||||
0.2953068046022972
|
||||
0.16450528334957878
|
||||
0.020242744866534435
|
||||
0.13084089121639847
|
||||
0.2634385178724825
|
||||
0.28987746987489366
|
||||
0.2428622264031086
|
||||
0.17919013792356872
|
||||
0.07307732461055456
|
||||
0.12208792348704414
|
||||
0.20824812068932066
|
||||
0.24307226671835522
|
||||
0.2576641629334006
|
||||
0.25048433157799066
|
||||
0.1216259848690068
|
||||
0.050232123962901463
|
||||
0.17071256189429312
|
||||
0.2640188090274396
|
||||
0.32000647838387675
|
||||
0.2340825348195698
|
||||
0.13493603424139705
|
||||
0.004722755729112378
|
||||
0.1809893451226458
|
||||
0.2566062991560634
|
||||
0.25458511111195226
|
||||
0.23427222899952724
|
||||
0.18817443846542414
|
||||
0.05656914016469241
|
||||
0.11699965213355376
|
||||
0.20331039833065437
|
||||
0.2601529201580851
|
||||
0.3021742327768193
|
||||
0.21963053062292107
|
||||
0.08342772449640856
|
||||
0.07179523248890883
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user