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
Mostrar comentarios más antiguos
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
Respuesta aceptada
Más respuestas (1)
Image Analyst
el 31 de Mzo. de 2013
0 votos
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.
Categorías
Más información sobre Image Segmentation and Analysis en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!