Hi everyone,
I have 2 dimensional table and I want to convert column to row, however I don't know how to keep desired row names.
This is my starting table with data. As highlited, column header as well as row names are necessary in further transformation.
This is what I want to output. First row and first column have changed their places.
I've converted columns to rows, but row with desired column header is not first, so I don't know how to use not first row as column header.
I attach Alteryx file with data, source data and the final table.
It would be very great If you find any ideas how to achive it.
Thanks a lot in advance!
Solved! Go to Solution.
Hi @mat_ste_cb,
For this you will need to transform your data using the transpose and crosstab tools in the Transform toolkit. The transform tool allows you to get the individual values for each possible combination of the Company and Office Market. Then you can use the crosstab tool to group that data by the Office Market and use the Company as the Column Headers.
-Robert
Thanks a lot, I'm impressed. There is last think I want to do, but I haven't found any solution: how to set custom order of rows (not alphabetically nor numerically)?
To create a manual sort you can do the following...
Bring a text input tool, and create a field called say Name. Then add every value in that list in the order, then use a recordID tool.
You can then join this manual list against your main dataset before using a sort on the recordID field.
Example attached.
Ben