when i load excel file number data read as string in matlab
이전 댓글 표시
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
Geoff Hayes
2018년 3월 15일
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
2018년 3월 15일
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
2018년 3월 15일
Adriana Velasquez
2021년 2월 18일
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
2021년 2월 18일
편집: Cris LaPierre
2021년 2월 18일
As Jeremy said, we can be of more help if you share your file. Attach your spreadsheet to your post using the paperclip icon.
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Spreadsheets에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!