How can I store data from an excel file to a 1D vector

조회 수: 4 (최근 30일)
INDS
INDS 2020년 1월 12일
댓글: Star Strider 2020년 1월 12일
I have an excel spreadsheet with many values all in one column. How can I import these into matlab to be saved as a 1D vector?

답변 (1개)

Star Strider
Star Strider 2020년 1월 12일
Use the readmatrix function (R2019a and later), or xlsread with earlier versions.
  댓글 수: 2
INDS
INDS 2020년 1월 12일
How can I get it to be stored as a variable which I can name?
Star Strider
Star Strider 2020년 1월 12일
Something like this:
Vector = readmatrix('YourExcelFile.xlsx');
or:
Vector = xlsread('YourExcelFile.xlsx');
depending on the function you use.

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

카테고리

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