How to separate horizontly on the basis of gaps or space

1 view (last 30 days)
Hello friends,
I am trying to separate all characters vertically separated through gaps/spaces as highlighted in image through red, blue and green color
If I am trying to use bwlabel, it is separating connected components. thus I am losing ligatures and dots. Any help by providing me the link or sample code shall be highly appreciated.
Regards

Answers (1)

Image Analyst
Image Analyst on 6 Nov 2013
For this simple case, I'd just get profiles. I would sum the image horizontally and vertically and look for spikes.
horizontalProfile = sum(grayImage, 1); % Sum across all rows.
verticalProfile = sum(grayImage, 2); % Sum across all columns.

Community Treasure Hunt

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

Start Hunting!