How to sum data points within contour lines/isolines?
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hello,
I have a numeric matrix, z, in which each data point represents a single pixel of an image. If I plot a filled contour, I get the image below that defines my regions of interests (cancer cells) very nicely. Is there a method by which I can sum all the raw data points of my matrix within the outer contour line, including those within the lightest-coloured areas? I am hoping to obtain the total signal intensities of each cancer cell, and then the integrated intensity values. Many thanks in advance.

0 commentaires
Réponses (1)
Star Strider
le 20 Mar 2019
Modifié(e) : Star Strider
le 20 Mar 2019
You can certainly get the (x,y) coordinates of the contours, although it takes a bit of code the get the result you likely want. See specifically the documentation section on Custom Line Width (link) and the detailed explanation of the contour matrix in the documentation section for M (link). You will also find the Contour Properties (link) documentation section on 'LevelList' (link) helpful.
EDIT —
0 commentaires
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!