File tree 1 file changed +2
-3
lines changed
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -107,14 +107,13 @@ def _mav_validator(mav_value):
107
107
Value for mav (moving average) keyword may be:
108
108
scalar int greater than 1, or tuple of ints, or list of ints (each greater than 1)
109
109
or a dict of `period` and `shift` each of which may be:
110
- scalar int, or tuple of ints, or list of ints. `period` must be greater than 1
111
- while `shift` must be greater than 0.
110
+ scalar int, or tuple of ints, or list of ints: each `period` int must be greater than 1
112
111
'''
113
112
def _valid_mav (value , is_period = True ):
114
113
if not isinstance (value ,(tuple ,list ,int )):
115
114
return False
116
115
if isinstance (value ,int ):
117
- return isinstance ( value , int ) and (value >= 2 or not is_period )
116
+ return (value >= 2 or not is_period )
118
117
# Must be a tuple or list here:
119
118
for num in value :
120
119
if not isinstance (num ,int ) or (is_period and num < 2 ):
You can’t perform that action at this time.
0 commit comments