Skip to content

Instantly share code, notes, and snippets.

@sivaraj-v
Created May 28, 2019 11:41
Show Gist options
  • Save sivaraj-v/08d5a74eeb2b46e2659b8d1d35694fcc to your computer and use it in GitHub Desktop.
Save sivaraj-v/08d5a74eeb2b46e2659b8d1d35694fcc to your computer and use it in GitHub Desktop.
ATR-Calculation-Code
const SampleData = require('SampleData);
const { Indicator } = require('../../study/index');
const { ATR } = require('../../study/ATR');
const newStudyATR = new Indicator(new ATR());
console.log(newStudyATR.calculate(ATR_DATA));
Output
 [ …
 TrueRange: 26.75, 
 SumTrueRange: 125.5999999999998,
 Value: 19.44443831563074
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment