3D Density Plotting Solutions for [x,y,z] Data

AI Thread Summary
To effectively display a 3D density plot for data points [x,y,z], using 'scatter3' may not adequately represent density due to overlapping data points. Suggestions include changing color or marker size to indicate the number of points at the same location, though this may still fall short in accurately depicting density for closely situated points. A more effective approach is to divide the volume into segments, count the points in each segment, and assign colors based on these counts. A potential solution was referenced from a MathWorks forum, indicating that further guidance on implementing color representation for varying densities is available.
jemma
Messages
35
Reaction score
0
I am trying to display a 3D density plot for my data [x,y,z] and have tried 'scatter3' however as some data points are the same it does not represent the density very well. There is a cool function called scattercloud on the file exchange, but this is only for [x,y] data. I would appreciate any suggestions. Thanks
 
Physics news on Phys.org
You could change the color (or marker size) to represent the number of points at the same location. If you're interested I can provide more help for doing this.

I suppose even if you did this, density might not be represented well, as having points that were close but not exactly the same wouldn't result in a color change. Instead, you could divide the volume up into pieces, get a count of the points in each piece, and then assign a corresponding color to each piece.
 
looks like somebody found a solution on mathworks forum:

http://www.mathworks.se/matlabcentral/newsreader/view_thread/268693
 
Thanks all for your replies. MisterX, how would I go about plotting different colours to represent different densities? Thanks again.
 
Back
Top