We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Passing a series (empty) to is same. Need work around
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) <ipython-input-39-6176c7133a7e> in <module> 1 eorm_vel = c_rolling(c_rolling(eorm17.vel,'6H',min_periods=100)['2017-8-5':'2017-8-20'],'6H').dropna() 2 ----> 3 eorm17_diurnal = DiurnalExtrema(eorm_vel,generate_figure=True) ~/WorkingDir/GrIS/X_PYTHON-CODES/datatools/diurnal.py in __init__(self, timeseries, minfirst, maxnextday, predictTiming, window, threshold, generate_figure, stn, **kwargs) 161 self.diurnal_vals = [] 162 --> 163 self.df = self.find_diurnal_extrema() 164 if self.generate_figure: 165 self.plot() ~/WorkingDir/GrIS/X_PYTHON-CODES/datatools/diurnal.py in find_diurnal_extrema(self) 227 else: 228 # find diurnal minimum --> 229 minVal, minTime = self.get_real_extrema( 230 self.timeseries, day, 'min') 231 if self.minfirst and self.maxnextday: ~/WorkingDir/GrIS/X_PYTHON-CODES/datatools/diurnal.py in get_real_extrema(self, ts, window, min_or_max) 374 extremaTuple = self.get_extrema( 375 ts[window[0]:window[1]], min_or_max) --> 376 if not on_boundary(ts, window, extremaTuple, min_or_max): 377 extremaTuple = (None, None) 378 return extremaTuple ~/WorkingDir/GrIS/X_PYTHON-CODES/datatools/diurnal.py in on_boundary(timeseries, window, extrema_tuple, val_type) 525 bound = get_index_of_bound( 526 timeseries, window, start_or_end[idx]) --> 527 if _bool_is_same(bound, extrema_time): 528 boundary_ok = bool_check_around_bound(timeseries, bound, 529 extrema_tuple, val_type) ~/WorkingDir/GrIS/X_PYTHON-CODES/datatools/diurnal.py in _bool_is_same(val1, val2) 417 418 def _bool_is_same(val1, val2): --> 419 return True if val1 == val2 else False 420 421 ~/WorkingDir/GrIS/X_PYTHON-CODES/move/lib/python3.8/site-packages/pandas/core/generic.py in __nonzero__(self) 1327 1328 def __nonzero__(self): -> 1329 raise ValueError( 1330 f"The truth value of a {type(self).__name__} is ambiguous. " 1331 "Use a.empty, a.bool(), a.item(), a.any() or a.all()." ValueError: The truth value of a Series is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all().
The text was updated successfully, but these errors were encountered:
You can not currently pass timeseries with dtype pd.DataFrame, only accepts pd.Series timeseries data.
Sorry, something went wrong.
jzmejia
No branches or pull requests
Passing a series (empty) to is same. Need work around
The text was updated successfully, but these errors were encountered: