how to remove a middle line in the histogram

3 ビュー (過去 30 日間)
Malini Bakthavatchalam
Malini Bakthavatchalam 2020 年 12 月 15 日
コメント済み: Matt Gaidica 2020 年 12 月 17 日
Hi,
I have to remove the middle line in the histogram, I have attached a sample of my histogram output and the circled the line which i have to dont want in the central histogram, I am attaching my code here. pls do help me with that .
figure;
subplot(231)
imshow(MyImrgbBackBR.^(1/2.2));
subplot(232)
imshow(MyImrgbColb.^(1/2.2));
subplot(233)
imshow(MyImrgbBackTR.^(1/2.2))
subplot(234)
histogram(MyImrgbBackBR.^(1/2.2),"Edgecolor", [1 0 0], "facealpha",0.7)
xlim([0 1])
set(gca,'Yscale','log')
subplot(235)
histogram(MyImrgbBackBR.^(1/2.2),"Facecolor",[1 0 0],"Edgecolor", [1 0 0],"facealpha",0.7)
hold on;
histogram(MyImrgbBackTR.^(1/2.2),"Facecolor",[0 0 1],"Edgecolor", [0 0 1],"facealpha",0.7)
xlim([0 1])
set(gca,'Yscale','log')
subplot(236)
histogram(MyImrgbBackTR.^(1/2.2),"Facecolor",[0 0 1],"Edgecolor", [0 0 1],"facealpha",0.7)
xlim([0 1])
set(gca,'Yscale','log')
set(gca,'ylim',[0 10000]);

採用された回答

Matt Gaidica
Matt Gaidica 2020 年 12 月 16 日
編集済み: Matt Gaidica 2020 年 12 月 16 日
After subplot(234) capture ylim
ylimVals = ylim;
The set it after the other subplots:
ylim(ylimVals);

その他の回答 (1 件)

Matt Gaidica
Matt Gaidica 2020 年 12 月 16 日
Can you just plot a subsection of those data? Is this RGB data?
imshow(MyImrgbColb(1:end-1,:,:).^(1/2.2));
  13 件のコメント
Malini Bakthavatchalam
Malini Bakthavatchalam 2020 年 12 月 16 日
Hi is there any solution for this limits ?
Matt Gaidica
Matt Gaidica 2020 年 12 月 17 日
One way is to capture ylim after subplot(234)
ylimVals = ylim;
Then set it at subplot(236)
ylim(ylimVals);

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

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by