New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

series-processing

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

series-processing

Time-series processing for forex, market analysis, including MA, EMA,...

latest
Source
npmnpm
Version
0.1.14
Version published
Maintainers
1
Created
Source

series-processing

Time-series processing for forex, market analysis, including SMA, EMA, MACD...

Install

NPM

npm intall --save series-processing

yarn add series-processing

Example

More examples

Simple with studyBuilder

const { TimeSeries, studyBuilder } = require('../lib');

const series = new TimeSeries();
series.map(studyBuilder.EMA('ema1', 'close', 2));

series.initData(data); // data: Array of candle object

console.log(series.getDataSeries()); // Print result: Array of transformed candle object

More studyBuilder can found here

Multiple studies with same series

const series = new TimeSeries();
series.map(studyBuilder.EMA('ema1', 'close', 2));
series.map(studyBuilder.SMA('sma1', 'open', 4));
series.map(studyBuilder.EMA('ema2', 'sma1', 5));

OR with array

const series = new TimeSeries();
series.map([
  studyBuilder.EMA('ema1', 'close', 2),
  studyBuilder.SMA('sma1', 'open', 4),
  studyBuilder.EMA('ema2', 'sma1', 5)
]);

Custom study

const series = new TimeSeries();
series.map((lastPoint) => {
  return { 'avg' : (lastPoint['open'] + lastPoint['close']) / 2 }
});

API Reference

API docs is coming soon.

License

MIT License.

Keywords

processing

FAQs

Package last updated on 29 Jun 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts