Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Custom Factors: how to pass through older window frames

I have a custom factor that makes calculations on the last 50 days of prices. How do I adjust this so I can calc trailing 50 days as of yesterday or the day before yesterday or three days prior, instead of as of today?

Tahnk you,

class new_custom(CustomFactor):
inputs = [USEquityPricing.close]
window_length = 50 ## [-2::-50]?
def compute(self, today, asset_ids, out, values):