scikit-spectra
scikit-spectra copied to clipboard
Should methods that return series return timespectra just like slicing?
Noticed that methods like np.cov() will return a series of values given a timespectra (timeseries actually). Seems like the place to fix this would be in _dfgetattr in TimeSpectra.
Tried putting this in before hte if isintance(out, DataFrame) line:
### If operation returns a dataframe, return new TimeSpectra
if isinstance(out, Series) or isinstance(out, TimeSeries):
out=DataFrame(out)
Caused some errors that I didn't look into, but I think it might not work just cuz some instances of series are necessary. Like storing the references and dark spectra and such.