Plotting data from a .csv file
1.393 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Win
am 4 Dez. 2013
Kommentiert: Anthony Sirico
am 15 Jun. 2020
Hi I need to plot a graph in MATLAB using data from a .csv file which has 2 columns of data, column A and column B. Can you please tell me the codes to use to do that? Thanks.
Winee
Akzeptierte Antwort
sixwwwwww
am 4 Dez. 2013
you can do it as follows:
Array=csvread('filename.csv');
col1 = Array(:, 1);
col2 = Array(:, 2);
plot(col1, col2)
3 Kommentare
Carolina Pulido
am 10 Jun. 2020
I was able using this commands. Thanks. Reddy, check don't use titles into the columns.
Anthony Sirico
am 15 Jun. 2020
Can i plot data froma CSV file with a column of Names?, i.e col1 = star names, col2 = distances.
Weitere Antworten (1)
Siehe auch
Kategorien
Mehr zu Bar Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!