How can I rotate a figure in an image according to its principal axis?
Show older comments
Good day!
I have read some papers that indicates that as part of their image pre-processing, specifically the image with the hand pattern, they rotate the images first. As for example, the papers would indicate that the image in Figure A will be rotated to look like Figure B but they do not indicate the necessary steps on how to do it. They just simply mentioned that they are rotated according to its principal axis. How will I be able to rotate the images to Figure B even if the hand is oriented in different manner than Figure A? Thank you very much!

Accepted Answer
More Answers (1)
Sean de Wolski
on 24 Sep 2014
Use regionprops to find the _'orientation'_and imrotate to rotate it with this information
doc regionprops
doc imrotate
Categories
Find more on Region and Image Properties in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!