How can i set range in contour plot?

11 ビュー (過去 30 日間)
Norman Breedman
Norman Breedman 2016 年 12 月 16 日
コメント済み: Norman Breedman 2016 年 12 月 17 日
I loaded a data and drawed a graph (contour plot) .
In the graph, i could find a diagonal patterns. (image of figure -->)
and next, i want to separate each pattern by using for,if-loop and draw a graph of it.
but i don't know how to set range in contour plot.
could you help me?
load('data.mat')
figure(1)
contour(z)
set(gca,'XTick',[0:250:3700])
set(gca,'YTick',[0:50:600])
xlim([0 3700])
ylim([0 600])

採用された回答

KSSV
KSSV 2016 年 12 月 16 日
編集済み: KSSV 2016 年 12 月 16 日
load('data.mat')
idx = nonzeros(z) ;
figure(1)
contour(z)
z(:,3697:end) = [] ;
N = 168 ;
% set(gca,'XTick',[0:250:3700])
% set(gca,'YTick',[0:50:600])
% xlim([0 3700])
% ylim([0 600])
K = reshape(z,405,N,[]) ;
for i = 1:size(K,3)
x = (1:N)+(i-1)*N ;
y = 1:405 ;
contour(x,y,K(:,:,i)) ;
drawnow
hold on
pause
end
I am reshaping your z matrix into 405x168x22, considering there are 22 strips in the contour plot of z. Each K has partial pattern.
  1 件のコメント
Norman Breedman
Norman Breedman 2016 年 12 月 17 日
thanks for your answer. but how should i do to separate each pattern and show them in each figure.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeContour Plots についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by