ta
ta copied to clipboard
Fix division by zero in ADX calculation
Fix "RuntimeWarning: invalid value encountered in double_scalars" in lines 608 and 612
This didnt solve my problem getting NaN as a whole series occasionally. I'm testing a change I made, where every time we do a .shift(1), I set the first element from NaN to 0.0. for example:
trend.py:566 cs = self._close.shift(1) cs[0] = 0.0
and also on dn and up, that seems to have solved my issue.