class_docstr: Calculates the percent change in close price over the given window_length.
  
  **Default Inputs**: [EquityPricing.close]
class_docstr_tok: ["Calculates","the","percent","change","in","close","price","over","the","given","window_length",".","*","*","Default","Inputs","*","*",":","[","EquityPricing.close","]"]
code: def _validate(self):
      super(Returns, self)._validate()
      if self.window_length < 2:
          raise ValueError(
              "'Returns' expected a window length of at least 2, but was "
              "given {window_length}. For daily returns, use a window "
              "length of 2.".format(window_length=self.window_length)
          )
  
imports: from numbers import Number
  from numpy import arange, average, clip, copyto, exp, fmax, full, isnan, log, NINF, sqrt, sum, unique
  from zipline.pipeline.data import EquityPricing
  from zipline.utils.input_validation import expect_types
  from zipline.utils.math_utils import nanargmax, nanmax, nanmean, nanstd, nansum
  from zipline.utils.numpy_utils import float64_dtype, ignore_nanwarnings
  from .factor import CustomFactor
  from ..mixins import SingleInputMixin
label_desc: Use image node_id 1 for calling the Returns obj's underlying member method code with example usage: obj._validate() without return types