How to plot 3D contours of temperature, on the 3D surface of the body !?

6 views (last 30 days)
Hi everybody
I've plotted a colored 3D surface of a human body using patch command.
My data includes a 3x1000 matrix of XYZ (vertices), a 1x1000 vector of colors (temperature), and a 3x3000 matrix of Faces. (a matrix that explains which points must be connected in order to shape the 3D surface.)
So I've plotted the colored 3D surface with the above data; There's no problem up to this point.
Now here is my question :
How can I plot some 3D contours (of temperature) on this 3D surface, which illustrate iso-temperature points on the body !!?
Actually, I want to plot something similar to the below picture (excluding the black dots, of course !!):
-
-
I've searched a lot on this, but nothing came to be useful.
I'd be thankful if you provide me some help on this topic.
  4 Comments
Jonathan Epperl
Jonathan Epperl on 12 Apr 2013
Edited: Jonathan Epperl on 12 Apr 2013
Maybe you could post a minimal example that we can copy&paste into Matlab? Do you know or could you obtain explicit expression for your contours? If so, then just plot them in there using plot3.
EDIT: countourslice might actually be what you are looking for
Omid Adljuy
Omid Adljuy on 12 Apr 2013
Thank you very much Jonathan for your comment. Actually the contourslice command is exactly what I need; however, this reqires the input data to be (1) monotonic & (2) 3-Dimentional matrix. Well my data is neither monotonic nor 3D !!!

Sign in to comment.

Answers (2)

Michael
Michael on 12 Apr 2013
Edited: Michael on 12 Apr 2013
My own suggestion might be to generate the 3D surface using g = surf(x), remove the edges using set(g,'EdgeColor','none'), and then color the pixel faces using your temperature data (say, C, which should be the same dimension as x) using set(g, 'CData', C). These properties are found in the "patch properties" of the documentation, you can mess with lighting and other things there as well.
  1 Comment
Omid Adljuy
Omid Adljuy on 12 Apr 2013
Thank you very much Michael for your reply. Actually, all my data are vectors, so I can't use the surf command. However, I've plotted the 3D surface of human body, with the temperature data as its color, using patch command. Now the problem is: "How can I plot contour lines on this 3D surface !?"

Sign in to comment.


John Mickett
John Mickett on 7 Aug 2019
Mathworks folks should be able to create a function for this. There are lots of people looking to do this and is an important way of visualizing a 3D surface. Surf works but why not have a function that can do contours instead of colors.

Community Treasure Hunt

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

Start Hunting!