我有大数据作为文本文件(表是3,496,080行x 6列),想重新排列吗?我查看了排序功能,但没有取得任何进展。我通过MATLAB中的工具栏使用了sort
函数,几乎得到了我想要的数据。我尝试使用writetable
函数,但出现如下错误:
Error using writetable
Too many output arguments.
我应该如何使用排序功能然后编写一个文本文件?
data = sortrows(ionex, {'Year','DoY','Hour','Lat','Long','TEC'},'ascend');
例如:
1998 152 1 30 30 12
1998 152 1 30 25 12.5
1998 152 1 30 35 11.8
1998 152 1 30 40 11.9
1998 152 1 30 45 12
1998 152 3 30 25 10.9
1998 152 3 30 30 10.7
1998 152 3 30 35 10.6
1998 152 3 30 40 10.5
1998 152 3 30 45 10.4
1998 152 5 30 25 9.6
1998 152 5 30 30 9.5
1998 152 5 30 35 9.2
1998 152 5 30 40 9
1998 152 5 30 45 8.7
1998 152 7 30 25 8.4
1998 152 7 30 30 8.5
1998 152 7 30 35 8.9
1998 152 7 30 40 9.6
1998 152 7 30 45 10.7
1998 152 9 30 25 13.2
1998 152 9 30 30 14.3
1998 152 9 30 35 15.2
1998 152 9 30 40 15.9
1998 152 9 30 45 16.2
1998 152 11 30 25 16.2
1998 152 11 30 30 16.5
1998 152 11 30 35 16.8
1998 152 11 30 40 17.2
1998 152 11 30 45 17.9
1998 152 13 30 25 18
1998 152 13 30 30 18.6
1998 152 13 30 35 19.3
1998 152 13 30 40 20.1
1998 152 13 30 45 21.2
1998 152 15 30 25 20.4
1998 152 15 30 30 21.4
1998 152 15 30 35 22.5
1998 152 15 30 40 23.7
1998 152 15 30 45 25
1998 152 17 30 25 21.8
1998 152 17 30 30 23.2
1998 152 17 30 35 24.7
1998 152 17 30 40 26
1998 152 17 30 45 26.9
1998 152 19 30 25 22.4
1998 152 19 30 30 23.4
1998 152 19 30 35 24.3
1998 152 19 30 40 25
1998 152 19 30 45 25.6
1998 152 21 30 25 25.1
1998 152 21 30 30 25
1998 152 21 30 35 24.3
1998 152 21 30 40 23.3
1998 152 21 30 45 22
1998 152 23 30 25 20.9
1998 152 23 30 30 19
1998 152 23 30 35 17.2
1998 152 23 30 40 15.7
1998 152 23 30 45 14.5
排序数据
1998 152 1 30 25 12.5
1998 152 1 30 30 12
1998 152 1 30 35 11.8
1998 152 1 30 40 11.9
1998 152 1 30 45 12
1998 152 1 32.5 25 11.6
1998 152 1 32.5 30 11.1
1998 152 1 32.5 35 10.9
1998 152 1 32.5 40 11
1998 152 1 32.5 45 11.3
1998 152 1 35 25 10.7
1998 152 1 35 30 10.2
1998 152 1 35 35 10
1998 152 1 35 40 10.1
1998 152 1 35 45 10.5
1998 152 1 37.5 25 10.1
1998 152 1 37.5 30 9.5
1998 152 1 37.5 35 9.2
1998 152 1 37.5 40 9.3
1998 152 1 37.5 45 9.6
1998 152 1 40 25 9.6
1998 152 1 40 30 8.9
1998 152 1 40 35 8.6
1998 152 1 40 40 8.5
1998 152 1 40 45 8.8
1998 152 1 42.5 25 9.3
1998 152 1 42.5 30 8.6
1998 152 1 42.5 35 8.2
1998 152 1 42.5 40 8
1998 152 1 42.5 45 8.1
1998 152 1 45 25 9.3
1998 152 1 45 30 8.6
1998 152 1 45 35 8.2
1998 152 1 45 40 8
1998 152 1 45 45 8.1
1998 152 3 30 25 10.9
1998 152 3 30 30 10.7
1998 152 3 30 35 10.6
1998 152 3 30 40 10.5
1998 152 3 30 45 10.4
1998 152 3 32.5 25 10.2
1998 152 3 32.5 30 10
1998 152 3 32.5 35 9.9
1998 152 3 32.5 40 9.9
1998 152 3 32.5 45 10