Creating Function that Divides of Mean Pixel value fo two images
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
shiffraw dagnechaw
am 27 Jul. 2018
Erneut geöffnet: Walter Roberson
am 22 Dez. 2018
I'm trying to create a function that divides the mean pixel values of two images. I tried to write a function, but the answer it's giving me is one which is incorrect because when I calculated the individual mean pixel values and divided them I got approx 1/2. Here is my code:
function [Beta] = betacalc(beta1,beta2)
beta1im = imread(beta1);
beta2im = imread(beta2);
beta1mean = mean(beta1im(:));
beta2mean = mean(beta1im(:));
betadivide = beta1mean/beta2mean
end
0 Kommentare
Akzeptierte Antwort
Image Analyst
am 27 Jul. 2018
The code is correct, except for the error that Beta is never assigned by your function.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!