how to make a pcolor plot for a bands of y-scale in matlab?
4 views (last 30 days)
Show older comments
Hi,
I would like to make a pcolor plot of X (35x1 double), Y (1440x1 double) and Z (1440x34 double).
the x-value is actually a range which says that Z values run from X = 1-2,2-3,3-4,... thus making 34 pairs, which is consistent. But, how to give it in the input, as the dimensions does not match?
the command would follow something:
pcolor(X(:,2:end),Y(1:end,:),Z(1:end,:)); shading interp;
ylim([0,24]); xlim([100,1100]);
view([90 270]);
colormap(jet);
caxis([0 2000])
hand = colorbar('peer',gca,...
'Ticks',(0:500:2100),...
'TickLabels',(0:500:2100),...
'FontSize',12);
HOwever, it starts plotting from 213 on X-scale and not 199.60 (Ofcourse, since I have defined it here from 2:end onwards).
But is there any way we can ask command to plot in actual y-scale bands i.e from 199.60 to 213 corresponds to Z(:,1), 213 to 226.30 corresponds to Z(:,2) and so on.. making 34 pairs.
Here is the attached data.
Any help will be greatly appriciated.
0 Comments
Answers (0)
See Also
Categories
Find more on Axis Labels in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!