时序数据分析 — 趋势预测
分析时间序列数据:趋势检测、周期性分析、异常点识别、简单预测。适用于监控数据和业务指标。
Wat ===
Simple library for doing time series analysis in Node.js. Much of the functionality has been closed from the time series module in Ruby's statsample library: https://github.com/clbustos/statsample
Install =======
Easy:
npm install time-series
Usage =====
Simple statistics:
ts = new TimeSeries([1, 2, 3, 4]);
ts.mean(); // => gives 2.5 ts.sd(); // => gives around 1.291 ts.var(); // => gives around 1.667
Moving averages:
ts = new TimeSeries(_.range(30));
// Default MA length is 10, gives 9 null observations at the start ts.ma(); // => [null, ..., null, 4.5, 5.5, 6.5, ..., 23.5, 24.5]
// Different MA length ts.ma(5); // => [null, ..., null, 2, 3, 4, 5, ...]
Exponential moving averages:
ts = new TimeSeries(_.range(30));
ts.ema(); // => [null, ..., null, 5.5, 6.5, 7.5, ...] ts.ema(5); // => [null, ..., null, 3, 4, 5, 6, ...]
Licence =======
MIT
安装
# 安装到当前项目
npx skills add time-series
# 全局安装
npx skills add time-series -g
来源
- 作者:
Rob Britton - 仓库:https://github.com/robbrit/node-time-series
- npm 包:
time-series
安装指南
复制下方命令,在终端运行即可安装:
需已安装 GenHub 桌面端
使用指南
安装完成后,在对话框中直接使用此技能。
评论已关闭。