problem with Read excel file

4 views (last 30 days)
tara es
tara es on 20 Oct 2022
Answered: VBBV on 21 Oct 2022
I have an excel file like below.
when I read it using
fid = xlsread('P645.cwu.igs14.csv');
the first column(Date) didnt read and it just give
what is the problem?

Answers (2)

Marcel Kreuzberg
Marcel Kreuzberg on 20 Oct 2022
xlsread read numeric values by default check out readtable
Marcel Kreuzberg
Marcel Kreuzberg on 21 Oct 2022
after reading the file with readtable (and the 'NumHeaderLines',11 option) you should get an table. the problem is now, that the tirst column 'Date' is not numeric. to get an matrix you have to convert the Date to numeric value first.

Sign in to comment.

VBBV on 21 Oct 2022
You can try using a readmatrix function.

Community Treasure Hunt

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

Start Hunting!

Translated by