Files
kingchenc cb6da4d737 feat(data-layer): Resampler (candle resampling) in all 10 languages (#310)
* feat(data-layer): Resampler (candle resampling) in all 10 languages

Second data-layer feature (F3): resample candles into a higher timeframe.

- Native (Node.js/WASM): new Resampler(timeframe) -> update(o,h,l,c,v,ts):
  Candle|null + flush(): Candle|null. Python the same -> tuple|None.
- C ABI: wickra_resampler_new/update/flush/free (update has the multi-output
  shape so the generators auto-emit it; flush is bespoke). Go Update -> (Candle,
  bool) + Flush; C# Candle? Update/Flush; Java Candle update/flush; R update()
  generic + a flush() S3 method (extends base::flush); C/C++ direct.
- Cross-language golden (testdata/golden/data_resampled.csv): the shared input
  candles resampled into 5-unit buckets, the final partial bucket via flush,
  pinned bit-for-bit across every binding.

Verified locally in all 10 (3 candles for the 5-unit smoke; 16 for the golden).
The WickraCandle output record is shared with the tick aggregator (deduped).

* test(node): exclude data-layer types from the indicator completeness contract

The Resampler exposes update(), so the completeness test flagged it as an
indicator and required batch/reset/isReady/warmupPeriod, which a data-layer type
does not have. Exclude TickAggregator and Resampler like the bar builders.
2026-06-15 22:36:16 +02:00

1.5 KiB

1openhighlowclosevolumetimestamp
299112.9040317712973598111.320390859672265187.0086237398260
3113.27609348158748115.1642566915892107.76539185209613108.77379880233835473.2381034683295
4106.12753789513545107.7396933799580796.3471004568948598.284242275864125324.37465331737910
597.378063505514106.3251016113183295.93821562552817103.993144574023635150.94135877518515
6108.04491654708718121.38046215528227105.7105413401633119.936678638491535456.983595408034520
7120.88220148856881124.2878498649492119.39438848583472121.129692300821835371.10122352253625
8119.8808727652764121.29920058454442108.51535390119264110.001253124064585128.4708820518930
9108.48360243707184113.29382811110736106.26786689008574111.880164160809675431.58255757856635
10114.22618875818226130.20955349568973113.09073586402833127.920735147072245410.40020021573140
11131.41114890560974135.065460892756129.49585703767033132.957468311429355120.05897352702745
12130.5116755897077132.71696973631924121.2254215875191122.275780136015345397.54339192478750
13121.09703354508844122.45602084147426117.25536324735009120.374175502088155441.48501411125255
14122.33587608239566136.79793765689536120.87761530843784135.433149288198935132.553924800824560
15138.08766685694894146.57143212166807136.58837142074304144.111527245021165355.54739257869265
16144.27024859045207145.7471249168318132.66155074344638134.92663579393245463.73350244763370
17131.6480122345848134.02210748888697127.39947545719488129.595144791028425163.94653882837375