how to correlation plots from image

3 ビュー (過去 30 日間)
nune pratyusha
nune pratyusha 2022 年 4 月 5 日
回答済み: nune pratyusha 2022 年 4 月 12 日
I = imread('Figure_1.png');
J = medfilt2(I);
R = corr2(I,J)
it showing error like
Error using medfilt2
Expected input number 1, A, to be two-dimensional.
Error in medfilt2>parse_inputs (line 107)
validateattributes(a, ...
Error in medfilt2 (line 49)
[a, mn, padopt] = parse_inputs(args{:});
Error in untitled15 (line 6)
J = medfilt2(I);
>>

回答 (2 件)

Tala
Tala 2022 年 4 月 5 日
I needs to be grayscale image. you want to convert your image to grayscale before passing ut to your filter. use imgtype = getImageType(I) and then convert it to grayscale

nune pratyusha
nune pratyusha 2022 年 4 月 12 日
but i am getting different hystogram plots using below code
A = imread('Figure11(b).png');
Ref = imread('Figure(b).png');
montage({A,Ref})
figure
displayHistogramChannels(A,Ref)
my output is comes like in untitled.fig
how to get histogram plots like Untitled.png

製品


リリース

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by