Pivoting Data in R


When organizing or tidying your data using R, you might need to convert wide data to long data or long to wide.

We can use the pivot_longer() and pivot_wider() functions. They are part of the tidyr package.

Leave a Reply