Excess Column Consolidation

jldarby

New Member
Joined
Oct 23, 2016
Messages
2
So, I am trying to consolidate columns of Stata output, but I cannot for the life of me figure out how to do so efficiently.

There are 666 columns of data and 40,000+ rows, but I only need select data from each column based on the group number in Column 1, as seen in the screenshot below.

Additionally, it is not a consistent number of cells from each column.

Is there a function I can use to do this? Or anything to make it simpler? I appreciate any input!

group3123
1-0.7319769-0.73197690.0388026-0.1950958
11.4585451.4585450.88113820.6414637
11.3415781.3415782.5589160.8218915
10.03522790.03522790.30831410.1015673
10.14772710.14772710.19907850.117075
1-0.0239062-0.0239062-0.00018090.0202252
1-0.0860018-0.08600180.57782550.1154793
10.71922060.71922061.3076520.5013363
10.79327820.79327821.0005980.4751873
1-2.321617-2.321617-1.195768-0.81506
1-1.915917-1.9159170.235807-0.4159741
20.98785931.752460.98785930.7301992
20.248257-0.446510.248257-0.0651583
2-0.6440582-4.658056-0.6440582-0.8872776
20.6071137-0.06296040.60711370.1285889
2-0.0126544-0.4375088-0.0126544-0.1172441
21.3680641.3356241.3680640.6900043
2-2.075680-2.07568-1.625271
2-1.4806710-1.480671-1.339827
2-0.7909263-1.47055-0.7909263-0.5671665
20.29733380.30504050.29733380.1886359
2-0.6661274-2.607719-0.6661274-0.7394468
2-0.0568002-0.0916928-0.0568002-0.0136846
20.180681-0.90194510.180681-0.211238
22.3137371.3762342.3137370.8117952
2
30.89142.3582691.2350610.8914
31.2434443.6445642.7395771.243444
31.3122553.3923795.004291.312255
30.38162180.51477450.96563940.3816218
3-0.0589167-0.30787790.0697584-0.0589167
31.1307842.9448192.3780661.130784
30.14907830.21870290.24158230.1490783
3-3.1318380-6.404656-3.131838
3-0.0015069-0.0716653-0.0291563-0.0015069
30.5749281.015671.2016110.574928
3-0.5341317-1.377318-0.7383488-0.5341317
3-1.4730020-1.766249-1.473002
3-0.5346901-1.786477-0.346334-0.5346901
3-0.9732029-4.966533-0.919046-0.9732029
30.63486880.99345481.6698730.6348688
3-0.0912796-0.68750410.4643932-0.0912796

<colgroup><col><col><col span="3"></colgroup><tbody>
</tbody>
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
Sorry, my screenshot didn't come through correctly with the color-coding The unlabeled column is the expected results. The first 11 cells in the unlabeled column correspond to the 11 cells in the column labeled 1 (in the group3 column, "group" 1 corresponds to column 1. The next 15 cells in the unlabeled column correspond to the 15 cells in the column labeled 2, and so forth.
 
Upvote 0
While we do not prohibit Cross-Posting on this site, we do ask that you please mention you are doing so and provide links in each of the threads pointing to the other thread (see rule #13 here along with the explanation: Forum Rules). This way, other members can see what has already been done in regards to a question, and do not waste time working on a question that may already be answered.
 
Upvote 0

Forum statistics

Threads
1,215,352
Messages
6,124,451
Members
449,161
Latest member
NHOJ

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top