DanielManiel
New Member
- Joined
- May 29, 2017
- Messages
- 2
I am doing a regression analysis and have some data from a survey. One column is ethnicity. The way the data is set up is:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Yearly Salary
[/TD]
[TD]Ethnicity[/TD]
[TD]Age[/TD]
[/TR]
[TR]
[TD]100[/TD]
[TD]Black[/TD]
[TD]25[/TD]
[/TR]
[TR]
[TD]87[/TD]
[TD]White[/TD]
[TD]24[/TD]
[/TR]
[TR]
[TD]57[/TD]
[TD]Black[/TD]
[TD]65[/TD]
[/TR]
[TR]
[TD]94[/TD]
[TD]Hispanic[/TD]
[TD]45[/TD]
[/TR]
</tbody>[/TABLE]
But I would like it set up so that each ethnicity is it's own column:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Yearly Salary
[/TD]
[TD]Black[/TD]
[TD]White[/TD]
[TD]Age[/TD]
[/TR]
[TR]
[TD]100[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]25[/TD]
[/TR]
[TR]
[TD]87[/TD]
[TD]0[/TD]
[TD]1[/TD]
[TD]24[/TD]
[/TR]
[TR]
[TD]57[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]65[/TD]
[/TR]
[TR]
[TD]94[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]45[/TD]
[/TR]
</tbody>[/TABLE]
Is there a fast way of doing this in excel?
Thanks!
[TABLE="width: 500"]
<tbody>[TR]
[TD]Yearly Salary
[/TD]
[TD]Ethnicity[/TD]
[TD]Age[/TD]
[/TR]
[TR]
[TD]100[/TD]
[TD]Black[/TD]
[TD]25[/TD]
[/TR]
[TR]
[TD]87[/TD]
[TD]White[/TD]
[TD]24[/TD]
[/TR]
[TR]
[TD]57[/TD]
[TD]Black[/TD]
[TD]65[/TD]
[/TR]
[TR]
[TD]94[/TD]
[TD]Hispanic[/TD]
[TD]45[/TD]
[/TR]
</tbody>[/TABLE]
But I would like it set up so that each ethnicity is it's own column:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Yearly Salary
[/TD]
[TD]Black[/TD]
[TD]White[/TD]
[TD]Age[/TD]
[/TR]
[TR]
[TD]100[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]25[/TD]
[/TR]
[TR]
[TD]87[/TD]
[TD]0[/TD]
[TD]1[/TD]
[TD]24[/TD]
[/TR]
[TR]
[TD]57[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]65[/TD]
[/TR]
[TR]
[TD]94[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]45[/TD]
[/TR]
</tbody>[/TABLE]
Is there a fast way of doing this in excel?
Thanks!