Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Trouble creating scanner with 2 time requirements

I am trying to create a scanner that will show me top gainers within a 20 day period, but all of the 20 day top gainers over a 4 year period.

I keep getting this error-

TypeError: zipline.pipeline.term.getitem() expected a value of type zipline.assets._assets.Asset for argument 'key', but got tuple instead.

It goes away when i remove - def Top_Percentage_Gainers(offset=5, nbars=3):

Any help would be appreciated!