Converting .CSV file element to double

조회 수: 50 (최근 30일)
Andrea Carroll
Andrea Carroll 2020년 1월 19일
답변: Athul Prakash 2020년 1월 27일
I have imported a .csv file from excel into MATLAB all fine. However I can not manage to convert the elements into any numerical type as i need to do so for analysis. Any advice?
  댓글 수: 2
BN
BN 2020년 1월 19일
편집: BN 2020년 1월 19일
Dear Andrea,
May I see what is your code for importing your .csv file to the Matlab?
I suggest you to import your csv file using readtable:
T = readtable ('yourcsvfile.csv')
I think this will fix the problem?
dpb
dpb 2020년 1월 19일
If magic doesn't happen via readtable, attach the file; we have no idea what kind of input you're trying to convert to what...for starters, is it really a .csv file on the disk or are you trying to read an Excel file directly? Not totally clear...

댓글을 달려면 로그인하십시오.

채택된 답변

Athul Prakash
Athul Prakash 2020년 1월 27일
You may try setting options for the readtable function as outlined in this doc:

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Spreadsheets에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by