Clear Filters
Clear Filters

how to find centre of mass in each grid

1 view (last 30 days)
Raghu Rao
Raghu Rao on 11 Mar 2017
Edited: Raghu Rao on 12 Mar 2017
help me to find centre of mass in each grid in a image

Answers (1)

Image Analyst
Image Analyst on 11 Mar 2017
Extract each grid into a small subimage, then sum up the x and y
[rows, columns] = find(~subImage);
meanRow = mean(rows);
meanColumn = mean(columns);
  4 Comments
Raghu Rao
Raghu Rao on 12 Mar 2017
Edited: Raghu Rao on 12 Mar 2017
  • after editing my code am not getting proper results i want to point center of mass in each grid on image.but am not getting the results. please help me.

Sign in to comment.

Categories

Find more on Modify Image Colors in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!