I am having difficulty in finding a code to find diameter of a circle
2 views (last 30 days)
Show older comments
Calvin Teoh
on 28 Oct 2021
Answered: Drishan Poovaya
on 1 Nov 2021
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/782563/image.png)
0 Comments
Accepted Answer
Drishan Poovaya
on 1 Nov 2021
Rather than finding the distance with code, I feel it would be easier to use imtool and use the 'Measure distance' tool.
You can run imtool by running the snippet below
imtool('image.png')
This will give you the relative distance in pixels. You can convert this value to mm by using the 'Measure distance' tool on the scale you have here, and calculating the ratios.
Refer to this answer for more details
0 Comments
More Answers (0)
See Also
Categories
Find more on Graphics Object Programming 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!