![](/img/trans.png)
[英]How to split data of one column into multiple equal n columns in Excel or R?
[英]How to split one column of data into multiple columns in Excel
我目前在Microsoft Excel 2013中工作,我有一列大數據,我想一分為三。 我想從這里開始:
name_1
timestamp_1
comment_1
name_2
timestamp_2
comment_2
...
name_N
timestamp_N
comment_N
對此:
name_1 timestamp_1 comment_1
name_2 timestamp_2 comment_2
...
name_N timestamp_N comment_N
有沒有辦法做到這一點?
我認為您的數據在單列中。 您可以創建一個子來完成此操作
Sub rowToColumn()
nRow = 2 'Assume u have header on Row 1
Do until cells(nRow,"A") = ""
cells(nRow, 2) = cells(nRow + 1, "A")
cells(nRow, 3) = cells(nRow + 2, "A")
'Then remove the additional row.....
bla bla bla......
nRow = nRow + 1
Loop
End sub
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.