Write a script that will load data from a file into a matrix. Create the data file first, and make sure that there is the same number of values on every line in the file so that it can be loaded into a matrix
belongs to book: MATLAB: A Practical Introduction to Programming and Problem Solving|Stormy Attaway|Fourth Edition| Chapter number:5| Question number:8.5
All Answers
total answers (1)
Ch5Ex8.m
% load data from a file and plot data
% from each line in a separate plot in a subplot
load xfile.dat
[r c] = size(xfile);
for i = 1:r
subplot(1,r,i)
plot(xfile(i,:),'k*')
end
need an explanation for this answer? contact us directly to get an explanation for this answer