We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0862ca1 commit c406cacCopy full SHA for c406cac
pyindicators/indicators/williams_percent_range.py
@@ -30,9 +30,9 @@ def willr(
30
.rolling(window=period, min_periods=1).min()
31
32
data[result_column] = (
33
- (data["high_n"] - data[close_column]) /
34
- (data["high_n"] - data["low_n"])
35
- ) * -100
+ (data["high_n"].squeeze() - data[close_column].squeeze()) /
+ (data["high_n"].squeeze() - data["low_n"].squeeze())
+ ).squeeze() * -100
36
37
# Set the first `period` rows to 0 using .iloc
38
if not data.empty:
0 commit comments