EZ Statistics

Long and Wide Data Format Converter

Tool

1. Upload Your Data

Not sure about data formats? Check out the examples in the Learn More section below

Learn More

Understanding Long and Wide Data Formats

Long Format (Tidy)

Each row is an observation, with variables in columns

ID,Year,Measurement,Value
1,2020,Temperature,18.5
1,2020,Humidity,30
1,2021,Temperature,19.0
1,2021,Humidity,32
2,2020,Temperature,17.0
2,2020,Humidity,40
2,2021,Temperature,16.5
2,2021,Humidity,42

Wide Format

Data spread across multiple columns with unique identifiers

ID,Year,Temperature,Humidity
1,2020,18.5,30
1,2021,19.0,32
2,2020,17.0,40
2,2021,16.5,42

Long to Wide Transformation

Original Data (Long Format)

IDYearMeasurementValue
12020Temperature18.5
12020Humidity30
12021Temperature19
12021Humidity32
22020Temperature17
22020Humidity40
22021Temperature16.5
22021Humidity42

Result (Wide Format)

IDYearTemperatureHumidity
1202018.530
120211932
220201740
2202116.542

Wide to Long Transformation

Original Data (Wide Format)

IDYearTemperatureHumidity
1202018.530
120211932
220201740
2202116.542

Result (Long Format)

IDYearMeasurementValue
12020Temperature18.5
12020Humidity30
12021Temperature19
12021Humidity32
22020Temperature17
22020Humidity40
22021Temperature16.5
22021Humidity42

Can't find what you need?

If you couldn't find what you're looking for, we'd love to hear from you!

Let us know what you need