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;
Related
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
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.
This question already has answers here:
Plot circles with alpha values in MATLAB
(5 answers)
Closed 8 years ago.
I have a plot similar to the one below. This is a cylindar. The points near the axis are red and become more and more blue when they get far from it.
The problem is that the blue points completely hide the red ones.
Is there any way to make these blue points transparent enough to see what's inside?
I could suggest a hack to try. Given that you approximately know what the colors of the points you want to remove are, you could use findall or findobj to extract the line objects from your plots (maybe they're named something else in a 3D plot, don't have a lot of experience there) and then just delete those with the blue coloration.
This question already has answers here:
Retrieving X and Y values from Matlab Plot
(4 answers)
Closed 9 years ago.
I'm developing a GUI in Matlab that presents a plot (in an axis object). When clicking on a point in the plot, the GUI will open some other plots for that data point.
I added an axis object to my figure and implement the WindowButtonDownFcn to get a button click. I can get the mouse position with
pos=get(hObject,'CurrentPoint');
but how do I convert it to values in my plot? (i.e. which x-value was clicked on)
thanks.
(I'd be happy to hear if there is some simpler way to do this, instead of writing my own GUI)
Try looking up the help on ginput and then set that to some variable. Then plot the points for the number of ginputs you've done.
A lot of it is explained here: http://www.mathworks.com/help/techdoc/ref/ginput.html
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.