How to combine the discrete bands of x-values to a continous plot?

1 回表示 (過去 30 日間)
MP
MP 2022 年 7 月 11 日
コメント済み: MP 2022 年 7 月 11 日
I require a pcolor plot showing x-values in non-linear scale. These are discrete bands with increasing values. I would like to club all the discrete bands shown in the figure and make a continous structure.
In the figure, the Y-scale is continous and have a repeated gap between the numbers, while the x-scale does not have a regular gap between the numbers. If we take a regular gap, most of the plot will be white space. How to avoid this white space and make a continous plot?
Any suggestions will be greatly appriciated.
  2 件のコメント
KSSV
KSSV 2022 年 7 月 11 日
Share your data...seems like pcolor should work for you.
MP
MP 2022 年 7 月 11 日
Thank you for your reply. Please chcek attached data.
X-axis, X.mat. (time series data)
Y-axis, Y.mat.
Colorbar, C.mat.

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

採用された回答

KSSV
KSSV 2022 年 7 月 11 日
load('X.mat') ;
load('Y.mat') ;
load('C.mat') ;
X = T_mag3 ;
Y = E3(1,:)' ;
Z = FESA3 ;
pcolor(X,Y,Z)
shading interp
  3 件のコメント
KSSV
KSSV 2022 年 7 月 11 日
How about this?
h = pcolor(X,Y,Z)
h.EdgeColor = 'none';
MP
MP 2022 年 7 月 11 日
Oh sorry. That did not make a lot difference.
Actually, if you observed X-values, you can see that there is a narrow band from
3.57 to 3.61 (index: 1-14)
Then there a gap, then again a narrow band from
4.20 to 4.25 (index: 15-29)
Then there a gap, then again a narrow band from
12.63 to 12.70 (index: 31-54)
and so on,... This is how I want to stack distinct bands side-by-side but in a continous mode without (white/colored) gap.

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by