IndexVariable.roll(shifts=None, **shifts_kwargs)[source]#

Return a new Variable with rolld data.

  • shifts (mapping of hashable to int) โ€“ Integer offset to roll along each of the given dimensions. Positive offsets roll to the right; negative offsets roll to the left.

  • **shifts_kwargs โ€“ The keyword arguments form of shifts. One of shifts or shifts_kwargs must be provided.


shifted (Variable) โ€“ Variable with the same dimensions and attributes but rolled data.