I have 100's of column CSV data with 50000 row data. i want to convert it into matlab. can anyone help me with this.
6 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Sai Sandeep Kornepati
il 31 Mag 2023
Risposto: Shishir Reddy
il 12 Giu 2023
I have a >100 of column data with >30000 of row data in CSV format. I tried to plot this in EXCEL but in excel it is not have any clarity and the data i have plotted is not been Zoomed in EXCEL. The data i cant put it here can anyone please help me solve this one. it is very urgent to me. i am a working proffssional.
Risposta accettata
Shishir Reddy
il 12 Giu 2023
Hi Sandeep,
As per my understanding, you want to extract the data from a .csv file and store in the MATLAB variable and then plot it.
Here’s a sample MATLAB code to perform the same.
%store the table in data
data = readmatrix('data.csv');
[r, c] = size(data);
%Setup figure
figure;
hold on;
for i = 1:c
plot(data(:, i))
end
%labels and legends can also be added
hold off;
In every iteration of the loop, we get one plot. Therefore, in total we get ‘c’ plots where c is the number of columns in the excel sheet.
For further reference, please refer these links to know more about ‘readmatrix’ and ‘plot’ functions.
I hope this helps resolving the issue.
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Data Import from MATLAB in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!