I have to load .mat file from a folder in my workspace. Can anyone tell me how to do so?

 채택된 답변

Mohammad Abouali
Mohammad Abouali 2015년 12월 8일
편집: Mohammad Abouali 2015년 12월 8일

0 개 추천

load C:\myFolder\mySubFolder\myMatFile.mat
or
variableName= 'myVarName';
matfilePath = 'C:\myFolder\mySubFolder\myMatFile.mat';
data = load(matfilePath);
% to access the variable
data.(variableName);

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Workspace Variables and MAT Files에 대해 자세히 알아보기

태그

질문:

2015년 12월 8일

편집:

2015년 12월 8일

Community Treasure Hunt

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

Start Hunting!

Translated by