How to get the boundary edge for object in MATLAB [duplicate] - matlab

This question already has answers here:
Find contour of 2D object in image in matlab
(1 answer)
Contour detection in MATLAB
(1 answer)
MATLAB - Find contour of a binary bit map?
(3 answers)
Compute contour of a binary image using matlab
(3 answers)
Closed 5 years ago.
I'm working to classify objects as human or non-human. My research focuses on the shape detection. I tried to use the function edge in MATLAB but I do not know how to find the boundary edge for the head, neck and shoulders only for a human object from an image. In another words I want to ignore the internal edges; I just want the boundary edge.
Can anyone help me in this?
i want to get this part only from the human object

Related

Matlab. Absolute markersize [duplicate]

This question already has answers here:
How to plot a circle in Matlab?
(2 answers)
How to plot a filled circle?
(1 answer)
Closed 5 years ago.
I know I can plot a dot and select its size with the word 'markersize' like this
plot(0,0,'.','markersize',50) %Dot centered in (0,0)
The size of the dot produced does not change if we amplify the plot. It always seems to have the same size to our eye. I would like to produce dots (or circles) with a real radius, so that when the image is amplified it appears bigger. What are my options?
Use rectangle command with curvature [1 1] it will draw circles with relative radius.

how to create 3d cylinder matlab [duplicate]

This question already has answers here:
Cylinder with filled top and bottom in matlab
(2 answers)
Closed 7 years ago.
I am trying to create a filled 3d shape that will look similar to this: (long round object)
(no need for the round part at the top, one color for all the object is good)
I've tried to create many similar circles with different center point but it didn't work, and with cylinder all I got was weird shapes.
To make a cylinder the exact name exists as a command:
figure;
cylinder(0.1,20);
axis equal;

Perspective correction using Matlab [duplicate]

This question already has answers here:
Matching images with different orientations and scales in MATLAB
(4 answers)
Closed 7 years ago.
After bounding natural images with textboxes (green), I want to apply a homography matrix (perspective correction) to project the green area to a rectangle.
Please refer to the link for the image mentioned above
http://i.stack.imgur.com/nhe4S.jpg
How can I implement the code / call the code in
http://www.mathworks.com/matlabcentral/answers/26141-homography-matrix
Alternatively, any other possibilities of other suitable algorithms?
I can provide you with the coordinates of the bounding box, obtained with
img=imread('perspective.jpg');
imshow(img); ginput(4)
and the coordinates of the quadrangle is
ans =
23.1597 25.0459
22.0220 55.9541
164.2375 61.6427
165.3752 30.1657
You can compute the homography transformation between the two bounding boxes using the fitgeotrans function. You can then apply the resulting transformation to the image using imwarp.

MATLAB: Saving a slice through volumetric data to an image [duplicate]

This question already has answers here:
Extract arbitrarily rotated plane of data from 3D array as 2D array
(2 answers)
Closed 8 years ago.
I have a 3D stack of bwlabeln'ed data (128 by 128 by 128). Is there a way to cut a slice through it (as in MATLAB slice(...)) and save the resulting image to a matrix?
Thanks in advance!
the function that may be of use is:
http://www.mathworks.com/matlabcentral/fileexchange/32032-extract-slice-from-volume
for other solutions, see:
Extract arbitrarily rotated plane of data from 3D array as 2D array
What kind of slice? Along one dimension e.g. z=5 you can use M(:,:,5). For diagonal slices you have to use some advanced method (interpolation).

Moving a point along a curve in matlab [duplicate]

This question already has an answer here:
Closed 10 years ago.
Possible Duplicate:
Points moving along a curve within MATLAB
I have two arrays ,the first represents the x-axis values and the second represents the y-axis values of a certain curve. I want to draw a point (or some object) that moves along that curve in MATLAB.
You can just trace the curve, i.e., you can place the cyrsor on the curve and press left or right to move your cursor across it.