www.gusucode.com > matlab 案例源码 matlab代码程序 > matlab/LoadEntireVariableExample.m

    %% Load Entire Variable  
% Load variable |topo| from the example file, |topography.mat|.   

%% 
% Open the example MAT-file, |topography.mat|. 
filename = 'topography.mat';
m = matfile(filename);  

%% 
% Read the variable |topo| from the MAT-file. 
topo = m.topo; 

%%
% MATLAB(R) loads the entire variable, |topo|, into the workspace.