Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like 3Dplot a list of data with 4 columns (these are mesh outputs):

x1 y1 z1 Dose1
x2 y2 z2 Dose2

which command i should to use??

share|improve this question
Image3D is a possibility. But I'd advise you to do at least some basic searching through the docs before posting questions. – jVincent Sep 19 '13 at 20:33
You could try using Graphics3D to place a little sphere at {x1,y1,z1}, with radius determined by Dose1. Or you could place points at {x1,y1,z1} with the color determined by Dose1. – Timothy Wofford Sep 19 '13 at 20:39
@TimothyWofford BubbleChart3D is meant for that. Ali, it's really up to you what command you want to use, look here at this list for a starter:… – C. E. Sep 19 '13 at 20:54

Like I said in the comments, BubbleChart3D is meant to do what ListPointPlot3D is doing in this case. For example:

d = RandomReal[{0, 1}, {100, 4}];


In this first example, the volume of the bubbles is proportional to the fourth element. To represent the fourth dimension with colors, we can do this:

  BubbleSizes -> {0.02, 0.02},
  ColorFunction -> (ColorData["TemperatureMap"][#4] &)]


share|improve this answer

Quick & dirty, the color represents the fourth coordinate :

d = RandomReal[{0, 1}, {100, 4}];
Block[{i = 1},
   ListPointPlot3D[d[[All, ;; 3]], 
         ColorFunction -> Function[{x, y, z}, ColorData["TemperatureMap"][d[[i++, 4]]]], 
         PlotStyle -> Directive[PointSize[Large]]]]

Mathematica graphics

share|improve this answer
after importing in mathematica, our data form is:{{x1,y1,z1,dos1},{x2,y2,z2,dos2},...} are you sure i can plot these data with this commands?? – ali Sep 19 '13 at 21:07
@ali Take a look at his example data using d[[1 ;; 5]] -- it is exactly in this format. – C. E. Sep 19 '13 at 21:13
Ok, Thanks a lot! – ali Sep 19 '13 at 21:53

How about a grid of x vs y combinations. Here is an example in R Not difficult to do in Mathematica also, just not automatic.

a = Table[RandomReal[], {x, 1, 3}, {y, 1, 3}];
x = Table[RandomReal[], {x, 1, 3}, {y, 1, 100}];
y = a.x;

Table[ListPlot[Thread[{y[[i]], y[[j]]}], PlotLabel -> {i, j}], {i, 1, 
  3}, {j, 1, 3}] // Grid

enter image description here

share|improve this answer
Ian, RandomReal[] can receive parameters, so it's unnecessary to wrap it with a table. You can make your y in a single line. As for the charts, here's a more elegant example:… – Gregory Klopper Sep 20 '13 at 0:51
Yes and yes. Good example. My example is obviously just thrown together. – Ian Schumacher Sep 20 '13 at 1:03

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.