@strong-roots-capital/ichimoku-moving-average
v2.0.1
Published
Average of high and low over a lookback period
Downloads
6
Readme
ichimoku-moving-average
Average of high and low over a lookback period
Install
npm install @strong-roots-capital/ichimoku-moving-average
Use
import IchimokuMovingAverage from '@strong-roots-capital/ichimoku-moving-average'
const tenkan = new IchimokuMovingAverage(9)
const kijun = new IchimokuMovingAverage(26)
for (const value of getValues()) {
tenkan.push(value)
kijun.push(value)
console.log(tenkan.value() > kijun.value() ? 'uptrend' : 'downtrend')
}