Pandas Tips: How to Convert Columns To Rows

codeforests
Python in Plain English
5 min readOct 9, 2021

--

Photo by Jeremy Thomas on Unsplash

Introduction

In one of my previous posts — Pandas tricks to split one row of data into multiple rows — we discussed a solution to split the summary data from one row into multiple rows in order to standardize the data for further analysis. Similarly, there are many scenarios where we have the aggregated data like a Excel pivot table, and we need to unpivot it from wide to long…

--

--

Resources and tutorials for python, data science and automation solutions