NREL/rdtools

Make filtering more robust to inputs on varying indexes

mdeceglie opened this issue · 2 comments

The existing filtering framework, including that in TrendAnalysis doesn't work very well if filters or their inputs are on different date time indexes from energy_normalized, for example, irradiance is 30 minute, and energy_normalized is 15 minute. It would be good to provide some functionality to handle these cases.

@kanderso-nrel and I talked through the following thought experiment about desired behavior for different use cases of TrendAnalysis when interp_freq=None

PV frequency weather frequency behavior
15 min 15 min existing
15 min hourly interpolate weather to pv index, then filter
hourly 15 min all contributing weather has to pass filter
weekly hourly don't filter based on weather (turns on when PV is daily or lower freq)
hourly weekly raise error and don't do analysis (turns on when weather is daily or lower freq)

Capturing the outcome of a phone call on this one: For the time being in TrendAnalysis let's always interpolate onto the pv index, either with or without regularizing PV (depends on whether interp_freq is set)