@sipemu/anofox-forecast 0.4.4 → 0.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +179 -4
- package/anofox_forecast_js.d.ts +1769 -55
- package/anofox_forecast_js.js +4276 -392
- package/anofox_forecast_js_bg.wasm +0 -0
- package/anofox_forecast_js_bg.wasm.d.ts +256 -1
- package/package.json +1 -1
package/anofox_forecast_js.d.ts
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
export class ADIDAForecaster {
|
|
5
5
|
free(): void;
|
|
6
6
|
[Symbol.dispose](): void;
|
|
7
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
7
8
|
fit(series: TimeSeries): void;
|
|
8
9
|
constructor();
|
|
9
10
|
predict(horizon: number): Forecast;
|
|
@@ -61,6 +62,179 @@ export class AutoETSForecaster {
|
|
|
61
62
|
readonly name: string;
|
|
62
63
|
}
|
|
63
64
|
|
|
65
|
+
export class AutoEnsembleForecaster {
|
|
66
|
+
free(): void;
|
|
67
|
+
[Symbol.dispose](): void;
|
|
68
|
+
/**
|
|
69
|
+
* Get all candidate scores as a JSON object.
|
|
70
|
+
*
|
|
71
|
+
* Returns an array of `{ name, score }` objects sorted by score (ascending).
|
|
72
|
+
*/
|
|
73
|
+
allScores(): any;
|
|
74
|
+
/**
|
|
75
|
+
* Get the number of models in the ensemble.
|
|
76
|
+
*/
|
|
77
|
+
modelCount(): number;
|
|
78
|
+
/**
|
|
79
|
+
* Create with custom configuration.
|
|
80
|
+
*
|
|
81
|
+
* @param topK - Number of top models to include in ensemble (default: 3)
|
|
82
|
+
* @param seasonalPeriod - Seasonal period (0 or undefined for non-seasonal)
|
|
83
|
+
*/
|
|
84
|
+
static withConfig(top_k?: number | null, seasonal_period?: number | null): AutoEnsembleForecaster;
|
|
85
|
+
/**
|
|
86
|
+
* Predict with prediction intervals.
|
|
87
|
+
*
|
|
88
|
+
* @param horizon - Number of steps to forecast
|
|
89
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
90
|
+
* @returns Forecast with combined predictions and intervals
|
|
91
|
+
*/
|
|
92
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
93
|
+
/**
|
|
94
|
+
* Fit the ensemble to a time series.
|
|
95
|
+
*
|
|
96
|
+
* Fits all candidate models, selects the top-K, and builds the ensemble.
|
|
97
|
+
*
|
|
98
|
+
* @param series - TimeSeries to fit
|
|
99
|
+
*/
|
|
100
|
+
fit(series: TimeSeries): void;
|
|
101
|
+
/**
|
|
102
|
+
* Create a new AutoEnsembleForecaster with default configuration.
|
|
103
|
+
*
|
|
104
|
+
* By default, uses top-3 models with weighted MSE combination.
|
|
105
|
+
*/
|
|
106
|
+
constructor();
|
|
107
|
+
/**
|
|
108
|
+
* Predict future values.
|
|
109
|
+
*
|
|
110
|
+
* @param horizon - Number of steps to forecast
|
|
111
|
+
* @returns Forecast with combined point predictions
|
|
112
|
+
*/
|
|
113
|
+
predict(horizon: number): Forecast;
|
|
114
|
+
/**
|
|
115
|
+
* Create a seasonal AutoEnsembleForecaster.
|
|
116
|
+
*
|
|
117
|
+
* @param period - Seasonal period
|
|
118
|
+
*/
|
|
119
|
+
static seasonal(period: number): AutoEnsembleForecaster;
|
|
120
|
+
/**
|
|
121
|
+
* Get the model name.
|
|
122
|
+
*/
|
|
123
|
+
readonly name: string;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
export class AutoForecastBuilder {
|
|
127
|
+
free(): void;
|
|
128
|
+
[Symbol.dispose](): void;
|
|
129
|
+
/**
|
|
130
|
+
* Include or exclude AutoETS from the candidate set.
|
|
131
|
+
*
|
|
132
|
+
* @param include - Whether to include AutoETS (default: true)
|
|
133
|
+
*/
|
|
134
|
+
includeEts(include: boolean): AutoForecastBuilder;
|
|
135
|
+
/**
|
|
136
|
+
* Include or exclude AutoARIMA from the candidate set.
|
|
137
|
+
*
|
|
138
|
+
* @param include - Whether to include AutoARIMA (default: true)
|
|
139
|
+
*/
|
|
140
|
+
includeArima(include: boolean): AutoForecastBuilder;
|
|
141
|
+
/**
|
|
142
|
+
* Include or exclude AutoTheta from the candidate set.
|
|
143
|
+
*
|
|
144
|
+
* @param include - Whether to include AutoTheta (default: true)
|
|
145
|
+
*/
|
|
146
|
+
includeTheta(include: boolean): AutoForecastBuilder;
|
|
147
|
+
/**
|
|
148
|
+
* Set the seasonal period.
|
|
149
|
+
*
|
|
150
|
+
* @param period - Seasonal period (e.g., 12 for monthly data)
|
|
151
|
+
*/
|
|
152
|
+
seasonalPeriod(period: number): AutoForecastBuilder;
|
|
153
|
+
/**
|
|
154
|
+
* Use cross-validation instead of in-sample MSE for model selection.
|
|
155
|
+
*
|
|
156
|
+
* @param useCv - Whether to use cross-validation (default: false)
|
|
157
|
+
*/
|
|
158
|
+
useCrossValidation(use_cv: boolean): AutoForecastBuilder;
|
|
159
|
+
/**
|
|
160
|
+
* Create a new builder with all defaults enabled.
|
|
161
|
+
*/
|
|
162
|
+
constructor();
|
|
163
|
+
/**
|
|
164
|
+
* Build the AutoForecaster with the configured parameters.
|
|
165
|
+
*
|
|
166
|
+
* @returns A new AutoForecaster ready to fit
|
|
167
|
+
*/
|
|
168
|
+
build(): AutoForecaster;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
export class AutoForecaster {
|
|
172
|
+
free(): void;
|
|
173
|
+
[Symbol.dispose](): void;
|
|
174
|
+
/**
|
|
175
|
+
* Get all candidate scores as a JSON object.
|
|
176
|
+
*
|
|
177
|
+
* Returns an array of `{ name, score }` objects sorted by score (ascending).
|
|
178
|
+
*/
|
|
179
|
+
allScores(): any;
|
|
180
|
+
/**
|
|
181
|
+
* Create an AutoForecaster with custom configuration.
|
|
182
|
+
*
|
|
183
|
+
* @param seasonalPeriod - Seasonal period (0 or undefined for non-seasonal)
|
|
184
|
+
* @param includeArima - Include AutoARIMA candidate (default: true)
|
|
185
|
+
* @param includeEts - Include AutoETS candidate (default: true)
|
|
186
|
+
* @param includeTheta - Include AutoTheta candidate (default: true)
|
|
187
|
+
* @param useCrossValidation - Use cross-validation instead of in-sample MSE (default: false)
|
|
188
|
+
*/
|
|
189
|
+
static withConfig(seasonal_period?: number | null, include_arima?: boolean | null, include_ets?: boolean | null, include_theta?: boolean | null, use_cross_validation?: boolean | null): AutoForecaster;
|
|
190
|
+
/**
|
|
191
|
+
* Get the name of the selected model.
|
|
192
|
+
*
|
|
193
|
+
* @returns Name of the best model, or undefined if not yet fitted
|
|
194
|
+
*/
|
|
195
|
+
selectedModelName(): string | undefined;
|
|
196
|
+
/**
|
|
197
|
+
* Predict with prediction intervals.
|
|
198
|
+
*
|
|
199
|
+
* @param horizon - Number of steps to forecast
|
|
200
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
201
|
+
* @returns Forecast with point predictions and intervals
|
|
202
|
+
*/
|
|
203
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
204
|
+
/**
|
|
205
|
+
* Fit the model to a time series.
|
|
206
|
+
*
|
|
207
|
+
* Fits all candidate models and selects the best one.
|
|
208
|
+
*
|
|
209
|
+
* @param series - TimeSeries to fit
|
|
210
|
+
*/
|
|
211
|
+
fit(series: TimeSeries): void;
|
|
212
|
+
/**
|
|
213
|
+
* Create a new AutoForecaster with default configuration.
|
|
214
|
+
*
|
|
215
|
+
* By default, includes AutoARIMA, AutoETS, and AutoTheta candidates
|
|
216
|
+
* and uses in-sample MSE for model selection.
|
|
217
|
+
*/
|
|
218
|
+
constructor();
|
|
219
|
+
/**
|
|
220
|
+
* Predict future values.
|
|
221
|
+
*
|
|
222
|
+
* @param horizon - Number of steps to forecast
|
|
223
|
+
* @returns Forecast with point predictions
|
|
224
|
+
*/
|
|
225
|
+
predict(horizon: number): Forecast;
|
|
226
|
+
/**
|
|
227
|
+
* Create a seasonal AutoForecaster.
|
|
228
|
+
*
|
|
229
|
+
* @param period - Seasonal period (e.g., 12 for monthly data with yearly seasonality)
|
|
230
|
+
*/
|
|
231
|
+
static seasonal(period: number): AutoForecaster;
|
|
232
|
+
/**
|
|
233
|
+
* Get the model name.
|
|
234
|
+
*/
|
|
235
|
+
readonly name: string;
|
|
236
|
+
}
|
|
237
|
+
|
|
64
238
|
export class AutoTBATSForecaster {
|
|
65
239
|
free(): void;
|
|
66
240
|
[Symbol.dispose](): void;
|
|
@@ -83,9 +257,98 @@ export class AutoThetaForecaster {
|
|
|
83
257
|
readonly name: string;
|
|
84
258
|
}
|
|
85
259
|
|
|
260
|
+
export class CalendarAnnotations {
|
|
261
|
+
free(): void;
|
|
262
|
+
[Symbol.dispose](): void;
|
|
263
|
+
/**
|
|
264
|
+
* Check if a specific date is a holiday.
|
|
265
|
+
*
|
|
266
|
+
* @param timestamp_ms - Date to check as milliseconds since Unix epoch
|
|
267
|
+
* @returns true if the date matches any registered holiday
|
|
268
|
+
*/
|
|
269
|
+
isHoliday(timestamp_ms: number): boolean;
|
|
270
|
+
/**
|
|
271
|
+
* Add a single holiday date.
|
|
272
|
+
*
|
|
273
|
+
* @param timestamp_ms - Holiday date as milliseconds since Unix epoch
|
|
274
|
+
*/
|
|
275
|
+
addHoliday(timestamp_ms: number): void;
|
|
276
|
+
/**
|
|
277
|
+
* Get holiday dates as milliseconds since Unix epoch.
|
|
278
|
+
*/
|
|
279
|
+
getHolidays(): Float64Array;
|
|
280
|
+
/**
|
|
281
|
+
* Set multiple holiday dates at once (replaces any existing holidays).
|
|
282
|
+
*
|
|
283
|
+
* @param timestamps_ms - Array of holiday dates as milliseconds since Unix epoch
|
|
284
|
+
*/
|
|
285
|
+
setHolidays(timestamps_ms: Float64Array): void;
|
|
286
|
+
/**
|
|
287
|
+
* Add a named regressor with values aligned to the time series.
|
|
288
|
+
*
|
|
289
|
+
* The values array must have the same length as the time series this
|
|
290
|
+
* will be attached to. Common examples: promotional flags (0/1),
|
|
291
|
+
* temperature, price changes, etc.
|
|
292
|
+
*
|
|
293
|
+
* @param name - Name of the regressor (e.g., "promo", "temperature")
|
|
294
|
+
* @param values - Array of numeric values, one per time step
|
|
295
|
+
*/
|
|
296
|
+
addRegressor(name: string, values: Float64Array): void;
|
|
297
|
+
/**
|
|
298
|
+
* Get values for a named regressor.
|
|
299
|
+
*
|
|
300
|
+
* @param name - Regressor name
|
|
301
|
+
* @returns Array of values, or undefined if the regressor does not exist
|
|
302
|
+
*/
|
|
303
|
+
getRegressor(name: string): Float64Array | undefined;
|
|
304
|
+
/**
|
|
305
|
+
* Get the number of holidays.
|
|
306
|
+
*/
|
|
307
|
+
holidayCount(): number;
|
|
308
|
+
/**
|
|
309
|
+
* Check whether any regressors have been added.
|
|
310
|
+
*/
|
|
311
|
+
hasRegressors(): boolean;
|
|
312
|
+
/**
|
|
313
|
+
* Check if a specific date is a business day (not weekend, not holiday).
|
|
314
|
+
*
|
|
315
|
+
* @param timestamp_ms - Date to check as milliseconds since Unix epoch
|
|
316
|
+
* @returns true if the date is a weekday and not a holiday
|
|
317
|
+
*/
|
|
318
|
+
isBusinessDay(timestamp_ms: number): boolean;
|
|
319
|
+
/**
|
|
320
|
+
* Get the number of named regressors.
|
|
321
|
+
*/
|
|
322
|
+
regressorCount(): number;
|
|
323
|
+
/**
|
|
324
|
+
* Get the names of all registered regressors.
|
|
325
|
+
*/
|
|
326
|
+
regressorNames(): any;
|
|
327
|
+
/**
|
|
328
|
+
* Create an empty CalendarAnnotations instance.
|
|
329
|
+
*/
|
|
330
|
+
constructor();
|
|
331
|
+
/**
|
|
332
|
+
* Serialize the calendar annotations to a JSON string.
|
|
333
|
+
*
|
|
334
|
+
* Useful for persisting or transferring annotations between contexts.
|
|
335
|
+
*
|
|
336
|
+
* @returns JSON string with `{ holidays: number[], regressors: { [name]: number[] } }`
|
|
337
|
+
*/
|
|
338
|
+
toJSON(): string;
|
|
339
|
+
/**
|
|
340
|
+
* Deserialize calendar annotations from a JSON string.
|
|
341
|
+
*
|
|
342
|
+
* @param json - JSON string produced by `toJSON()`
|
|
343
|
+
* @returns A new CalendarAnnotations instance
|
|
344
|
+
*/
|
|
345
|
+
static fromJSON(json: string): CalendarAnnotations;
|
|
346
|
+
}
|
|
347
|
+
|
|
86
348
|
export class CrostonForecaster {
|
|
87
349
|
free(): void;
|
|
88
350
|
[Symbol.dispose](): void;
|
|
351
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
89
352
|
fit(series: TimeSeries): void;
|
|
90
353
|
constructor();
|
|
91
354
|
predict(horizon: number): Forecast;
|
|
@@ -165,104 +428,926 @@ export class ETSForecaster {
|
|
|
165
428
|
readonly name: string;
|
|
166
429
|
}
|
|
167
430
|
|
|
431
|
+
export class EnsembleForecaster {
|
|
432
|
+
free(): void;
|
|
433
|
+
[Symbol.dispose](): void;
|
|
434
|
+
/**
|
|
435
|
+
* Set the combination method to median.
|
|
436
|
+
*/
|
|
437
|
+
setMedian(): void;
|
|
438
|
+
/**
|
|
439
|
+
* Set the combination method by name string.
|
|
440
|
+
*
|
|
441
|
+
* Supported values: "mean", "median", "weighted_mse", "inverse_aic",
|
|
442
|
+
* "stacking", "horizon_adaptive".
|
|
443
|
+
*
|
|
444
|
+
* @param method - Combination method name
|
|
445
|
+
*/
|
|
446
|
+
setMethod(method: string): void;
|
|
447
|
+
/**
|
|
448
|
+
* Get the number of models in the ensemble.
|
|
449
|
+
*/
|
|
450
|
+
modelCount(): number;
|
|
451
|
+
/**
|
|
452
|
+
* Set custom combination weights.
|
|
453
|
+
*
|
|
454
|
+
* Weights are normalized to sum to 1. Length must match number of models.
|
|
455
|
+
*
|
|
456
|
+
* @param weights - Array of combination weights
|
|
457
|
+
*/
|
|
458
|
+
setWeights(weights: Float64Array): void;
|
|
459
|
+
/**
|
|
460
|
+
* Set the combination method to stacking (projected gradient descent).
|
|
461
|
+
*
|
|
462
|
+
* Trains non-negative weights that sum to one on validation data.
|
|
463
|
+
*
|
|
464
|
+
* @param folds - Number of folds (default: 5)
|
|
465
|
+
*/
|
|
466
|
+
setStacking(folds?: number | null): void;
|
|
467
|
+
/**
|
|
468
|
+
* Set the combination method to inverse AIC weighting.
|
|
469
|
+
*
|
|
470
|
+
* Computes Akaike weights from in-sample residuals.
|
|
471
|
+
*/
|
|
472
|
+
setInverseAic(): void;
|
|
473
|
+
/**
|
|
474
|
+
* Set the combination method to weighted MSE.
|
|
475
|
+
*/
|
|
476
|
+
setWeightedMse(): void;
|
|
477
|
+
/**
|
|
478
|
+
* Set the combination method to per-horizon adaptive weighting.
|
|
479
|
+
*
|
|
480
|
+
* Computes separate weight vectors for each forecast horizon step
|
|
481
|
+
* based on rolling-origin evaluation.
|
|
482
|
+
*/
|
|
483
|
+
setHorizonAdaptive(): void;
|
|
484
|
+
/**
|
|
485
|
+
* Predict with prediction intervals.
|
|
486
|
+
*
|
|
487
|
+
* @param horizon - Number of steps to forecast
|
|
488
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
489
|
+
* @returns Forecast with combined predictions and intervals
|
|
490
|
+
*/
|
|
491
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
492
|
+
/**
|
|
493
|
+
* Fit all models in the ensemble.
|
|
494
|
+
*
|
|
495
|
+
* @param series - TimeSeries to fit
|
|
496
|
+
*/
|
|
497
|
+
fit(series: TimeSeries): void;
|
|
498
|
+
/**
|
|
499
|
+
* Create an ensemble from an array of model name strings.
|
|
500
|
+
*
|
|
501
|
+
* Supported names: "naive", "mean", "rwdrift", "ses", "holt",
|
|
502
|
+
* "autoarima", "autoets", "autotheta", "sma5", "wa10", etc.
|
|
503
|
+
*
|
|
504
|
+
* @param modelNames - Array of model name strings
|
|
505
|
+
*/
|
|
506
|
+
constructor(model_names: string[]);
|
|
507
|
+
/**
|
|
508
|
+
* Predict future values using the combined ensemble.
|
|
509
|
+
*
|
|
510
|
+
* @param horizon - Number of steps to forecast
|
|
511
|
+
* @returns Forecast with combined point predictions
|
|
512
|
+
*/
|
|
513
|
+
predict(horizon: number): Forecast;
|
|
514
|
+
/**
|
|
515
|
+
* Get the model name.
|
|
516
|
+
*/
|
|
517
|
+
readonly name: string;
|
|
518
|
+
}
|
|
519
|
+
|
|
168
520
|
export class Forecast {
|
|
169
521
|
private constructor();
|
|
170
522
|
free(): void;
|
|
171
523
|
[Symbol.dispose](): void;
|
|
172
524
|
/**
|
|
173
|
-
*
|
|
174
|
-
*/
|
|
175
|
-
|
|
176
|
-
/**
|
|
177
|
-
*
|
|
525
|
+
* Return a new forecast with all values clamped to be non-negative.
|
|
526
|
+
*/
|
|
527
|
+
nonNegative(): Forecast;
|
|
528
|
+
/**
|
|
529
|
+
* Return a new forecast with point values rounded to the nearest integer,
|
|
530
|
+
* lower intervals floored, and upper intervals ceiled.
|
|
531
|
+
*/
|
|
532
|
+
roundToInteger(): Forecast;
|
|
533
|
+
/**
|
|
534
|
+
* Return a new forecast with all values clamped to `[lower, upper]`.
|
|
535
|
+
*
|
|
536
|
+
* @param lower - Lower bound
|
|
537
|
+
* @param upper - Upper bound
|
|
538
|
+
*/
|
|
539
|
+
clamp(lower: number, upper: number): Forecast;
|
|
540
|
+
/**
|
|
541
|
+
* Check if lower prediction interval is available.
|
|
542
|
+
*/
|
|
543
|
+
hasLower(): boolean;
|
|
544
|
+
/**
|
|
545
|
+
* Check if upper prediction interval is available.
|
|
546
|
+
*/
|
|
547
|
+
hasUpper(): boolean;
|
|
548
|
+
/**
|
|
549
|
+
* Get lower prediction interval bounds.
|
|
550
|
+
*
|
|
551
|
+
* @returns Array of lower bounds, or undefined if not available
|
|
552
|
+
*/
|
|
553
|
+
readonly lower: Float64Array | undefined;
|
|
554
|
+
/**
|
|
555
|
+
* Get upper prediction interval bounds.
|
|
556
|
+
*
|
|
557
|
+
* @returns Array of upper bounds, or undefined if not available
|
|
558
|
+
*/
|
|
559
|
+
readonly upper: Float64Array | undefined;
|
|
560
|
+
/**
|
|
561
|
+
* Get point predictions.
|
|
562
|
+
*/
|
|
563
|
+
readonly values: Float64Array;
|
|
564
|
+
/**
|
|
565
|
+
* Get the forecast horizon (number of predictions).
|
|
566
|
+
*/
|
|
567
|
+
readonly horizon: number;
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
export class GARCHForecaster {
|
|
571
|
+
free(): void;
|
|
572
|
+
[Symbol.dispose](): void;
|
|
573
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
574
|
+
fit(series: TimeSeries): void;
|
|
575
|
+
/**
|
|
576
|
+
* @param p - GARCH order (lagged variance terms)
|
|
577
|
+
* @param q - ARCH order (lagged squared residuals)
|
|
578
|
+
*/
|
|
579
|
+
constructor(p: number, q: number);
|
|
580
|
+
predict(horizon: number): Forecast;
|
|
581
|
+
readonly name: string;
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
export class HoltForecaster {
|
|
585
|
+
free(): void;
|
|
586
|
+
[Symbol.dispose](): void;
|
|
587
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
588
|
+
fit(series: TimeSeries): void;
|
|
589
|
+
/**
|
|
590
|
+
* @param alpha - Level smoothing parameter (0 < alpha <= 1)
|
|
591
|
+
* @param beta - Trend smoothing parameter (0 < beta <= 1)
|
|
592
|
+
*/
|
|
593
|
+
constructor(alpha: number, beta: number);
|
|
594
|
+
predict(horizon: number): Forecast;
|
|
595
|
+
readonly name: string;
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
export class HoltWintersForecaster {
|
|
599
|
+
free(): void;
|
|
600
|
+
[Symbol.dispose](): void;
|
|
601
|
+
/**
|
|
602
|
+
* Create with multiplicative seasonality.
|
|
603
|
+
*/
|
|
604
|
+
static multiplicative(alpha: number, beta: number, gamma: number, period: number): HoltWintersForecaster;
|
|
605
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
606
|
+
fit(series: TimeSeries): void;
|
|
607
|
+
/**
|
|
608
|
+
* Create with additive seasonality.
|
|
609
|
+
* @param alpha - Level smoothing parameter
|
|
610
|
+
* @param beta - Trend smoothing parameter
|
|
611
|
+
* @param gamma - Seasonal smoothing parameter
|
|
612
|
+
* @param period - Seasonal period
|
|
613
|
+
*/
|
|
614
|
+
constructor(alpha: number, beta: number, gamma: number, period: number);
|
|
615
|
+
/**
|
|
616
|
+
* Create with automatic parameter optimization.
|
|
617
|
+
* @param period - Seasonal period
|
|
618
|
+
* @param seasonal_type - "additive" or "multiplicative"
|
|
619
|
+
*/
|
|
620
|
+
static auto(period: number, seasonal_type: string): HoltWintersForecaster;
|
|
621
|
+
predict(horizon: number): Forecast;
|
|
622
|
+
readonly name: string;
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
export class IMAPAForecaster {
|
|
626
|
+
free(): void;
|
|
627
|
+
[Symbol.dispose](): void;
|
|
628
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
629
|
+
fit(series: TimeSeries): void;
|
|
630
|
+
constructor();
|
|
631
|
+
predict(horizon: number): Forecast;
|
|
632
|
+
readonly name: string;
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
export class JsBacktestConfig {
|
|
636
|
+
free(): void;
|
|
637
|
+
[Symbol.dispose](): void;
|
|
638
|
+
/**
|
|
639
|
+
* Set the initial training window size.
|
|
640
|
+
*/
|
|
641
|
+
initialWindow(size: number): JsBacktestConfig;
|
|
642
|
+
/**
|
|
643
|
+
* Create a new backtest configuration with default settings.
|
|
644
|
+
*
|
|
645
|
+
* Defaults: initial_window=50, step=1, horizon=1, expanding=true.
|
|
646
|
+
*/
|
|
647
|
+
constructor();
|
|
648
|
+
/**
|
|
649
|
+
* Set the step size between folds.
|
|
650
|
+
*/
|
|
651
|
+
step(step: number): JsBacktestConfig;
|
|
652
|
+
/**
|
|
653
|
+
* Set the forecast horizon.
|
|
654
|
+
*/
|
|
655
|
+
horizon(horizon: number): JsBacktestConfig;
|
|
656
|
+
/**
|
|
657
|
+
* Set whether to use expanding (true) or rolling (false) window.
|
|
658
|
+
*/
|
|
659
|
+
expanding(expanding: boolean): JsBacktestConfig;
|
|
660
|
+
}
|
|
661
|
+
|
|
662
|
+
export class JsBacktestResult {
|
|
663
|
+
private constructor();
|
|
664
|
+
free(): void;
|
|
665
|
+
[Symbol.dispose](): void;
|
|
666
|
+
/**
|
|
667
|
+
* Get average interval width across all folds.
|
|
668
|
+
*/
|
|
669
|
+
intervalWidths(): number;
|
|
670
|
+
/**
|
|
671
|
+
* Get calibration error (absolute deviation from target coverage).
|
|
672
|
+
*/
|
|
673
|
+
calibrationError(target_coverage: number): number;
|
|
674
|
+
/**
|
|
675
|
+
* Get the number of backtest folds.
|
|
676
|
+
*/
|
|
677
|
+
numFolds(): number;
|
|
678
|
+
/**
|
|
679
|
+
* Get overall coverage across all folds.
|
|
680
|
+
*/
|
|
681
|
+
readonly coverage: number;
|
|
682
|
+
}
|
|
683
|
+
|
|
684
|
+
export class JsConformalPredictor {
|
|
685
|
+
free(): void;
|
|
686
|
+
[Symbol.dispose](): void;
|
|
687
|
+
/**
|
|
688
|
+
* Create a conformal predictor with the Jackknife+ method.
|
|
689
|
+
*
|
|
690
|
+
* @param coverage - Target coverage level in (0, 1)
|
|
691
|
+
*/
|
|
692
|
+
static jackknifePlus(coverage: number): JsConformalPredictor;
|
|
693
|
+
/**
|
|
694
|
+
* Generate prediction intervals for new point forecasts.
|
|
695
|
+
*
|
|
696
|
+
* @param result - A fitted JsConformalResult from calibrate()
|
|
697
|
+
* @param pointForecasts - New point forecast values
|
|
698
|
+
*/
|
|
699
|
+
predictIntervals(result: JsConformalResult, point_forecasts: Float64Array): JsPredictionIntervals;
|
|
700
|
+
/**
|
|
701
|
+
* Create a split conformal predictor.
|
|
702
|
+
*
|
|
703
|
+
* @param coverage - Target coverage level in (0, 1), e.g. 0.90
|
|
704
|
+
*/
|
|
705
|
+
constructor(coverage: number);
|
|
706
|
+
/**
|
|
707
|
+
* Calibrate (fit) the predictor on historical forecasts and actuals.
|
|
708
|
+
*
|
|
709
|
+
* @param forecasts - Historical point forecast values
|
|
710
|
+
* @param actuals - Corresponding actual observed values
|
|
711
|
+
*/
|
|
712
|
+
calibrate(forecasts: Float64Array, actuals: Float64Array): JsConformalResult;
|
|
713
|
+
/**
|
|
714
|
+
* Create a conformal predictor with the cross-validation method.
|
|
715
|
+
*
|
|
716
|
+
* @param coverage - Target coverage level in (0, 1)
|
|
717
|
+
* @param nFolds - Number of cross-validation folds
|
|
718
|
+
*/
|
|
719
|
+
static crossVal(coverage: number, n_folds: number): JsConformalPredictor;
|
|
720
|
+
}
|
|
721
|
+
|
|
722
|
+
export class JsConformalResult {
|
|
723
|
+
private constructor();
|
|
724
|
+
free(): void;
|
|
725
|
+
[Symbol.dispose](): void;
|
|
726
|
+
/**
|
|
727
|
+
* Get the quantile value (interval half-width).
|
|
728
|
+
*/
|
|
729
|
+
quantileValue(): number;
|
|
730
|
+
/**
|
|
731
|
+
* Get the nonconformity scores.
|
|
732
|
+
*/
|
|
733
|
+
scores(): Float64Array;
|
|
734
|
+
/**
|
|
735
|
+
* Get the coverage level.
|
|
736
|
+
*/
|
|
737
|
+
readonly coverage: number;
|
|
738
|
+
}
|
|
739
|
+
|
|
740
|
+
export class JsDataProfile {
|
|
741
|
+
private constructor();
|
|
742
|
+
free(): void;
|
|
743
|
+
[Symbol.dispose](): void;
|
|
744
|
+
/**
|
|
745
|
+
* Profile a time series.
|
|
746
|
+
*
|
|
747
|
+
* @param series - TimeSeries to profile
|
|
748
|
+
* @returns A comprehensive data profile
|
|
749
|
+
*/
|
|
750
|
+
static fromSeries(series: TimeSeries): JsDataProfile;
|
|
751
|
+
/**
|
|
752
|
+
* Profile raw values (without timestamps).
|
|
753
|
+
*
|
|
754
|
+
* @param values - Array of numeric values
|
|
755
|
+
* @returns A data profile
|
|
756
|
+
*/
|
|
757
|
+
static fromValues(values: Float64Array): JsDataProfile;
|
|
758
|
+
/**
|
|
759
|
+
* Full profile as a formatted string.
|
|
760
|
+
*/
|
|
761
|
+
toString(): string;
|
|
762
|
+
/**
|
|
763
|
+
* Human-readable summary string.
|
|
764
|
+
*/
|
|
765
|
+
summary(): string;
|
|
766
|
+
/**
|
|
767
|
+
* Profile as a JSON-serializable object.
|
|
768
|
+
*/
|
|
769
|
+
toJSON(): any;
|
|
770
|
+
/**
|
|
771
|
+
* Whether every finite value is integer-valued.
|
|
772
|
+
*/
|
|
773
|
+
readonly isInteger: boolean;
|
|
774
|
+
/**
|
|
775
|
+
* Lempel-Ziv complexity (normalized).
|
|
776
|
+
*/
|
|
777
|
+
readonly lempelZiv: number;
|
|
778
|
+
/**
|
|
779
|
+
* ADF p-value.
|
|
780
|
+
*/
|
|
781
|
+
readonly adfPValue: number;
|
|
782
|
+
/**
|
|
783
|
+
* Slope of the linear trend.
|
|
784
|
+
*/
|
|
785
|
+
readonly trendSlope: number;
|
|
786
|
+
/**
|
|
787
|
+
* KPSS p-value.
|
|
788
|
+
*/
|
|
789
|
+
readonly kpssPValue: number;
|
|
790
|
+
/**
|
|
791
|
+
* ADF test statistic.
|
|
792
|
+
*/
|
|
793
|
+
readonly adfStatistic: number;
|
|
794
|
+
/**
|
|
795
|
+
* Whether any value is negative.
|
|
796
|
+
*/
|
|
797
|
+
readonly hasNegatives: boolean;
|
|
798
|
+
/**
|
|
799
|
+
* Combined stationarity (ADF stationary AND KPSS stationary).
|
|
800
|
+
*/
|
|
801
|
+
readonly isStationary: boolean;
|
|
802
|
+
/**
|
|
803
|
+
* Count of NaN or infinite values.
|
|
804
|
+
*/
|
|
805
|
+
readonly missingCount: number;
|
|
806
|
+
/**
|
|
807
|
+
* Heuristic data-quality score in [0.0, 1.0].
|
|
808
|
+
*/
|
|
809
|
+
readonly qualityScore: number;
|
|
810
|
+
/**
|
|
811
|
+
* Fraction of values that are exactly zero.
|
|
812
|
+
*/
|
|
813
|
+
readonly zeroFraction: number;
|
|
814
|
+
/**
|
|
815
|
+
* KPSS test statistic.
|
|
816
|
+
*/
|
|
817
|
+
readonly kpssStatistic: number;
|
|
818
|
+
/**
|
|
819
|
+
* Number of observations.
|
|
820
|
+
*/
|
|
821
|
+
readonly nObservations: number;
|
|
822
|
+
/**
|
|
823
|
+
* Trend strength (R-squared, 0.0 to 1.0).
|
|
824
|
+
*/
|
|
825
|
+
readonly trendStrength: number;
|
|
826
|
+
/**
|
|
827
|
+
* Whether the series is classified as intermittent.
|
|
828
|
+
*/
|
|
829
|
+
readonly isIntermittent: boolean;
|
|
830
|
+
/**
|
|
831
|
+
* Trend direction: "Rising", "Falling", or "Flat".
|
|
832
|
+
*/
|
|
833
|
+
readonly trendDirection: string;
|
|
834
|
+
/**
|
|
835
|
+
* Partial autocorrelation at lag 1.
|
|
836
|
+
*/
|
|
837
|
+
readonly partialAcfLag1: number;
|
|
838
|
+
/**
|
|
839
|
+
* Whether ADF concludes stationarity at 5%.
|
|
840
|
+
*/
|
|
841
|
+
readonly adfIsStationary: boolean;
|
|
842
|
+
/**
|
|
843
|
+
* Whether KPSS concludes stationarity at 5%.
|
|
844
|
+
*/
|
|
845
|
+
readonly kpssIsStationary: boolean;
|
|
846
|
+
/**
|
|
847
|
+
* Approximate entropy (undefined if series is too short).
|
|
848
|
+
*/
|
|
849
|
+
readonly approximateEntropy: number | undefined;
|
|
850
|
+
/**
|
|
851
|
+
* Maximum value.
|
|
852
|
+
*/
|
|
853
|
+
readonly max: number;
|
|
854
|
+
/**
|
|
855
|
+
* Minimum value.
|
|
856
|
+
*/
|
|
857
|
+
readonly min: number;
|
|
858
|
+
/**
|
|
859
|
+
* Arithmetic mean.
|
|
860
|
+
*/
|
|
861
|
+
readonly mean: number;
|
|
862
|
+
/**
|
|
863
|
+
* Standard deviation.
|
|
864
|
+
*/
|
|
865
|
+
readonly stdDev: number;
|
|
866
|
+
/**
|
|
867
|
+
* Autocorrelation at lag 1.
|
|
868
|
+
*/
|
|
869
|
+
readonly acfLag1: number;
|
|
870
|
+
/**
|
|
871
|
+
* Autocorrelation at lag 2.
|
|
872
|
+
*/
|
|
873
|
+
readonly acfLag2: number;
|
|
874
|
+
/**
|
|
875
|
+
* Excess kurtosis.
|
|
876
|
+
*/
|
|
877
|
+
readonly kurtosis: number;
|
|
878
|
+
/**
|
|
879
|
+
* Skewness.
|
|
880
|
+
*/
|
|
881
|
+
readonly skewness: number;
|
|
882
|
+
}
|
|
883
|
+
|
|
884
|
+
export class JsHistoricalSimResult {
|
|
885
|
+
private constructor();
|
|
886
|
+
free(): void;
|
|
887
|
+
[Symbol.dispose](): void;
|
|
888
|
+
/**
|
|
889
|
+
* Get the quantile values.
|
|
890
|
+
*/
|
|
891
|
+
quantileValues(): Float64Array;
|
|
892
|
+
/**
|
|
893
|
+
* Get the sorted errors.
|
|
894
|
+
*/
|
|
895
|
+
errors(): Float64Array;
|
|
896
|
+
}
|
|
897
|
+
|
|
898
|
+
export class JsHistoricalSimulator {
|
|
899
|
+
free(): void;
|
|
900
|
+
[Symbol.dispose](): void;
|
|
901
|
+
/**
|
|
902
|
+
* Create a simulator with a rolling window.
|
|
903
|
+
*
|
|
904
|
+
* @param quantiles - Sorted quantile levels in (0,1)
|
|
905
|
+
* @param window - Number of recent observations to use
|
|
906
|
+
*/
|
|
907
|
+
static withWindow(quantiles: Float64Array, window: number): JsHistoricalSimulator;
|
|
908
|
+
/**
|
|
909
|
+
* Generate prediction intervals for new point forecasts.
|
|
910
|
+
*
|
|
911
|
+
* @param result - A fitted JsHistoricalSimResult from simulate()
|
|
912
|
+
* @param pointForecasts - New point forecast values
|
|
913
|
+
*/
|
|
914
|
+
predictIntervals(result: JsHistoricalSimResult, point_forecasts: Float64Array): JsPredictionIntervals;
|
|
915
|
+
/**
|
|
916
|
+
* Create a new historical simulator.
|
|
917
|
+
*
|
|
918
|
+
* @param quantiles - Sorted quantile levels in (0,1), e.g. [0.1, 0.5, 0.9]
|
|
919
|
+
*/
|
|
920
|
+
constructor(quantiles: Float64Array);
|
|
921
|
+
/**
|
|
922
|
+
* Fit the simulator on historical forecasts and actuals.
|
|
923
|
+
*
|
|
924
|
+
* @param forecasts - Historical point forecast values
|
|
925
|
+
* @param actuals - Corresponding actual observed values
|
|
926
|
+
*/
|
|
927
|
+
simulate(forecasts: Float64Array, actuals: Float64Array): JsHistoricalSimResult;
|
|
928
|
+
}
|
|
929
|
+
|
|
930
|
+
export class JsModelDiagnostics {
|
|
931
|
+
private constructor();
|
|
932
|
+
free(): void;
|
|
933
|
+
[Symbol.dispose](): void;
|
|
934
|
+
/**
|
|
935
|
+
* Create diagnostics from an array of residuals.
|
|
936
|
+
*
|
|
937
|
+
* @param residuals - Array of model residuals
|
|
938
|
+
* @param significance - Significance level for tests (e.g., 0.05)
|
|
939
|
+
*/
|
|
940
|
+
static fromResiduals(residuals: Float64Array, significance: number): JsModelDiagnostics;
|
|
941
|
+
/**
|
|
942
|
+
* Get a human-readable summary of the diagnostics.
|
|
943
|
+
*/
|
|
944
|
+
summary(): string;
|
|
945
|
+
/**
|
|
946
|
+
* Whether all diagnostic tests pass at the configured significance level.
|
|
947
|
+
*/
|
|
948
|
+
readonly passesAll: boolean;
|
|
949
|
+
/**
|
|
950
|
+
* Autocorrelation function of the residuals.
|
|
951
|
+
*/
|
|
952
|
+
readonly residualAcf: Float64Array;
|
|
953
|
+
/**
|
|
954
|
+
* Standard deviation of the residuals.
|
|
955
|
+
*/
|
|
956
|
+
readonly residualStd: number;
|
|
957
|
+
/**
|
|
958
|
+
* Mean of the residuals.
|
|
959
|
+
*/
|
|
960
|
+
readonly residualMean: number;
|
|
961
|
+
/**
|
|
962
|
+
* Partial autocorrelation function of the residuals.
|
|
963
|
+
*/
|
|
964
|
+
readonly residualPacf: Float64Array;
|
|
965
|
+
/**
|
|
966
|
+
* Number of lags used in the Ljung-Box test.
|
|
967
|
+
*/
|
|
968
|
+
readonly ljungBoxLags: number;
|
|
969
|
+
/**
|
|
970
|
+
* Ljung-Box test p-value for autocorrelation.
|
|
971
|
+
*/
|
|
972
|
+
readonly ljungBoxPvalue: number;
|
|
973
|
+
/**
|
|
974
|
+
* Jarque-Bera test p-value.
|
|
975
|
+
*/
|
|
976
|
+
readonly jarqueBeraPvalue: number;
|
|
977
|
+
/**
|
|
978
|
+
* Jarque-Bera test statistic for normality.
|
|
979
|
+
*/
|
|
980
|
+
readonly jarqueBeraStatistic: number;
|
|
981
|
+
/**
|
|
982
|
+
* Breusch-Pagan heteroscedasticity test p-value.
|
|
983
|
+
*/
|
|
984
|
+
readonly heteroscedasticityPvalue: number;
|
|
985
|
+
}
|
|
986
|
+
|
|
987
|
+
export class JsNormalPredictor {
|
|
988
|
+
free(): void;
|
|
989
|
+
[Symbol.dispose](): void;
|
|
990
|
+
/**
|
|
991
|
+
* Generate prediction intervals for new point forecasts.
|
|
992
|
+
*
|
|
993
|
+
* Returns intervals using the first and last quantile as bounds.
|
|
994
|
+
*
|
|
995
|
+
* @param result - A fitted JsNormalResult from fit()
|
|
996
|
+
* @param pointForecasts - New point forecast values
|
|
997
|
+
*/
|
|
998
|
+
predictIntervals(result: JsNormalResult, point_forecasts: Float64Array): JsPredictionIntervals;
|
|
999
|
+
/**
|
|
1000
|
+
* Fit the predictor on historical forecasts and actuals.
|
|
1001
|
+
*
|
|
1002
|
+
* @param forecasts - Historical point forecast values
|
|
1003
|
+
* @param actuals - Corresponding actual observed values
|
|
1004
|
+
*/
|
|
1005
|
+
fit(forecasts: Float64Array, actuals: Float64Array): JsNormalResult;
|
|
1006
|
+
/**
|
|
1007
|
+
* Create a new normal predictor.
|
|
1008
|
+
*
|
|
1009
|
+
* @param quantiles - Sorted quantile levels in (0,1), e.g. [0.1, 0.5, 0.9]
|
|
1010
|
+
*/
|
|
1011
|
+
constructor(quantiles: Float64Array);
|
|
1012
|
+
}
|
|
1013
|
+
|
|
1014
|
+
export class JsNormalResult {
|
|
1015
|
+
private constructor();
|
|
1016
|
+
free(): void;
|
|
1017
|
+
[Symbol.dispose](): void;
|
|
1018
|
+
/**
|
|
1019
|
+
* Get the standard deviation of errors.
|
|
1020
|
+
*/
|
|
1021
|
+
stdDev(): number;
|
|
1022
|
+
/**
|
|
1023
|
+
* Get the mean error (bias).
|
|
1024
|
+
*/
|
|
1025
|
+
readonly mean: number;
|
|
1026
|
+
}
|
|
1027
|
+
|
|
1028
|
+
export class JsPipelineBuilder {
|
|
1029
|
+
free(): void;
|
|
1030
|
+
[Symbol.dispose](): void;
|
|
1031
|
+
/**
|
|
1032
|
+
* Set preprocessing mode.
|
|
1033
|
+
*
|
|
1034
|
+
* @param mode - "auto", "none", or "manual"
|
|
1035
|
+
*/
|
|
1036
|
+
preprocess(mode: string): JsPipelineBuilder;
|
|
1037
|
+
/**
|
|
1038
|
+
* Apply non-negative constraint to forecasts.
|
|
1039
|
+
*/
|
|
1040
|
+
nonNegative(): JsPipelineBuilder;
|
|
1041
|
+
/**
|
|
1042
|
+
* Select top-K models for evaluation.
|
|
1043
|
+
*
|
|
1044
|
+
* @param k - Number of models to select
|
|
1045
|
+
*/
|
|
1046
|
+
selectModels(k: number): JsPipelineBuilder;
|
|
1047
|
+
/**
|
|
1048
|
+
* Enable fallback chain (Naive → SMA).
|
|
1049
|
+
*/
|
|
1050
|
+
withFallback(): JsPipelineBuilder;
|
|
1051
|
+
/**
|
|
1052
|
+
* Enable cross-validation.
|
|
1053
|
+
*
|
|
1054
|
+
* @param folds - Number of CV folds
|
|
1055
|
+
* @param horizon - Forecast horizon for each fold
|
|
1056
|
+
*/
|
|
1057
|
+
crossValidate(folds: number, horizon: number): JsPipelineBuilder;
|
|
1058
|
+
/**
|
|
1059
|
+
* Set the seasonal period hint.
|
|
1060
|
+
*
|
|
1061
|
+
* @param period - Seasonal period (e.g., 12 for monthly data)
|
|
1062
|
+
*/
|
|
1063
|
+
seasonalPeriod(period: number): JsPipelineBuilder;
|
|
1064
|
+
/**
|
|
1065
|
+
* Add a seasonal model to the pipeline.
|
|
1066
|
+
*
|
|
1067
|
+
* @param name - Model name (e.g., "SeasonalNaive")
|
|
1068
|
+
* @param period - Seasonal period
|
|
1069
|
+
*/
|
|
1070
|
+
addSeasonalModel(name: string, period: number): JsPipelineBuilder;
|
|
1071
|
+
/**
|
|
1072
|
+
* Create a new pipeline builder.
|
|
1073
|
+
*/
|
|
1074
|
+
constructor();
|
|
1075
|
+
/**
|
|
1076
|
+
* Set the metric strategy for model selection.
|
|
1077
|
+
*
|
|
1078
|
+
* @param strategy - "auto", "mae", "mse", "rmse", "smape", "wape", or "mda"
|
|
1079
|
+
*/
|
|
1080
|
+
metric(strategy: string): JsPipelineBuilder;
|
|
1081
|
+
/**
|
|
1082
|
+
* Build and execute the pipeline.
|
|
1083
|
+
*
|
|
1084
|
+
* @param series - TimeSeries to forecast
|
|
1085
|
+
* @param horizon - Number of steps to forecast
|
|
1086
|
+
* @returns JsPipelineResult with forecast, profile, and diagnostics
|
|
1087
|
+
*/
|
|
1088
|
+
execute(series: TimeSeries, horizon: number): JsPipelineResult;
|
|
1089
|
+
/**
|
|
1090
|
+
* Enable data profiling.
|
|
1091
|
+
*/
|
|
1092
|
+
profile(): JsPipelineBuilder;
|
|
1093
|
+
/**
|
|
1094
|
+
* Set the ensemble mode.
|
|
1095
|
+
*
|
|
1096
|
+
* @param mode - "auto", "none", "mean", "median", or "weighted"
|
|
1097
|
+
*/
|
|
1098
|
+
ensemble(mode: string): JsPipelineBuilder;
|
|
1099
|
+
/**
|
|
1100
|
+
* Add a built-in model to the pipeline.
|
|
1101
|
+
*
|
|
1102
|
+
* Supported models: "Naive", "SES", "SMA", "SMA5", "SMA10"
|
|
1103
|
+
*
|
|
1104
|
+
* @param name - Model name
|
|
1105
|
+
*/
|
|
1106
|
+
addModel(name: string): JsPipelineBuilder;
|
|
1107
|
+
}
|
|
1108
|
+
|
|
1109
|
+
export class JsPipelineReport {
|
|
1110
|
+
private constructor();
|
|
1111
|
+
free(): void;
|
|
1112
|
+
[Symbol.dispose](): void;
|
|
1113
|
+
/**
|
|
1114
|
+
* Get the full report as formatted text.
|
|
1115
|
+
*/
|
|
1116
|
+
toString(): string;
|
|
1117
|
+
/**
|
|
1118
|
+
* Get a section heading by index.
|
|
1119
|
+
*/
|
|
1120
|
+
sectionHeading(index: number): string | undefined;
|
|
1121
|
+
/**
|
|
1122
|
+
* Get the report as a JSON object.
|
|
1123
|
+
*
|
|
1124
|
+
* Returns `{ title, sections: [{ heading, content }] }`.
|
|
1125
|
+
*/
|
|
1126
|
+
toJSON(): any;
|
|
1127
|
+
/**
|
|
1128
|
+
* Get the number of sections.
|
|
1129
|
+
*/
|
|
1130
|
+
readonly sectionCount: number;
|
|
1131
|
+
/**
|
|
1132
|
+
* Get the report title.
|
|
1133
|
+
*/
|
|
1134
|
+
readonly title: string;
|
|
1135
|
+
}
|
|
1136
|
+
|
|
1137
|
+
export class JsPipelineResult {
|
|
1138
|
+
private constructor();
|
|
1139
|
+
free(): void;
|
|
1140
|
+
[Symbol.dispose](): void;
|
|
1141
|
+
/**
|
|
1142
|
+
* Get a human-readable summary of the result.
|
|
1143
|
+
*/
|
|
1144
|
+
toString(): string;
|
|
1145
|
+
/**
|
|
1146
|
+
* Generate a full structured report.
|
|
1147
|
+
*/
|
|
1148
|
+
report(): JsPipelineReport;
|
|
1149
|
+
/**
|
|
1150
|
+
* Get the name of the selected model.
|
|
1151
|
+
*/
|
|
1152
|
+
readonly modelName: string;
|
|
1153
|
+
/**
|
|
1154
|
+
* Get the decision log as a formatted string.
|
|
1155
|
+
*/
|
|
1156
|
+
readonly decisionLog: string;
|
|
1157
|
+
/**
|
|
1158
|
+
* Get metric scores as JSON (undefined if not computed).
|
|
1159
|
+
*/
|
|
1160
|
+
readonly metricScores: any;
|
|
1161
|
+
/**
|
|
1162
|
+
* Get quality floor result (undefined if not computed).
|
|
1163
|
+
*/
|
|
1164
|
+
readonly qualityFloor: string | undefined;
|
|
1165
|
+
/**
|
|
1166
|
+
* Get the number of decisions in the log.
|
|
1167
|
+
*/
|
|
1168
|
+
readonly decisionCount: number;
|
|
1169
|
+
/**
|
|
1170
|
+
* Get preprocessing info (undefined if not applied).
|
|
1171
|
+
*/
|
|
1172
|
+
readonly preprocessInfo: any;
|
|
1173
|
+
/**
|
|
1174
|
+
* Get ensemble weights as JSON (undefined if not an ensemble).
|
|
1175
|
+
*/
|
|
1176
|
+
readonly ensembleWeights: any;
|
|
1177
|
+
/**
|
|
1178
|
+
* Get model confidence set (undefined if not computed).
|
|
1179
|
+
*/
|
|
1180
|
+
readonly modelConfidenceSet: any;
|
|
1181
|
+
/**
|
|
1182
|
+
* Get selection confidence (undefined if not computed).
|
|
1183
|
+
*/
|
|
1184
|
+
readonly selectionConfidence: string | undefined;
|
|
1185
|
+
/**
|
|
1186
|
+
* Get the data profile (undefined if profiling was not enabled).
|
|
1187
|
+
*/
|
|
1188
|
+
readonly profile: JsDataProfile | undefined;
|
|
1189
|
+
/**
|
|
1190
|
+
* Get the forecast.
|
|
1191
|
+
*/
|
|
1192
|
+
readonly forecast: Forecast;
|
|
1193
|
+
}
|
|
1194
|
+
|
|
1195
|
+
export class JsPointForecasts {
|
|
1196
|
+
free(): void;
|
|
1197
|
+
[Symbol.dispose](): void;
|
|
1198
|
+
/**
|
|
1199
|
+
* Create point forecasts from an array of values.
|
|
1200
|
+
*/
|
|
1201
|
+
constructor(values: Float64Array);
|
|
1202
|
+
/**
|
|
1203
|
+
* Check if empty.
|
|
1204
|
+
*/
|
|
1205
|
+
isEmpty(): boolean;
|
|
1206
|
+
/**
|
|
1207
|
+
* Get the number of forecast points.
|
|
1208
|
+
*/
|
|
1209
|
+
readonly length: number;
|
|
1210
|
+
/**
|
|
1211
|
+
* Get the forecast values.
|
|
1212
|
+
*/
|
|
1213
|
+
readonly values: Float64Array;
|
|
1214
|
+
}
|
|
1215
|
+
|
|
1216
|
+
export class JsPostProcessor {
|
|
1217
|
+
private constructor();
|
|
1218
|
+
free(): void;
|
|
1219
|
+
[Symbol.dispose](): void;
|
|
1220
|
+
/**
|
|
1221
|
+
* Create a historical simulation postprocessor.
|
|
1222
|
+
*
|
|
1223
|
+
* @param quantiles - Sorted quantile levels in (0,1)
|
|
178
1224
|
*/
|
|
179
|
-
|
|
1225
|
+
static historicalSim(quantiles: Float64Array): JsPostProcessor;
|
|
180
1226
|
/**
|
|
181
|
-
*
|
|
1227
|
+
* Generate prediction intervals from a trained model.
|
|
182
1228
|
*
|
|
183
|
-
* @
|
|
1229
|
+
* @param trained - A JsTrainedModel from train()
|
|
1230
|
+
* @param forecasts - New point forecasts
|
|
184
1231
|
*/
|
|
185
|
-
|
|
1232
|
+
predictIntervals(trained: JsTrainedModel, forecasts: JsPointForecasts): JsPredictionIntervals;
|
|
186
1233
|
/**
|
|
187
|
-
*
|
|
1234
|
+
* Train the postprocessor on historical data.
|
|
188
1235
|
*
|
|
189
|
-
* @
|
|
1236
|
+
* @param forecasts - JsPointForecasts with historical predictions
|
|
1237
|
+
* @param actuals - Corresponding actual observed values
|
|
190
1238
|
*/
|
|
191
|
-
|
|
1239
|
+
train(forecasts: JsPointForecasts, actuals: Float64Array): JsTrainedModel;
|
|
192
1240
|
/**
|
|
193
|
-
*
|
|
1241
|
+
* Create a normal prediction postprocessor.
|
|
1242
|
+
*
|
|
1243
|
+
* @param quantiles - Sorted quantile levels in (0,1)
|
|
194
1244
|
*/
|
|
195
|
-
|
|
1245
|
+
static normal(quantiles: Float64Array): JsPostProcessor;
|
|
196
1246
|
/**
|
|
197
|
-
*
|
|
1247
|
+
* Create a conformal prediction postprocessor.
|
|
1248
|
+
*
|
|
1249
|
+
* @param coverage - Target coverage level in (0, 1), e.g. 0.90
|
|
198
1250
|
*/
|
|
199
|
-
|
|
1251
|
+
static conformal(coverage: number): JsPostProcessor;
|
|
200
1252
|
}
|
|
201
1253
|
|
|
202
|
-
export class
|
|
1254
|
+
export class JsPredictionIntervals {
|
|
1255
|
+
private constructor();
|
|
203
1256
|
free(): void;
|
|
204
1257
|
[Symbol.dispose](): void;
|
|
205
|
-
fit(series: TimeSeries): void;
|
|
206
1258
|
/**
|
|
207
|
-
*
|
|
208
|
-
* @param q - ARCH order (lagged squared residuals)
|
|
1259
|
+
* Compute empirical coverage given actual values.
|
|
209
1260
|
*/
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
1261
|
+
empiricalCoverage(actuals: Float64Array): number | undefined;
|
|
1262
|
+
/**
|
|
1263
|
+
* Get the interval widths.
|
|
1264
|
+
*/
|
|
1265
|
+
widths(): Float64Array;
|
|
1266
|
+
/**
|
|
1267
|
+
* Get the interval midpoints.
|
|
1268
|
+
*/
|
|
1269
|
+
midpoints(): Float64Array;
|
|
1270
|
+
/**
|
|
1271
|
+
* Get the lower bounds.
|
|
1272
|
+
*/
|
|
1273
|
+
readonly lower: Float64Array;
|
|
1274
|
+
/**
|
|
1275
|
+
* Get the upper bounds.
|
|
1276
|
+
*/
|
|
1277
|
+
readonly upper: Float64Array;
|
|
1278
|
+
/**
|
|
1279
|
+
* Get the number of intervals.
|
|
1280
|
+
*/
|
|
1281
|
+
readonly length: number;
|
|
1282
|
+
/**
|
|
1283
|
+
* Get the coverage level (e.g. 0.90).
|
|
1284
|
+
*/
|
|
1285
|
+
readonly coverage: number;
|
|
213
1286
|
}
|
|
214
1287
|
|
|
215
|
-
export class
|
|
1288
|
+
export class JsTrainedModel {
|
|
1289
|
+
private constructor();
|
|
216
1290
|
free(): void;
|
|
217
1291
|
[Symbol.dispose](): void;
|
|
218
|
-
fit(series: TimeSeries): void;
|
|
219
|
-
/**
|
|
220
|
-
* @param alpha - Level smoothing parameter (0 < alpha <= 1)
|
|
221
|
-
* @param beta - Trend smoothing parameter (0 < beta <= 1)
|
|
222
|
-
*/
|
|
223
|
-
constructor(alpha: number, beta: number);
|
|
224
|
-
predict(horizon: number): Forecast;
|
|
225
|
-
readonly name: string;
|
|
226
1292
|
}
|
|
227
1293
|
|
|
228
|
-
export class
|
|
1294
|
+
export class KalmanForecaster {
|
|
1295
|
+
private constructor();
|
|
229
1296
|
free(): void;
|
|
230
1297
|
[Symbol.dispose](): void;
|
|
231
1298
|
/**
|
|
232
|
-
* Create
|
|
1299
|
+
* Create a local level (random walk plus noise) model.
|
|
1300
|
+
*
|
|
1301
|
+
* @param obs_noise - Observation noise variance
|
|
1302
|
+
* @param state_noise - State (level) noise variance
|
|
233
1303
|
*/
|
|
234
|
-
static
|
|
235
|
-
fit(series: TimeSeries): void;
|
|
1304
|
+
static localLevel(obs_noise: number, state_noise: number): KalmanForecaster;
|
|
236
1305
|
/**
|
|
237
|
-
* Create
|
|
238
|
-
*
|
|
239
|
-
* @param
|
|
240
|
-
* @param
|
|
241
|
-
* @param
|
|
1306
|
+
* Create a local linear trend model.
|
|
1307
|
+
*
|
|
1308
|
+
* @param obs_noise - Observation noise variance
|
|
1309
|
+
* @param level_noise - Level noise variance
|
|
1310
|
+
* @param trend_noise - Trend noise variance
|
|
242
1311
|
*/
|
|
243
|
-
|
|
1312
|
+
static localLinearTrend(obs_noise: number, level_noise: number, trend_noise: number): KalmanForecaster;
|
|
244
1313
|
/**
|
|
245
|
-
*
|
|
246
|
-
*
|
|
247
|
-
* @param
|
|
1314
|
+
* Predict with prediction intervals.
|
|
1315
|
+
*
|
|
1316
|
+
* @param horizon - Number of steps to forecast
|
|
1317
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
1318
|
+
* @returns Forecast with predictions and intervals
|
|
1319
|
+
*/
|
|
1320
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
1321
|
+
/**
|
|
1322
|
+
* Fit the Kalman filter to a time series.
|
|
1323
|
+
*
|
|
1324
|
+
* @param series - TimeSeries to fit
|
|
248
1325
|
*/
|
|
249
|
-
static auto(period: number, seasonal_type: string): HoltWintersForecaster;
|
|
250
|
-
predict(horizon: number): Forecast;
|
|
251
|
-
readonly name: string;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
export class IMAPAForecaster {
|
|
255
|
-
free(): void;
|
|
256
|
-
[Symbol.dispose](): void;
|
|
257
1326
|
fit(series: TimeSeries): void;
|
|
258
|
-
|
|
1327
|
+
/**
|
|
1328
|
+
* Apply the Kalman smoother (RTS smoother) and return smoothed observations.
|
|
1329
|
+
*
|
|
1330
|
+
* @param series - TimeSeries to smooth
|
|
1331
|
+
* @returns Array of smoothed observation values
|
|
1332
|
+
*/
|
|
1333
|
+
smooth(series: TimeSeries): Float64Array;
|
|
1334
|
+
/**
|
|
1335
|
+
* Predict future values.
|
|
1336
|
+
*
|
|
1337
|
+
* @param horizon - Number of steps to forecast
|
|
1338
|
+
* @returns Forecast with point predictions
|
|
1339
|
+
*/
|
|
259
1340
|
predict(horizon: number): Forecast;
|
|
1341
|
+
/**
|
|
1342
|
+
* Get the model name.
|
|
1343
|
+
*/
|
|
260
1344
|
readonly name: string;
|
|
261
1345
|
}
|
|
262
1346
|
|
|
263
1347
|
export class MFLESForecaster {
|
|
264
1348
|
free(): void;
|
|
265
1349
|
[Symbol.dispose](): void;
|
|
1350
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
266
1351
|
fit(series: TimeSeries): void;
|
|
267
1352
|
/**
|
|
268
1353
|
* @param seasonal_periods - Array of seasonal periods
|
|
@@ -346,6 +1431,7 @@ export class SARIMAForecaster {
|
|
|
346
1431
|
export class SESForecaster {
|
|
347
1432
|
free(): void;
|
|
348
1433
|
[Symbol.dispose](): void;
|
|
1434
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
349
1435
|
fit(series: TimeSeries): void;
|
|
350
1436
|
/**
|
|
351
1437
|
* @param alpha - Smoothing parameter (0 < alpha <= 1)
|
|
@@ -408,18 +1494,58 @@ export class SeasonalWindowAverageForecaster {
|
|
|
408
1494
|
export class TBATSForecaster {
|
|
409
1495
|
free(): void;
|
|
410
1496
|
[Symbol.dispose](): void;
|
|
1497
|
+
/**
|
|
1498
|
+
* Enable Box-Cox transformation.
|
|
1499
|
+
*
|
|
1500
|
+
* @param lambda - Box-Cox parameter (0 = log, 1 = identity)
|
|
1501
|
+
*/
|
|
1502
|
+
setBoxCox(lambda: number): void;
|
|
1503
|
+
/**
|
|
1504
|
+
* Set Fourier K (number of harmonics) for each seasonal period.
|
|
1505
|
+
*
|
|
1506
|
+
* @param k - Array of K values (one per seasonal period)
|
|
1507
|
+
*/
|
|
1508
|
+
setFourierK(k: Uint32Array): void;
|
|
1509
|
+
/**
|
|
1510
|
+
* Enable damped trend.
|
|
1511
|
+
*
|
|
1512
|
+
* @param phi - Damping parameter (typically 0.8-0.99)
|
|
1513
|
+
*/
|
|
1514
|
+
setDampedTrend(phi: number): void;
|
|
1515
|
+
/**
|
|
1516
|
+
* Create a TBATSForecaster with specified seasonal periods.
|
|
1517
|
+
*
|
|
1518
|
+
* @param periods - Array of seasonal periods
|
|
1519
|
+
* @returns A new TBATSForecaster
|
|
1520
|
+
*/
|
|
1521
|
+
static withSeasonalPeriods(periods: Uint32Array): TBATSForecaster;
|
|
1522
|
+
/**
|
|
1523
|
+
* Predict with prediction intervals.
|
|
1524
|
+
*
|
|
1525
|
+
* @param horizon - Number of steps to forecast
|
|
1526
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
1527
|
+
*/
|
|
1528
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
411
1529
|
fit(series: TimeSeries): void;
|
|
412
1530
|
/**
|
|
413
1531
|
* @param seasonal_periods - Array of seasonal periods (e.g., [7, 365] for daily data)
|
|
414
1532
|
*/
|
|
415
1533
|
constructor(seasonal_periods: Uint32Array);
|
|
416
1534
|
predict(horizon: number): Forecast;
|
|
1535
|
+
/**
|
|
1536
|
+
* Set ARMA error orders.
|
|
1537
|
+
*
|
|
1538
|
+
* @param p - AR order
|
|
1539
|
+
* @param q - MA order
|
|
1540
|
+
*/
|
|
1541
|
+
setArma(p: number, q: number): void;
|
|
417
1542
|
readonly name: string;
|
|
418
1543
|
}
|
|
419
1544
|
|
|
420
1545
|
export class TSBForecaster {
|
|
421
1546
|
free(): void;
|
|
422
1547
|
[Symbol.dispose](): void;
|
|
1548
|
+
predictWithIntervals(horizon: number, level: number): Forecast;
|
|
423
1549
|
fit(series: TimeSeries): void;
|
|
424
1550
|
constructor();
|
|
425
1551
|
predict(horizon: number): Forecast;
|
|
@@ -439,6 +1565,23 @@ export class ThetaForecaster {
|
|
|
439
1565
|
export class TimeSeries {
|
|
440
1566
|
free(): void;
|
|
441
1567
|
[Symbol.dispose](): void;
|
|
1568
|
+
/**
|
|
1569
|
+
* Check if calendar annotations are attached.
|
|
1570
|
+
*/
|
|
1571
|
+
hasCalendar(): boolean;
|
|
1572
|
+
/**
|
|
1573
|
+
* Attach calendar annotations (holidays, regressors) to this time series.
|
|
1574
|
+
*
|
|
1575
|
+
* Models that support exogenous variables will automatically use the
|
|
1576
|
+
* calendar annotations during fitting.
|
|
1577
|
+
*
|
|
1578
|
+
* @param calendar - CalendarAnnotations instance
|
|
1579
|
+
*/
|
|
1580
|
+
setCalendar(calendar: CalendarAnnotations): void;
|
|
1581
|
+
/**
|
|
1582
|
+
* Remove calendar annotations from this time series.
|
|
1583
|
+
*/
|
|
1584
|
+
clearCalendar(): void;
|
|
442
1585
|
/**
|
|
443
1586
|
* Create a time series with timestamps.
|
|
444
1587
|
*
|
|
@@ -480,6 +1623,48 @@ export class TimeSeries {
|
|
|
480
1623
|
readonly values: Float64Array;
|
|
481
1624
|
}
|
|
482
1625
|
|
|
1626
|
+
export class VARForecaster {
|
|
1627
|
+
free(): void;
|
|
1628
|
+
[Symbol.dispose](): void;
|
|
1629
|
+
/**
|
|
1630
|
+
* Fit the VAR model to multivariate time series data.
|
|
1631
|
+
*
|
|
1632
|
+
* @param data - Array of Float64Arrays, one per variable. All must have the same length.
|
|
1633
|
+
*/
|
|
1634
|
+
fitMultivariate(data: Array<any>): void;
|
|
1635
|
+
/**
|
|
1636
|
+
* Predict future values for all variables.
|
|
1637
|
+
*
|
|
1638
|
+
* @param horizon - Number of steps to forecast
|
|
1639
|
+
* @returns Array of Float64Arrays, one per variable
|
|
1640
|
+
*/
|
|
1641
|
+
predictMultivariate(horizon: number): Array<any>;
|
|
1642
|
+
/**
|
|
1643
|
+
* Perform a Granger causality test.
|
|
1644
|
+
*
|
|
1645
|
+
* Tests whether variable `cause` Granger-causes variable `effect`.
|
|
1646
|
+
*
|
|
1647
|
+
* @param cause - Index of the potentially causal variable (0-based)
|
|
1648
|
+
* @param effect - Index of the effect variable (0-based)
|
|
1649
|
+
* @returns F-statistic. Higher values indicate stronger evidence of causality.
|
|
1650
|
+
*/
|
|
1651
|
+
grangerCausalityTest(cause: number, effect: number): number;
|
|
1652
|
+
/**
|
|
1653
|
+
* Create a new VAR forecaster with the given lag order.
|
|
1654
|
+
*
|
|
1655
|
+
* @param order - Number of lags (p). Must be at least 1.
|
|
1656
|
+
*/
|
|
1657
|
+
constructor(order: number);
|
|
1658
|
+
/**
|
|
1659
|
+
* Get the model name.
|
|
1660
|
+
*/
|
|
1661
|
+
readonly name: string;
|
|
1662
|
+
/**
|
|
1663
|
+
* Get the lag order.
|
|
1664
|
+
*/
|
|
1665
|
+
readonly order: number;
|
|
1666
|
+
}
|
|
1667
|
+
|
|
483
1668
|
export class WindowAverageForecaster {
|
|
484
1669
|
free(): void;
|
|
485
1670
|
[Symbol.dispose](): void;
|
|
@@ -492,6 +1677,142 @@ export class WindowAverageForecaster {
|
|
|
492
1677
|
readonly name: string;
|
|
493
1678
|
}
|
|
494
1679
|
|
|
1680
|
+
/**
|
|
1681
|
+
* Perform the Augmented Dickey-Fuller (ADF) test for unit root.
|
|
1682
|
+
*
|
|
1683
|
+
* Tests the null hypothesis that the series has a unit root (non-stationary).
|
|
1684
|
+
* Rejection (low p-value, negative statistic below critical values) implies
|
|
1685
|
+
* stationarity.
|
|
1686
|
+
*
|
|
1687
|
+
* @param values - Array of numeric values
|
|
1688
|
+
* @param maxLags - Maximum lags to include (default: (n-1)^(1/3))
|
|
1689
|
+
* @returns Object with `statistic`, `pValue`, `lags`, `isStationary`, and `criticalValues`
|
|
1690
|
+
*/
|
|
1691
|
+
export function adfTest(values: Float64Array, max_lags?: number | null): any;
|
|
1692
|
+
|
|
1693
|
+
/**
|
|
1694
|
+
* Compute the approximate entropy of a time series.
|
|
1695
|
+
*
|
|
1696
|
+
* Measures the complexity/regularity of a time series, including self-matches.
|
|
1697
|
+
*
|
|
1698
|
+
* @param values - Array of numeric values
|
|
1699
|
+
* @param m - Embedding dimension (typically 2)
|
|
1700
|
+
* @param r - Tolerance (typically 0.2 * standard deviation)
|
|
1701
|
+
* @returns Approximate entropy, or NaN if insufficient data
|
|
1702
|
+
*/
|
|
1703
|
+
export function approximateEntropy(values: Float64Array, m: number, r: number): number;
|
|
1704
|
+
|
|
1705
|
+
/**
|
|
1706
|
+
* Compute the autocorrelation of a time series at a specific lag.
|
|
1707
|
+
*
|
|
1708
|
+
* @param values - Array of numeric values
|
|
1709
|
+
* @param lag - Lag value
|
|
1710
|
+
* @returns Autocorrelation coefficient at the given lag
|
|
1711
|
+
*/
|
|
1712
|
+
export function autocorrelation(values: Float64Array, lag: number): number;
|
|
1713
|
+
|
|
1714
|
+
/**
|
|
1715
|
+
* Run a backtest on a postprocessor.
|
|
1716
|
+
*
|
|
1717
|
+
* @param processor - The postprocessor to evaluate
|
|
1718
|
+
* @param forecasts - All historical point forecasts
|
|
1719
|
+
* @param actuals - All historical actual values
|
|
1720
|
+
* @param config - Backtest configuration
|
|
1721
|
+
*/
|
|
1722
|
+
export function backtestPostProcessor(processor: JsPostProcessor, forecasts: JsPointForecasts, actuals: Float64Array, config: JsBacktestConfig): JsBacktestResult;
|
|
1723
|
+
|
|
1724
|
+
/**
|
|
1725
|
+
* Generate a bootstrap forecast with empirical prediction intervals.
|
|
1726
|
+
*
|
|
1727
|
+
* Uses residual bootstrap: resamples fitted residuals, generates synthetic
|
|
1728
|
+
* series, re-fits the model, and collects forecast distributions to
|
|
1729
|
+
* compute confidence intervals.
|
|
1730
|
+
*
|
|
1731
|
+
* @param values - Array of numeric values
|
|
1732
|
+
* @param timestamps - Optional array of timestamps as milliseconds since epoch
|
|
1733
|
+
* @param modelType - Model type: "naive", "ses", "holt", "autoarima", "autoets", "autotheta", "sma5", etc.
|
|
1734
|
+
* @param horizon - Number of steps to forecast
|
|
1735
|
+
* @param level - Confidence level (e.g., 0.95 for 95% intervals)
|
|
1736
|
+
* @param nSamples - Number of bootstrap samples (default: 200)
|
|
1737
|
+
* @returns Object with `point`, `lower`, `upper`, `level`, `nSamples`
|
|
1738
|
+
*/
|
|
1739
|
+
export function bootstrapForecast(values: Float64Array, timestamps: Float64Array | null | undefined, model_type: string, horizon: number, level: number, n_samples?: number | null): any;
|
|
1740
|
+
|
|
1741
|
+
/**
|
|
1742
|
+
* Perform time series cross-validation with expanding window.
|
|
1743
|
+
*
|
|
1744
|
+
* Evaluates a forecasting model using multiple train/test splits where
|
|
1745
|
+
* the training window grows with each fold.
|
|
1746
|
+
*
|
|
1747
|
+
* @param values - Array of numeric values
|
|
1748
|
+
* @param timestamps - Optional array of timestamps as milliseconds since epoch
|
|
1749
|
+
* @param modelType - Model type: "naive", "ses", "holt", "autoarima", "autoets", "autotheta", "sma5", etc.
|
|
1750
|
+
* @param horizon - Forecast horizon for each fold
|
|
1751
|
+
* @param initialWindow - Initial training window size (default: max(10, length/3))
|
|
1752
|
+
* @returns Object with `rmse`, `mae`, `mape`, `smape`, `folds`, `maeStd`, `rmseStd`
|
|
1753
|
+
*/
|
|
1754
|
+
export function crossValidate(values: Float64Array, timestamps: Float64Array | null | undefined, model_type: string, horizon: number, initial_window?: number | null): any;
|
|
1755
|
+
|
|
1756
|
+
/**
|
|
1757
|
+
* Detect changepoints in a time series using the PELT algorithm.
|
|
1758
|
+
*
|
|
1759
|
+
* Returns an object with `changepoints` (indices), `segments` (boundary pairs),
|
|
1760
|
+
* `cost`, `nChangepoints`, and `segmentMeans`.
|
|
1761
|
+
*
|
|
1762
|
+
* @param values - Array of numeric values
|
|
1763
|
+
* @param penalty - Penalty for each changepoint (controls number of changepoints; higher = fewer)
|
|
1764
|
+
* @param costFunction - Cost function: "l1", "l2" (default), "normal", "poisson", "linearTrend", "meanVariance", or "cusum"
|
|
1765
|
+
* @param minSegmentLength - Minimum segment length (default: 2)
|
|
1766
|
+
* @returns Object with changepoint detection results
|
|
1767
|
+
*/
|
|
1768
|
+
export function detectChangepoints(values: Float64Array, penalty: number, cost_function?: string | null, min_segment_length?: number | null): any;
|
|
1769
|
+
|
|
1770
|
+
/**
|
|
1771
|
+
* Detect changepoints using BIC penalty (penalty = log(n)).
|
|
1772
|
+
*
|
|
1773
|
+
* BIC penalty automatically adapts to series length, providing a good
|
|
1774
|
+
* default for most use cases.
|
|
1775
|
+
*
|
|
1776
|
+
* @param values - Array of numeric values
|
|
1777
|
+
* @param costFunction - Cost function (default: "l2")
|
|
1778
|
+
* @returns Object with changepoint detection results
|
|
1779
|
+
*/
|
|
1780
|
+
export function detectChangepointsBic(values: Float64Array, cost_function?: string | null): any;
|
|
1781
|
+
|
|
1782
|
+
/**
|
|
1783
|
+
* Run comprehensive residual diagnostics.
|
|
1784
|
+
*
|
|
1785
|
+
* Combines Ljung-Box (autocorrelation), Durbin-Watson (first-order autocorrelation),
|
|
1786
|
+
* and Jarque-Bera (normality) tests into a single diagnostic report.
|
|
1787
|
+
*
|
|
1788
|
+
* @param residuals - Array of model residuals
|
|
1789
|
+
* @param fittedParams - Number of fitted model parameters (default: 0)
|
|
1790
|
+
* @returns Object with `ljungBox`, `durbinWatson`, `jarqueBera`, `mean`, `variance`, `n`, and `isAdequate`
|
|
1791
|
+
*/
|
|
1792
|
+
export function diagnoseResiduals(residuals: Float64Array, fitted_params?: number | null): any;
|
|
1793
|
+
|
|
1794
|
+
/**
|
|
1795
|
+
* Perform the Durbin-Watson test for first-order autocorrelation.
|
|
1796
|
+
*
|
|
1797
|
+
* The statistic ranges from 0 to 4:
|
|
1798
|
+
* - Near 0: Strong positive autocorrelation
|
|
1799
|
+
* - Near 2: No autocorrelation
|
|
1800
|
+
* - Near 4: Strong negative autocorrelation
|
|
1801
|
+
*
|
|
1802
|
+
* @param residuals - Array of model residuals
|
|
1803
|
+
* @returns Object with `statistic` and `interpretation`
|
|
1804
|
+
*/
|
|
1805
|
+
export function durbinWatson(residuals: Float64Array): any;
|
|
1806
|
+
|
|
1807
|
+
/**
|
|
1808
|
+
* Generate a human-readable explanation of a pipeline result.
|
|
1809
|
+
*
|
|
1810
|
+
* @param result - A JsPipelineResult to explain
|
|
1811
|
+
* @param verbosity - "brief", "normal", or "detailed"
|
|
1812
|
+
* @returns Object with `summary` and `sections`
|
|
1813
|
+
*/
|
|
1814
|
+
export function explainResult(result: JsPipelineResult, verbosity: string): any;
|
|
1815
|
+
|
|
495
1816
|
/**
|
|
496
1817
|
* Initialize the WASM module.
|
|
497
1818
|
*
|
|
@@ -499,6 +1820,144 @@ export class WindowAverageForecaster {
|
|
|
499
1820
|
*/
|
|
500
1821
|
export function init(): void;
|
|
501
1822
|
|
|
1823
|
+
/**
|
|
1824
|
+
* Perform the Jarque-Bera test for normality of residuals.
|
|
1825
|
+
*
|
|
1826
|
+
* Tests the null hypothesis that residuals are normally distributed by
|
|
1827
|
+
* examining skewness and kurtosis. A high statistic (low p-value) suggests
|
|
1828
|
+
* non-normality.
|
|
1829
|
+
*
|
|
1830
|
+
* @param residuals - Array of model residuals
|
|
1831
|
+
* @returns Object with `statistic`, `pValue`, `isNormal`, `skewness`, and `excessKurtosis`
|
|
1832
|
+
*/
|
|
1833
|
+
export function jarqueBera(residuals: Float64Array): any;
|
|
1834
|
+
|
|
1835
|
+
/**
|
|
1836
|
+
* Perform the KPSS test for stationarity.
|
|
1837
|
+
*
|
|
1838
|
+
* Tests the null hypothesis that the series is (level) stationary.
|
|
1839
|
+
* Rejection (high statistic above critical values) implies non-stationarity.
|
|
1840
|
+
*
|
|
1841
|
+
* Note: ADF and KPSS test opposite null hypotheses:
|
|
1842
|
+
* - ADF: H0 = non-stationary, reject = stationary
|
|
1843
|
+
* - KPSS: H0 = stationary, reject = non-stationary
|
|
1844
|
+
*
|
|
1845
|
+
* @param values - Array of numeric values
|
|
1846
|
+
* @param lags - Number of lags for HAC variance (default: 4*(n/100)^0.25)
|
|
1847
|
+
* @returns Object with `statistic`, `pValue`, `lags`, `isStationary`, and `criticalValues`
|
|
1848
|
+
*/
|
|
1849
|
+
export function kpssTest(values: Float64Array, lags?: number | null): any;
|
|
1850
|
+
|
|
1851
|
+
/**
|
|
1852
|
+
* Compute the excess kurtosis (fourth standardized moment) of a time series.
|
|
1853
|
+
*
|
|
1854
|
+
* Measures the "tailedness" of the distribution. A normal distribution has
|
|
1855
|
+
* excess kurtosis of 0.
|
|
1856
|
+
*
|
|
1857
|
+
* @param values - Array of numeric values
|
|
1858
|
+
* @returns Excess kurtosis, or NaN if fewer than 4 values
|
|
1859
|
+
*/
|
|
1860
|
+
export function kurtosis(values: Float64Array): number;
|
|
1861
|
+
|
|
1862
|
+
/**
|
|
1863
|
+
* Perform the Ljung-Box test for autocorrelation in residuals.
|
|
1864
|
+
*
|
|
1865
|
+
* Tests the null hypothesis that residuals are independently distributed
|
|
1866
|
+
* (white noise). A low p-value suggests significant autocorrelation remains.
|
|
1867
|
+
*
|
|
1868
|
+
* @param residuals - Array of model residuals
|
|
1869
|
+
* @param lags - Number of lags to include (default: min(10, n/5))
|
|
1870
|
+
* @param fittedParams - Number of fitted model parameters (for df adjustment, default: 0)
|
|
1871
|
+
* @returns Object with `statistic`, `pValue`, `lags`, `df`, and `isWhiteNoise`
|
|
1872
|
+
*/
|
|
1873
|
+
export function ljungBox(residuals: Float64Array, lags?: number | null, fitted_params?: number | null): any;
|
|
1874
|
+
|
|
1875
|
+
/**
|
|
1876
|
+
* Compute the arithmetic mean of a time series.
|
|
1877
|
+
*
|
|
1878
|
+
* @param values - Array of numeric values
|
|
1879
|
+
* @returns Arithmetic mean, or NaN if empty
|
|
1880
|
+
*/
|
|
1881
|
+
export function mean(values: Float64Array): number;
|
|
1882
|
+
|
|
1883
|
+
/**
|
|
1884
|
+
* Perform MSTL (Multiple Seasonal-Trend decomposition using LOESS).
|
|
1885
|
+
*
|
|
1886
|
+
* Decomposes a time series with multiple seasonal periods into trend,
|
|
1887
|
+
* multiple seasonal components, and remainder.
|
|
1888
|
+
*
|
|
1889
|
+
* @param values - Array of numeric values
|
|
1890
|
+
* @param periods - Array of seasonal periods (e.g., [7, 365] for daily data)
|
|
1891
|
+
* @returns Object with `trend`, `seasonals` (array of arrays), `seasonalPeriods`, `remainder`, and `trendStrength`
|
|
1892
|
+
*/
|
|
1893
|
+
export function mstlDecompose(values: Float64Array, periods: Uint32Array): any;
|
|
1894
|
+
|
|
1895
|
+
/**
|
|
1896
|
+
* Compute the partial autocorrelation of a time series at a specific lag.
|
|
1897
|
+
*
|
|
1898
|
+
* Uses the Durbin-Levinson algorithm.
|
|
1899
|
+
*
|
|
1900
|
+
* @param values - Array of numeric values
|
|
1901
|
+
* @param lag - Lag value (must be >= 1)
|
|
1902
|
+
* @returns Partial autocorrelation coefficient at the given lag
|
|
1903
|
+
*/
|
|
1904
|
+
export function partialAutocorrelation(values: Float64Array, lag: number): number;
|
|
1905
|
+
|
|
1906
|
+
/**
|
|
1907
|
+
* Compute the sample entropy of a time series.
|
|
1908
|
+
*
|
|
1909
|
+
* Measures the complexity/regularity of a time series. Lower values indicate
|
|
1910
|
+
* more regularity. Unlike approximate entropy, excludes self-matches.
|
|
1911
|
+
*
|
|
1912
|
+
* @param values - Array of numeric values
|
|
1913
|
+
* @param m - Embedding dimension (typically 2)
|
|
1914
|
+
* @param r - Tolerance (typically 0.2 * standard deviation)
|
|
1915
|
+
* @returns Sample entropy, or NaN if insufficient data
|
|
1916
|
+
*/
|
|
1917
|
+
export function sampleEntropy(values: Float64Array, m: number, r: number): number;
|
|
1918
|
+
|
|
1919
|
+
/**
|
|
1920
|
+
* Recommend models based on data profile characteristics.
|
|
1921
|
+
*
|
|
1922
|
+
* Returns an object with `recommended` (model names) and `reasoning` (explanations).
|
|
1923
|
+
*
|
|
1924
|
+
* @param profile - A JsDataProfile from profiling
|
|
1925
|
+
* @param availableModels - Optional array of model names to filter by
|
|
1926
|
+
*/
|
|
1927
|
+
export function selectModels(profile: JsDataProfile, available_models?: string[] | null): any;
|
|
1928
|
+
|
|
1929
|
+
/**
|
|
1930
|
+
* Compute the skewness (third standardized moment) of a time series.
|
|
1931
|
+
*
|
|
1932
|
+
* Measures the asymmetry of the distribution.
|
|
1933
|
+
*
|
|
1934
|
+
* @param values - Array of numeric values
|
|
1935
|
+
* @returns Skewness, or NaN if fewer than 3 values
|
|
1936
|
+
*/
|
|
1937
|
+
export function skewness(values: Float64Array): number;
|
|
1938
|
+
|
|
1939
|
+
/**
|
|
1940
|
+
* Perform STL (Seasonal-Trend decomposition using LOESS).
|
|
1941
|
+
*
|
|
1942
|
+
* Decomposes a time series into trend, seasonal, and remainder components.
|
|
1943
|
+
*
|
|
1944
|
+
* @param values - Array of numeric values
|
|
1945
|
+
* @param period - Seasonal period (e.g., 12 for monthly data)
|
|
1946
|
+
* @param robust - Enable robust fitting to reduce outlier influence (default: false)
|
|
1947
|
+
* @returns Object with `trend`, `seasonal`, `remainder`, `seasonalStrength`, and `trendStrength`
|
|
1948
|
+
*/
|
|
1949
|
+
export function stlDecompose(values: Float64Array, period: number, robust?: boolean | null): any;
|
|
1950
|
+
|
|
1951
|
+
/**
|
|
1952
|
+
* Compute the population variance of a time series.
|
|
1953
|
+
*
|
|
1954
|
+
* Uses population formula (n denominator) matching tsfresh.
|
|
1955
|
+
*
|
|
1956
|
+
* @param values - Array of numeric values
|
|
1957
|
+
* @returns Population variance, or NaN if empty
|
|
1958
|
+
*/
|
|
1959
|
+
export function variance(values: Float64Array): number;
|
|
1960
|
+
|
|
502
1961
|
/**
|
|
503
1962
|
* Get the library version.
|
|
504
1963
|
*/
|
|
@@ -511,17 +1970,40 @@ export interface InitOutput {
|
|
|
511
1970
|
readonly __wbg_adidaforecaster_free: (a: number, b: number) => void;
|
|
512
1971
|
readonly __wbg_arimaforecaster_free: (a: number, b: number) => void;
|
|
513
1972
|
readonly __wbg_autoarimaforecaster_free: (a: number, b: number) => void;
|
|
1973
|
+
readonly __wbg_autoensembleforecaster_free: (a: number, b: number) => void;
|
|
514
1974
|
readonly __wbg_autoetsforecaster_free: (a: number, b: number) => void;
|
|
1975
|
+
readonly __wbg_autoforecastbuilder_free: (a: number, b: number) => void;
|
|
1976
|
+
readonly __wbg_autoforecaster_free: (a: number, b: number) => void;
|
|
515
1977
|
readonly __wbg_autotbatsforecaster_free: (a: number, b: number) => void;
|
|
516
1978
|
readonly __wbg_autothetaforecaster_free: (a: number, b: number) => void;
|
|
1979
|
+
readonly __wbg_calendarannotations_free: (a: number, b: number) => void;
|
|
517
1980
|
readonly __wbg_crostonforecaster_free: (a: number, b: number) => void;
|
|
518
1981
|
readonly __wbg_dynamicthetaforecaster_free: (a: number, b: number) => void;
|
|
1982
|
+
readonly __wbg_ensembleforecaster_free: (a: number, b: number) => void;
|
|
519
1983
|
readonly __wbg_etsforecaster_free: (a: number, b: number) => void;
|
|
520
1984
|
readonly __wbg_forecast_free: (a: number, b: number) => void;
|
|
521
1985
|
readonly __wbg_garchforecaster_free: (a: number, b: number) => void;
|
|
522
1986
|
readonly __wbg_holtforecaster_free: (a: number, b: number) => void;
|
|
523
1987
|
readonly __wbg_holtwintersforecaster_free: (a: number, b: number) => void;
|
|
524
1988
|
readonly __wbg_imapaforecaster_free: (a: number, b: number) => void;
|
|
1989
|
+
readonly __wbg_jsbacktestconfig_free: (a: number, b: number) => void;
|
|
1990
|
+
readonly __wbg_jsbacktestresult_free: (a: number, b: number) => void;
|
|
1991
|
+
readonly __wbg_jsconformalpredictor_free: (a: number, b: number) => void;
|
|
1992
|
+
readonly __wbg_jsconformalresult_free: (a: number, b: number) => void;
|
|
1993
|
+
readonly __wbg_jsdataprofile_free: (a: number, b: number) => void;
|
|
1994
|
+
readonly __wbg_jshistoricalsimresult_free: (a: number, b: number) => void;
|
|
1995
|
+
readonly __wbg_jshistoricalsimulator_free: (a: number, b: number) => void;
|
|
1996
|
+
readonly __wbg_jsmodeldiagnostics_free: (a: number, b: number) => void;
|
|
1997
|
+
readonly __wbg_jsnormalpredictor_free: (a: number, b: number) => void;
|
|
1998
|
+
readonly __wbg_jsnormalresult_free: (a: number, b: number) => void;
|
|
1999
|
+
readonly __wbg_jspipelinebuilder_free: (a: number, b: number) => void;
|
|
2000
|
+
readonly __wbg_jspipelinereport_free: (a: number, b: number) => void;
|
|
2001
|
+
readonly __wbg_jspipelineresult_free: (a: number, b: number) => void;
|
|
2002
|
+
readonly __wbg_jspointforecasts_free: (a: number, b: number) => void;
|
|
2003
|
+
readonly __wbg_jspostprocessor_free: (a: number, b: number) => void;
|
|
2004
|
+
readonly __wbg_jspredictionintervals_free: (a: number, b: number) => void;
|
|
2005
|
+
readonly __wbg_jstrainedmodel_free: (a: number, b: number) => void;
|
|
2006
|
+
readonly __wbg_kalmanforecaster_free: (a: number, b: number) => void;
|
|
525
2007
|
readonly __wbg_meanforecaster_free: (a: number, b: number) => void;
|
|
526
2008
|
readonly __wbg_mflesforecaster_free: (a: number, b: number) => void;
|
|
527
2009
|
readonly __wbg_mstlforecasterwrapper_free: (a: number, b: number) => void;
|
|
@@ -537,10 +2019,14 @@ export interface InitOutput {
|
|
|
537
2019
|
readonly __wbg_tbatsforecaster_free: (a: number, b: number) => void;
|
|
538
2020
|
readonly __wbg_thetaforecaster_free: (a: number, b: number) => void;
|
|
539
2021
|
readonly __wbg_timeseries_free: (a: number, b: number) => void;
|
|
2022
|
+
readonly __wbg_varforecaster_free: (a: number, b: number) => void;
|
|
2023
|
+
readonly adfTest: (a: number, b: number, c: number) => [number, number, number];
|
|
540
2024
|
readonly adidaforecaster_fit: (a: number, b: number) => [number, number];
|
|
541
2025
|
readonly adidaforecaster_name: (a: number) => [number, number];
|
|
542
2026
|
readonly adidaforecaster_new: () => number;
|
|
543
2027
|
readonly adidaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2028
|
+
readonly adidaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2029
|
+
readonly approximateEntropy: (a: number, b: number, c: number, d: number) => number;
|
|
544
2030
|
readonly arimaforecaster_fit: (a: number, b: number) => [number, number];
|
|
545
2031
|
readonly arimaforecaster_name: (a: number) => [number, number];
|
|
546
2032
|
readonly arimaforecaster_new: (a: number, b: number, c: number) => number;
|
|
@@ -551,6 +2037,16 @@ export interface InitOutput {
|
|
|
551
2037
|
readonly autoarimaforecaster_new: () => number;
|
|
552
2038
|
readonly autoarimaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
553
2039
|
readonly autoarimaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2040
|
+
readonly autocorrelation: (a: number, b: number, c: number) => number;
|
|
2041
|
+
readonly autoensembleforecaster_allScores: (a: number) => [number, number, number];
|
|
2042
|
+
readonly autoensembleforecaster_fit: (a: number, b: number) => [number, number];
|
|
2043
|
+
readonly autoensembleforecaster_modelCount: (a: number) => number;
|
|
2044
|
+
readonly autoensembleforecaster_name: (a: number) => [number, number];
|
|
2045
|
+
readonly autoensembleforecaster_new: () => number;
|
|
2046
|
+
readonly autoensembleforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2047
|
+
readonly autoensembleforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2048
|
+
readonly autoensembleforecaster_seasonal: (a: number) => number;
|
|
2049
|
+
readonly autoensembleforecaster_withConfig: (a: number, b: number) => number;
|
|
554
2050
|
readonly autoetsforecaster_additiveOnly: () => number;
|
|
555
2051
|
readonly autoetsforecaster_fit: (a: number, b: number) => [number, number];
|
|
556
2052
|
readonly autoetsforecaster_name: (a: number) => [number, number];
|
|
@@ -558,6 +2054,22 @@ export interface InitOutput {
|
|
|
558
2054
|
readonly autoetsforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
559
2055
|
readonly autoetsforecaster_withConfig: (a: number, b: number, c: number, d: number) => number;
|
|
560
2056
|
readonly autoetsforecaster_withPeriod: (a: number) => number;
|
|
2057
|
+
readonly autoforecastbuilder_build: (a: number) => number;
|
|
2058
|
+
readonly autoforecastbuilder_includeArima: (a: number, b: number) => number;
|
|
2059
|
+
readonly autoforecastbuilder_includeEts: (a: number, b: number) => number;
|
|
2060
|
+
readonly autoforecastbuilder_includeTheta: (a: number, b: number) => number;
|
|
2061
|
+
readonly autoforecastbuilder_new: () => number;
|
|
2062
|
+
readonly autoforecastbuilder_seasonalPeriod: (a: number, b: number) => number;
|
|
2063
|
+
readonly autoforecastbuilder_useCrossValidation: (a: number, b: number) => number;
|
|
2064
|
+
readonly autoforecaster_allScores: (a: number) => [number, number, number];
|
|
2065
|
+
readonly autoforecaster_fit: (a: number, b: number) => [number, number];
|
|
2066
|
+
readonly autoforecaster_name: (a: number) => [number, number];
|
|
2067
|
+
readonly autoforecaster_new: () => number;
|
|
2068
|
+
readonly autoforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2069
|
+
readonly autoforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2070
|
+
readonly autoforecaster_seasonal: (a: number) => number;
|
|
2071
|
+
readonly autoforecaster_selectedModelName: (a: number) => [number, number];
|
|
2072
|
+
readonly autoforecaster_withConfig: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
561
2073
|
readonly autotbatsforecaster_fit: (a: number, b: number) => [number, number];
|
|
562
2074
|
readonly autotbatsforecaster_name: (a: number) => [number, number];
|
|
563
2075
|
readonly autotbatsforecaster_new: (a: number, b: number) => number;
|
|
@@ -567,10 +2079,32 @@ export interface InitOutput {
|
|
|
567
2079
|
readonly autothetaforecaster_new: () => number;
|
|
568
2080
|
readonly autothetaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
569
2081
|
readonly autothetaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2082
|
+
readonly backtestPostProcessor: (a: number, b: number, c: number, d: number, e: number) => [number, number, number];
|
|
2083
|
+
readonly bootstrapForecast: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => [number, number, number];
|
|
2084
|
+
readonly calendarannotations_addHoliday: (a: number, b: number) => void;
|
|
2085
|
+
readonly calendarannotations_addRegressor: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
2086
|
+
readonly calendarannotations_fromJSON: (a: number, b: number) => [number, number, number];
|
|
2087
|
+
readonly calendarannotations_getHolidays: (a: number) => [number, number];
|
|
2088
|
+
readonly calendarannotations_getRegressor: (a: number, b: number, c: number) => [number, number];
|
|
2089
|
+
readonly calendarannotations_hasRegressors: (a: number) => number;
|
|
2090
|
+
readonly calendarannotations_holidayCount: (a: number) => number;
|
|
2091
|
+
readonly calendarannotations_isBusinessDay: (a: number, b: number) => number;
|
|
2092
|
+
readonly calendarannotations_isHoliday: (a: number, b: number) => number;
|
|
2093
|
+
readonly calendarannotations_new: () => number;
|
|
2094
|
+
readonly calendarannotations_regressorCount: (a: number) => number;
|
|
2095
|
+
readonly calendarannotations_regressorNames: (a: number) => [number, number, number];
|
|
2096
|
+
readonly calendarannotations_setHolidays: (a: number, b: number, c: number) => void;
|
|
2097
|
+
readonly calendarannotations_toJSON: (a: number) => [number, number, number, number];
|
|
2098
|
+
readonly crossValidate: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => [number, number, number];
|
|
570
2099
|
readonly crostonforecaster_fit: (a: number, b: number) => [number, number];
|
|
571
2100
|
readonly crostonforecaster_name: (a: number) => [number, number];
|
|
572
2101
|
readonly crostonforecaster_new: () => number;
|
|
573
2102
|
readonly crostonforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2103
|
+
readonly crostonforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2104
|
+
readonly detectChangepoints: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
|
|
2105
|
+
readonly detectChangepointsBic: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2106
|
+
readonly diagnoseResiduals: (a: number, b: number, c: number) => [number, number, number];
|
|
2107
|
+
readonly durbinWatson: (a: number, b: number) => [number, number, number];
|
|
574
2108
|
readonly dynamicthetaforecaster_fit: (a: number, b: number) => [number, number];
|
|
575
2109
|
readonly dynamicthetaforecaster_name: (a: number) => [number, number];
|
|
576
2110
|
readonly dynamicthetaforecaster_new: (a: number) => number;
|
|
@@ -578,37 +2112,181 @@ export interface InitOutput {
|
|
|
578
2112
|
readonly dynamicthetaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
579
2113
|
readonly dynamicthetaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
580
2114
|
readonly dynamicthetaforecaster_seasonal: (a: number) => number;
|
|
2115
|
+
readonly ensembleforecaster_fit: (a: number, b: number) => [number, number];
|
|
2116
|
+
readonly ensembleforecaster_modelCount: (a: number) => number;
|
|
2117
|
+
readonly ensembleforecaster_name: (a: number) => [number, number];
|
|
2118
|
+
readonly ensembleforecaster_new: (a: number, b: number) => [number, number, number];
|
|
2119
|
+
readonly ensembleforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2120
|
+
readonly ensembleforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2121
|
+
readonly ensembleforecaster_setHorizonAdaptive: (a: number) => void;
|
|
2122
|
+
readonly ensembleforecaster_setInverseAic: (a: number) => void;
|
|
2123
|
+
readonly ensembleforecaster_setMedian: (a: number) => void;
|
|
2124
|
+
readonly ensembleforecaster_setMethod: (a: number, b: number, c: number) => [number, number];
|
|
2125
|
+
readonly ensembleforecaster_setStacking: (a: number, b: number) => void;
|
|
2126
|
+
readonly ensembleforecaster_setWeightedMse: (a: number) => void;
|
|
2127
|
+
readonly ensembleforecaster_setWeights: (a: number, b: number, c: number) => void;
|
|
581
2128
|
readonly etsforecaster_fit: (a: number, b: number) => [number, number];
|
|
582
2129
|
readonly etsforecaster_fromNotation: (a: number, b: number, c: number) => [number, number, number];
|
|
583
2130
|
readonly etsforecaster_isValidSpec: (a: number, b: number, c: number, d: number, e: number, f: number) => number;
|
|
584
2131
|
readonly etsforecaster_name: (a: number) => [number, number];
|
|
585
2132
|
readonly etsforecaster_new: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => [number, number, number];
|
|
586
2133
|
readonly etsforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2134
|
+
readonly explainResult: (a: number, b: number, c: number) => [number, number, number];
|
|
2135
|
+
readonly forecast_clamp: (a: number, b: number, c: number) => number;
|
|
587
2136
|
readonly forecast_hasLower: (a: number) => number;
|
|
588
2137
|
readonly forecast_hasUpper: (a: number) => number;
|
|
589
2138
|
readonly forecast_horizon: (a: number) => number;
|
|
590
2139
|
readonly forecast_lower: (a: number) => [number, number];
|
|
2140
|
+
readonly forecast_nonNegative: (a: number) => number;
|
|
2141
|
+
readonly forecast_roundToInteger: (a: number) => number;
|
|
591
2142
|
readonly forecast_upper: (a: number) => [number, number];
|
|
592
2143
|
readonly forecast_values: (a: number) => [number, number];
|
|
593
2144
|
readonly garchforecaster_fit: (a: number, b: number) => [number, number];
|
|
594
2145
|
readonly garchforecaster_name: (a: number) => [number, number];
|
|
595
2146
|
readonly garchforecaster_new: (a: number, b: number) => number;
|
|
596
2147
|
readonly garchforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2148
|
+
readonly garchforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
597
2149
|
readonly holtforecaster_fit: (a: number, b: number) => [number, number];
|
|
598
2150
|
readonly holtforecaster_name: (a: number) => [number, number];
|
|
599
2151
|
readonly holtforecaster_new: (a: number, b: number) => number;
|
|
600
2152
|
readonly holtforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2153
|
+
readonly holtforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
601
2154
|
readonly holtwintersforecaster_auto: (a: number, b: number, c: number) => [number, number, number];
|
|
602
2155
|
readonly holtwintersforecaster_fit: (a: number, b: number) => [number, number];
|
|
603
2156
|
readonly holtwintersforecaster_multiplicative: (a: number, b: number, c: number, d: number) => number;
|
|
604
2157
|
readonly holtwintersforecaster_name: (a: number) => [number, number];
|
|
605
2158
|
readonly holtwintersforecaster_new: (a: number, b: number, c: number, d: number) => number;
|
|
606
2159
|
readonly holtwintersforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2160
|
+
readonly holtwintersforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
607
2161
|
readonly imapaforecaster_fit: (a: number, b: number) => [number, number];
|
|
608
2162
|
readonly imapaforecaster_name: (a: number) => [number, number];
|
|
609
2163
|
readonly imapaforecaster_new: () => number;
|
|
610
2164
|
readonly imapaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2165
|
+
readonly imapaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
611
2166
|
readonly init: () => void;
|
|
2167
|
+
readonly jarqueBera: (a: number, b: number) => [number, number, number];
|
|
2168
|
+
readonly jsbacktestconfig_expanding: (a: number, b: number) => number;
|
|
2169
|
+
readonly jsbacktestconfig_horizon: (a: number, b: number) => number;
|
|
2170
|
+
readonly jsbacktestconfig_initialWindow: (a: number, b: number) => number;
|
|
2171
|
+
readonly jsbacktestconfig_new: () => number;
|
|
2172
|
+
readonly jsbacktestconfig_step: (a: number, b: number) => number;
|
|
2173
|
+
readonly jsbacktestresult_calibrationError: (a: number, b: number) => number;
|
|
2174
|
+
readonly jsbacktestresult_coverage: (a: number) => number;
|
|
2175
|
+
readonly jsbacktestresult_intervalWidths: (a: number) => number;
|
|
2176
|
+
readonly jsbacktestresult_numFolds: (a: number) => number;
|
|
2177
|
+
readonly jsconformalpredictor_calibrate: (a: number, b: number, c: number, d: number, e: number) => [number, number, number];
|
|
2178
|
+
readonly jsconformalpredictor_crossVal: (a: number, b: number) => number;
|
|
2179
|
+
readonly jsconformalpredictor_jackknifePlus: (a: number) => number;
|
|
2180
|
+
readonly jsconformalpredictor_new: (a: number) => number;
|
|
2181
|
+
readonly jsconformalpredictor_predictIntervals: (a: number, b: number, c: number, d: number) => number;
|
|
2182
|
+
readonly jsconformalresult_coverage: (a: number) => number;
|
|
2183
|
+
readonly jsconformalresult_quantileValue: (a: number) => number;
|
|
2184
|
+
readonly jsconformalresult_scores: (a: number) => [number, number];
|
|
2185
|
+
readonly jsdataprofile_acfLag1: (a: number) => number;
|
|
2186
|
+
readonly jsdataprofile_acfLag2: (a: number) => number;
|
|
2187
|
+
readonly jsdataprofile_adfIsStationary: (a: number) => number;
|
|
2188
|
+
readonly jsdataprofile_adfPValue: (a: number) => number;
|
|
2189
|
+
readonly jsdataprofile_adfStatistic: (a: number) => number;
|
|
2190
|
+
readonly jsdataprofile_approximateEntropy: (a: number) => [number, number];
|
|
2191
|
+
readonly jsdataprofile_fromSeries: (a: number) => number;
|
|
2192
|
+
readonly jsdataprofile_fromValues: (a: number, b: number) => number;
|
|
2193
|
+
readonly jsdataprofile_hasNegatives: (a: number) => number;
|
|
2194
|
+
readonly jsdataprofile_isInteger: (a: number) => number;
|
|
2195
|
+
readonly jsdataprofile_isIntermittent: (a: number) => number;
|
|
2196
|
+
readonly jsdataprofile_isStationary: (a: number) => number;
|
|
2197
|
+
readonly jsdataprofile_kpssIsStationary: (a: number) => number;
|
|
2198
|
+
readonly jsdataprofile_kpssPValue: (a: number) => number;
|
|
2199
|
+
readonly jsdataprofile_kpssStatistic: (a: number) => number;
|
|
2200
|
+
readonly jsdataprofile_kurtosis: (a: number) => number;
|
|
2201
|
+
readonly jsdataprofile_lempelZiv: (a: number) => number;
|
|
2202
|
+
readonly jsdataprofile_max: (a: number) => number;
|
|
2203
|
+
readonly jsdataprofile_min: (a: number) => number;
|
|
2204
|
+
readonly jsdataprofile_missingCount: (a: number) => number;
|
|
2205
|
+
readonly jsdataprofile_nObservations: (a: number) => number;
|
|
2206
|
+
readonly jsdataprofile_partialAcfLag1: (a: number) => number;
|
|
2207
|
+
readonly jsdataprofile_qualityScore: (a: number) => number;
|
|
2208
|
+
readonly jsdataprofile_skewness: (a: number) => number;
|
|
2209
|
+
readonly jsdataprofile_summary: (a: number) => [number, number];
|
|
2210
|
+
readonly jsdataprofile_toJSON: (a: number) => [number, number, number];
|
|
2211
|
+
readonly jsdataprofile_toString: (a: number) => [number, number];
|
|
2212
|
+
readonly jsdataprofile_trendDirection: (a: number) => [number, number];
|
|
2213
|
+
readonly jsdataprofile_trendSlope: (a: number) => number;
|
|
2214
|
+
readonly jsdataprofile_trendStrength: (a: number) => number;
|
|
2215
|
+
readonly jsdataprofile_zeroFraction: (a: number) => number;
|
|
2216
|
+
readonly jshistoricalsimresult_errors: (a: number) => [number, number];
|
|
2217
|
+
readonly jshistoricalsimresult_quantileValues: (a: number) => [number, number];
|
|
2218
|
+
readonly jshistoricalsimulator_new: (a: number, b: number) => number;
|
|
2219
|
+
readonly jshistoricalsimulator_predictIntervals: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2220
|
+
readonly jshistoricalsimulator_simulate: (a: number, b: number, c: number, d: number, e: number) => [number, number, number];
|
|
2221
|
+
readonly jshistoricalsimulator_withWindow: (a: number, b: number, c: number) => number;
|
|
2222
|
+
readonly jsmodeldiagnostics_fromResiduals: (a: number, b: number, c: number) => number;
|
|
2223
|
+
readonly jsmodeldiagnostics_jarqueBeraStatistic: (a: number) => number;
|
|
2224
|
+
readonly jsmodeldiagnostics_ljungBoxLags: (a: number) => number;
|
|
2225
|
+
readonly jsmodeldiagnostics_ljungBoxPvalue: (a: number) => number;
|
|
2226
|
+
readonly jsmodeldiagnostics_passesAll: (a: number) => number;
|
|
2227
|
+
readonly jsmodeldiagnostics_residualAcf: (a: number) => [number, number];
|
|
2228
|
+
readonly jsmodeldiagnostics_residualPacf: (a: number) => [number, number];
|
|
2229
|
+
readonly jsmodeldiagnostics_summary: (a: number) => [number, number];
|
|
2230
|
+
readonly jsnormalpredictor_fit: (a: number, b: number, c: number, d: number, e: number) => [number, number, number];
|
|
2231
|
+
readonly jsnormalpredictor_new: (a: number, b: number) => number;
|
|
2232
|
+
readonly jsnormalpredictor_predictIntervals: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2233
|
+
readonly jspipelinebuilder_addModel: (a: number, b: number, c: number) => number;
|
|
2234
|
+
readonly jspipelinebuilder_addSeasonalModel: (a: number, b: number, c: number, d: number) => number;
|
|
2235
|
+
readonly jspipelinebuilder_crossValidate: (a: number, b: number, c: number) => number;
|
|
2236
|
+
readonly jspipelinebuilder_ensemble: (a: number, b: number, c: number) => number;
|
|
2237
|
+
readonly jspipelinebuilder_execute: (a: number, b: number, c: number) => [number, number, number];
|
|
2238
|
+
readonly jspipelinebuilder_metric: (a: number, b: number, c: number) => number;
|
|
2239
|
+
readonly jspipelinebuilder_new: () => number;
|
|
2240
|
+
readonly jspipelinebuilder_nonNegative: (a: number) => number;
|
|
2241
|
+
readonly jspipelinebuilder_preprocess: (a: number, b: number, c: number) => number;
|
|
2242
|
+
readonly jspipelinebuilder_profile: (a: number) => number;
|
|
2243
|
+
readonly jspipelinebuilder_seasonalPeriod: (a: number, b: number) => number;
|
|
2244
|
+
readonly jspipelinebuilder_selectModels: (a: number, b: number) => number;
|
|
2245
|
+
readonly jspipelinebuilder_withFallback: (a: number) => number;
|
|
2246
|
+
readonly jspipelinereport_sectionCount: (a: number) => number;
|
|
2247
|
+
readonly jspipelinereport_sectionHeading: (a: number, b: number) => [number, number];
|
|
2248
|
+
readonly jspipelinereport_title: (a: number) => [number, number];
|
|
2249
|
+
readonly jspipelinereport_toJSON: (a: number) => [number, number, number];
|
|
2250
|
+
readonly jspipelinereport_toString: (a: number) => [number, number];
|
|
2251
|
+
readonly jspipelineresult_decisionCount: (a: number) => number;
|
|
2252
|
+
readonly jspipelineresult_decisionLog: (a: number) => [number, number];
|
|
2253
|
+
readonly jspipelineresult_ensembleWeights: (a: number) => [number, number, number];
|
|
2254
|
+
readonly jspipelineresult_forecast: (a: number) => number;
|
|
2255
|
+
readonly jspipelineresult_metricScores: (a: number) => [number, number, number];
|
|
2256
|
+
readonly jspipelineresult_modelConfidenceSet: (a: number) => [number, number, number];
|
|
2257
|
+
readonly jspipelineresult_modelName: (a: number) => [number, number];
|
|
2258
|
+
readonly jspipelineresult_preprocessInfo: (a: number) => [number, number, number];
|
|
2259
|
+
readonly jspipelineresult_profile: (a: number) => number;
|
|
2260
|
+
readonly jspipelineresult_qualityFloor: (a: number) => [number, number];
|
|
2261
|
+
readonly jspipelineresult_report: (a: number) => number;
|
|
2262
|
+
readonly jspipelineresult_selectionConfidence: (a: number) => [number, number];
|
|
2263
|
+
readonly jspipelineresult_toString: (a: number) => [number, number];
|
|
2264
|
+
readonly jspointforecasts_isEmpty: (a: number) => number;
|
|
2265
|
+
readonly jspointforecasts_length: (a: number) => number;
|
|
2266
|
+
readonly jspointforecasts_new: (a: number, b: number) => number;
|
|
2267
|
+
readonly jspointforecasts_values: (a: number) => [number, number];
|
|
2268
|
+
readonly jspostprocessor_conformal: (a: number) => number;
|
|
2269
|
+
readonly jspostprocessor_historicalSim: (a: number, b: number) => number;
|
|
2270
|
+
readonly jspostprocessor_normal: (a: number, b: number) => number;
|
|
2271
|
+
readonly jspostprocessor_predictIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2272
|
+
readonly jspostprocessor_train: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2273
|
+
readonly jspredictionintervals_empiricalCoverage: (a: number, b: number, c: number) => [number, number];
|
|
2274
|
+
readonly jspredictionintervals_length: (a: number) => number;
|
|
2275
|
+
readonly jspredictionintervals_lower: (a: number) => [number, number];
|
|
2276
|
+
readonly jspredictionintervals_midpoints: (a: number) => [number, number];
|
|
2277
|
+
readonly jspredictionintervals_upper: (a: number) => [number, number];
|
|
2278
|
+
readonly jspredictionintervals_widths: (a: number) => [number, number];
|
|
2279
|
+
readonly kalmanforecaster_fit: (a: number, b: number) => [number, number];
|
|
2280
|
+
readonly kalmanforecaster_localLevel: (a: number, b: number) => number;
|
|
2281
|
+
readonly kalmanforecaster_localLinearTrend: (a: number, b: number, c: number) => number;
|
|
2282
|
+
readonly kalmanforecaster_name: (a: number) => [number, number];
|
|
2283
|
+
readonly kalmanforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2284
|
+
readonly kalmanforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2285
|
+
readonly kalmanforecaster_smooth: (a: number, b: number) => [number, number, number, number];
|
|
2286
|
+
readonly kpssTest: (a: number, b: number, c: number) => [number, number, number];
|
|
2287
|
+
readonly kurtosis: (a: number, b: number) => number;
|
|
2288
|
+
readonly ljungBox: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2289
|
+
readonly mean: (a: number, b: number) => number;
|
|
612
2290
|
readonly meanforecaster_fit: (a: number, b: number) => [number, number];
|
|
613
2291
|
readonly meanforecaster_name: (a: number) => [number, number];
|
|
614
2292
|
readonly meanforecaster_new: () => number;
|
|
@@ -618,6 +2296,8 @@ export interface InitOutput {
|
|
|
618
2296
|
readonly mflesforecaster_name: (a: number) => [number, number];
|
|
619
2297
|
readonly mflesforecaster_new: (a: number, b: number) => number;
|
|
620
2298
|
readonly mflesforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2299
|
+
readonly mflesforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2300
|
+
readonly mstlDecompose: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
621
2301
|
readonly mstlforecasterwrapper_fit: (a: number, b: number) => [number, number];
|
|
622
2302
|
readonly mstlforecasterwrapper_name: (a: number) => [number, number];
|
|
623
2303
|
readonly mstlforecasterwrapper_new: (a: number, b: number) => number;
|
|
@@ -632,11 +2312,13 @@ export interface InitOutput {
|
|
|
632
2312
|
readonly optimizedthetaforecaster_new: () => number;
|
|
633
2313
|
readonly optimizedthetaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
634
2314
|
readonly optimizedthetaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2315
|
+
readonly partialAutocorrelation: (a: number, b: number, c: number) => number;
|
|
635
2316
|
readonly randomwalkdriftforecaster_fit: (a: number, b: number) => [number, number];
|
|
636
2317
|
readonly randomwalkdriftforecaster_name: (a: number) => [number, number];
|
|
637
2318
|
readonly randomwalkdriftforecaster_new: () => number;
|
|
638
2319
|
readonly randomwalkdriftforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
639
2320
|
readonly randomwalkdriftforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2321
|
+
readonly sampleEntropy: (a: number, b: number, c: number, d: number) => number;
|
|
640
2322
|
readonly sarimaforecaster_fit: (a: number, b: number) => [number, number];
|
|
641
2323
|
readonly sarimaforecaster_name: (a: number) => [number, number];
|
|
642
2324
|
readonly sarimaforecaster_new: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number;
|
|
@@ -655,27 +2337,39 @@ export interface InitOutput {
|
|
|
655
2337
|
readonly seasonalwindowaverageforecaster_name: (a: number) => [number, number];
|
|
656
2338
|
readonly seasonalwindowaverageforecaster_new: (a: number, b: number) => number;
|
|
657
2339
|
readonly seasonalwindowaverageforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2340
|
+
readonly selectModels: (a: number, b: number, c: number) => [number, number, number];
|
|
658
2341
|
readonly sesforecaster_fit: (a: number, b: number) => [number, number];
|
|
659
2342
|
readonly sesforecaster_name: (a: number) => [number, number];
|
|
660
2343
|
readonly sesforecaster_new: (a: number) => number;
|
|
661
2344
|
readonly sesforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2345
|
+
readonly sesforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2346
|
+
readonly skewness: (a: number, b: number) => number;
|
|
662
2347
|
readonly smaforecaster_fit: (a: number, b: number) => [number, number];
|
|
663
2348
|
readonly smaforecaster_name: (a: number) => [number, number];
|
|
664
2349
|
readonly smaforecaster_new: (a: number) => number;
|
|
665
2350
|
readonly smaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2351
|
+
readonly stlDecompose: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
666
2352
|
readonly tbatsforecaster_fit: (a: number, b: number) => [number, number];
|
|
667
2353
|
readonly tbatsforecaster_name: (a: number) => [number, number];
|
|
668
2354
|
readonly tbatsforecaster_new: (a: number, b: number) => number;
|
|
669
2355
|
readonly tbatsforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2356
|
+
readonly tbatsforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2357
|
+
readonly tbatsforecaster_setArma: (a: number, b: number, c: number) => void;
|
|
2358
|
+
readonly tbatsforecaster_setBoxCox: (a: number, b: number) => void;
|
|
2359
|
+
readonly tbatsforecaster_setDampedTrend: (a: number, b: number) => void;
|
|
2360
|
+
readonly tbatsforecaster_setFourierK: (a: number, b: number, c: number) => void;
|
|
670
2361
|
readonly thetaforecaster_fit: (a: number, b: number) => [number, number];
|
|
671
2362
|
readonly thetaforecaster_name: (a: number) => [number, number];
|
|
672
2363
|
readonly thetaforecaster_new: () => number;
|
|
673
2364
|
readonly thetaforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
674
2365
|
readonly thetaforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2366
|
+
readonly timeseries_clearCalendar: (a: number) => void;
|
|
2367
|
+
readonly timeseries_hasCalendar: (a: number) => number;
|
|
675
2368
|
readonly timeseries_hasMissingValues: (a: number) => number;
|
|
676
2369
|
readonly timeseries_isEmpty: (a: number) => number;
|
|
677
2370
|
readonly timeseries_length: (a: number) => number;
|
|
678
2371
|
readonly timeseries_new: (a: number, b: number) => [number, number, number];
|
|
2372
|
+
readonly timeseries_setCalendar: (a: number, b: number) => void;
|
|
679
2373
|
readonly timeseries_slice: (a: number, b: number, c: number) => [number, number, number];
|
|
680
2374
|
readonly timeseries_values: (a: number) => [number, number];
|
|
681
2375
|
readonly timeseries_withTimestamps: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
@@ -683,16 +2377,36 @@ export interface InitOutput {
|
|
|
683
2377
|
readonly tsbforecaster_name: (a: number) => [number, number];
|
|
684
2378
|
readonly tsbforecaster_new: () => number;
|
|
685
2379
|
readonly tsbforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2380
|
+
readonly tsbforecaster_predictWithIntervals: (a: number, b: number, c: number) => [number, number, number];
|
|
2381
|
+
readonly varforecaster_fitMultivariate: (a: number, b: any) => [number, number];
|
|
2382
|
+
readonly varforecaster_grangerCausalityTest: (a: number, b: number, c: number) => [number, number, number];
|
|
2383
|
+
readonly varforecaster_name: (a: number) => [number, number];
|
|
2384
|
+
readonly varforecaster_new: (a: number) => number;
|
|
2385
|
+
readonly varforecaster_order: (a: number) => number;
|
|
2386
|
+
readonly varforecaster_predictMultivariate: (a: number, b: number) => [number, number, number];
|
|
2387
|
+
readonly variance: (a: number, b: number) => number;
|
|
686
2388
|
readonly version: () => [number, number];
|
|
687
2389
|
readonly windowaverageforecaster_fit: (a: number, b: number) => [number, number];
|
|
688
2390
|
readonly windowaverageforecaster_name: (a: number) => [number, number];
|
|
689
2391
|
readonly windowaverageforecaster_new: (a: number) => number;
|
|
690
2392
|
readonly windowaverageforecaster_predict: (a: number, b: number) => [number, number, number];
|
|
2393
|
+
readonly tbatsforecaster_withSeasonalPeriods: (a: number, b: number) => number;
|
|
691
2394
|
readonly __wbg_tsbforecaster_free: (a: number, b: number) => void;
|
|
692
2395
|
readonly __wbg_windowaverageforecaster_free: (a: number, b: number) => void;
|
|
693
|
-
readonly
|
|
2396
|
+
readonly jsdataprofile_mean: (a: number) => number;
|
|
2397
|
+
readonly jsdataprofile_stdDev: (a: number) => number;
|
|
2398
|
+
readonly jsmodeldiagnostics_heteroscedasticityPvalue: (a: number) => number;
|
|
2399
|
+
readonly jsmodeldiagnostics_jarqueBeraPvalue: (a: number) => number;
|
|
2400
|
+
readonly jsmodeldiagnostics_residualMean: (a: number) => number;
|
|
2401
|
+
readonly jsmodeldiagnostics_residualStd: (a: number) => number;
|
|
2402
|
+
readonly jsnormalresult_mean: (a: number) => number;
|
|
2403
|
+
readonly jsnormalresult_stdDev: (a: number) => number;
|
|
2404
|
+
readonly jspredictionintervals_coverage: (a: number) => number;
|
|
694
2405
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
695
2406
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
2407
|
+
readonly __wbindgen_exn_store: (a: number) => void;
|
|
2408
|
+
readonly __externref_table_alloc: () => number;
|
|
2409
|
+
readonly __wbindgen_externrefs: WebAssembly.Table;
|
|
696
2410
|
readonly __externref_table_dealloc: (a: number) => void;
|
|
697
2411
|
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
698
2412
|
readonly __wbindgen_start: () => void;
|