% save and who/whos clear all A = [1 2 3 4 5]; B = 12.5; C = rand(4); save savefile; A = [6 7 8]; save savefile A -append; mydataVariables = who('savefile.mat') mydataVariables = whos('savefile.mat') % load help load %example: % Using regular expressions, load from MAT-file mydata.mat those % variables with names that begin with Mon, Tue, or Wed: load('mydata', '-regexp', '^Mon|^Tue|^Wed'); % dlmwrite: Write matrix to ASCII-delimited file % example1: m = magic(3); dlmwrite('myfile.txt', m, 'precision', '%.6f') type myfile.txt % example2: M = magic(3); dlmwrite('myfile.txt', [M*5 M/5], ' ') dlmwrite('myfile.txt', rand(3), '-append', ... 'roffset', 1, 'delimiter', ' ') type myfile.txt % dlmread dlmread('myfile.txt') % comma limited files: csvread('myfile.txt') csvwrite('.....'): % diary command help diary