I have an excel file containing numbers in five columns and several rows. Each column represents a variable.How I can generate a mat file that recognise the varaibles? And how to call the variables for the mat file generated?

 채택된 답변

Yuvaraj Venkataswamy
Yuvaraj Venkataswamy 2018년 6월 14일

1 개 추천

Use below commands.
if true
Input=xlsread('your_file.xls');
save Input.mat
end

댓글 수: 3

Davide Di Pasquale
Davide Di Pasquale 2018년 6월 14일
Thanks Yuvaraj,
I have created the Input. mat file, but How Can I read the variables?. Imagine I have x y u v w in the columns as variable, position and 3 velocity component. and want to read those. Thanks again and best regards,
Use this,
if true
load('Input.mat')
end
Yuvaraj Venkataswamy
Yuvaraj Venkataswamy 2018년 6월 14일
Then can define it as variable like below,
A=input;
Then use it for further processing.

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

추가 답변 (0개)

카테고리

제품

릴리스

R2017a

태그

Community Treasure Hunt

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

Start Hunting!

Translated by