Hello all,
I have a .fig file that I want to make multiple profiles for, but improfile doesn't like when I try to pass it as an input.
[x,y,I] = improfile; works when I have a figure already open, but I want to take the initial x that I draw and make additional profiles the next pixel over. So my code looks like this:
figure(5)
imagesc(X,Y,Q,[0 1])
colormap(TSPcolormap);
colorbar;
[Px,Py,I] = improfile;
for k=1:5
[Qprof(:,k)] = improfile(figure(5), Px+k ,Py);
end
The .fig file is a matrix 600x800 and has a color map so if I try to save it as anything else it loses the scaling and shows up as intensity or RGB instead. So is there a way to tell improfile to read in the current figure?
Also I have tried replacing figure(5) with gcf, gca, etc. To use improfile with initial x and y would have to pass an image through and cannot leave it blank.
Thanks