Please help me implement the equations: Pij = (f(i,j))/(∑_(i=1)^M∑_(j=1)^N〖f(i,j)〗) and H = ─∑_(i=1)^M∑_(j=1)^NPijlog2Pij
Ältere Kommentare anzeigen
Can someone please explain how to implement these equations in MATLAB?
Pij = (f(i,j))/(∑_(i=1)^M∑_(j=1)^N〖f(i,j)〗)
H = ─∑_(i=1)^M∑_(j=1)^NPijlog2Pij
Akzeptierte Antwort
Weitere Antworten (1)
Image Analyst
am 31 Mär. 2013
0 Stimmen
Try to construct a pair of nested for loops over i and j. See the getting started section if you don't know how to program in MATLAB yet. The latter formula is the entropy and there are functions for that, such as entropyfilt() in the Image Processing Toolbox.
Kategorien
Mehr zu Image Arithmetic finden Sie in Hilfe-Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!