'How to edit rolling function for panda to look at not sliding windows but sequential windows

I have the data set below as in the link picture. How to use rolling function rolling( window = offset ??? , min_periods = 1, center = True, closed = 'both' ) on the windows with size of 6, going one after another ( it are not sliding windows, but sequential windows with offset of 6)

Scheme of the windows I try to check some rules

Regards, Nataliya



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source