0
我有這個原始(字符串)數據。我想先將它改爲數字,然後通過刪除斜槓將第三列分成兩部分,這樣我的最終答案將是一個四(4)列矩陣。從矩陣中提取數據
[-0.095] [ 3.251] '0.152/0.0415'
[ NaN] [ NaN] [ NaN]
[ 3.194] [ 3.194] [ NaN]
[ 3.251] [ 9.911] '0.152/0.0387'
[ NaN] [ NaN] [ NaN]
[ 9.854] [ 9.854] [ NaN]
[ 9.911] [16.571] '0.152/0.0387'
[ NaN] [ NaN] [ NaN]
[16.514] [16.514] [ NaN]
[16.571] [23.211] '0.129/0.0535'
[23.154] [23.154] [ NaN]
[23.211] [29.851] '0.129/0.0535'
[29.794] [29.794] [ NaN]
你看着'strsplit'? https://uk.mathworks.com/help/matlab/ref/strsplit.html – GameOfThrows
您的示例數據是字符串中的方括號,還是它們表示分隔單元格中的字符串? – Tar