Hello Hadar,
The following commands will help you understand the usage of "regionprops" function with the properties Centroid, BoundingBox and Orientation :
% Read a binary image into workspace.
BW = imread('text.png');
% Calculate centroids, BoundingBox and Orientation for connected components in the image using regionprops.
% The regionprops function returns the values of these properties in the form of a table.
s = regionprops(BW,'centroid','BoundingBox','Orientation');
Please refer to the documentation link of regionprops, to better understand the usage of the function and the parameters it takes.
Thanks,
Niharika.
