when i load excel file number data read as string in matlab
Afficher commentaires plus anciens
I use T = readtable('rawtrans1.xlsx') this command to load excel data . but found numeric data type declared in excel read as string in Matlab.So I can't do numeric calculation
5 commentaires
Geoff Hayes
le 15 Mar 2018
Kakoli - can you convert to a number using str2double? I see that T is a table so presumably you are accessing a certain row or column from it...
Jeremy Hughes
le 15 Mar 2018
It would help to see the file.
If the numbers are stored as TEXT in the spreadsheet, READTABLE will read those as text. Otherwise, I'd expect those to be imported as DOUBLE.
KAKOLI DEY
le 15 Mar 2018
Adriana Velasquez
le 18 Fév 2021
I'm having the same problem and I have the format for that column in Excel as number. I tried cientific too..but nothing..readtable is reading the values as string. Did you figure it out two years ago @KAKOLI DEY?
Cris LaPierre
le 18 Fév 2021
Modifié(e) : Cris LaPierre
le 18 Fév 2021
As Jeremy said, we can be of more help if you share your file. Attach your spreadsheet to your post using the paperclip icon.
Réponses (0)
Catégories
En savoir plus sur Spreadsheets dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!