Azzera filtri
Azzera filtri

Importing CSV files in MATLAB

3 visualizzazioni (ultimi 30 giorni)
T
T il 11 Giu 2013
Suppose I have the following lines in a .csv file:
Date,Time,Ch1:
09/07/2007,12:26:51.000,10.684
09/07/2007,12:26:51.005,14.957
If one used an older version of Excel, these would automatically be placed in three columns without the commas. However, the above is not the case.
I was wondering how to convert these strings into an array.

Risposta accettata

T
T il 19 Giu 2013
int = size(raw,2);
if int == 3 raw ...
elseif int == 4
raw ...
end

Più risposte (1)

Iain
Iain il 11 Giu 2013
[n, t, r] = xlsread(filename);

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by