Importing text to cell, avoid conversion to scientific notation

조회 수: 4 (최근 30일)
Victoria Lawlor
Victoria Lawlor 2015년 10월 26일
댓글: Star Strider 2015년 10월 26일
I'm wondering how I can import a tab delimited text file into a cell without having it convert to scientific notation.
  댓글 수: 1
Stephen23
Stephen23 2015년 10월 26일
편집: Stephen23 2015년 10월 26일
The standard MATLAB file-reading functions read data with the full double precision, and do not "convert to scientific notation". When data is displayed in the command window it is often shown in scientific notation, but this is not the same thing as how it is stored. You can use format to change how numeric values are displayed.
Summary: displaying numeric variables is a different topic to how they are stored.

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

채택된 답변

Star Strider
Star Strider 2015년 10월 26일
The format function dictates how data are displayed in the Command Window and tooltips. Full precision is maintained internally.
  댓글 수: 4
Victoria Lawlor
Victoria Lawlor 2015년 10월 26일
"format long g" worked, thanks

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

추가 답변 (1개)

Thorsten
Thorsten 2015년 10월 26일
You can use dlmread for this task.

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by