ohlcv-indicators 3.5.44 → 3.5.45

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ohlcv-indicators",
3
- "version": "3.5.44",
3
+ "version": "3.5.45",
4
4
  "description": "A JavaScript library featuring optimized trading indicators for OHLCV arrays [{open, high, low, close, value}]. This library is optimized for backtesting and trading bot development.",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -6,7 +6,7 @@ export const rsi = (main, index, size, { target, lag, parser, prefix, minmax })
6
6
 
7
7
 
8
8
 
9
- const { verticalOhlcv, instances } = main;
9
+ const { verticalOhlcv, instances, notNumberKeys } = main;
10
10
 
11
11
  const suffix = target === defaultTarget ? '' : `_${target}`;
12
12
  const rsiKey = `${prefix}rsi_${size}${suffix}`;
@@ -53,6 +53,7 @@ export const rsi = (main, index, size, { target, lag, parser, prefix, minmax })
53
53
  for(const key of keyNames)
54
54
  {
55
55
  arrayTypes[key] = 'Float64Array'
56
+ notNumberKeys.add(key)
56
57
  }
57
58
 
58
59
  }
@@ -5,7 +5,7 @@ export const stochastic = (main, index, kPeriod, kSlowingPeriod, dPeriod, {minma
5
5
 
6
6
 
7
7
 
8
- const { verticalOhlcv, instances, scaledGroups } = main;
8
+ const { verticalOhlcv, instances, notNumberKeys } = main;
9
9
 
10
10
  const paramsKey = (kPeriod === 14 && kSlowingPeriod === 3 && dPeriod === 3) ? '' : `${kPeriod}_${kSlowingPeriod}_${dPeriod}`
11
11
  const stochD = `${prefix}stoch_d${paramsKey}`;
@@ -48,6 +48,7 @@ export const stochastic = (main, index, kPeriod, kSlowingPeriod, dPeriod, {minma
48
48
  for(const key of keyNames)
49
49
  {
50
50
  arrayTypes[key] = 'Float64Array'
51
+ notNumberKeys.add(key)
51
52
  }
52
53
  }
53
54