If you want to shift the index of a DataFrame by a specific number of periods, use pandas.DataFrame.shift.
pandas.DataFrame.shift
My previous tips on datetime in pandas.
DuckDB: Simplify DataFrame Analysis with Serverless SQL
Simplifying Dataset Comparison with Datacompy
Fuzzy Joining Tables with Non-Exact Matching Entries
Your email address will not be published. Required fields are marked *
Name
Email
Website
Save my name, email, and website in this browser for the next time I comment.
Δ