I have a discrete dataset data
of the form {10524, 2} where I have in the first row the {x,y,z}
coordinates and in the second row the evaluation f[x,y,z]
. The points are not dense, in that sense, that I kept only some points of $f$ above a bound.
Ignoring $f$ I can do that with ListPointPlot3D[data[[;; , 1]]]
however I don't see then, when the function is really large.
Is there a Colouring-Option or a totally different Plot-Option similar to perhaps DensityPlot3D
?
So a minimal example,
data = {{{0, 0, 0}, 1}, {{0, 1, 1}, 2}, {{0, 2, 1}, 3}}
ListPointPlot3D[data[[;; , 1]]]
And I want to see the difference between $1,2,3$
Thanks alot in advance
EDIT2: I now found C ListDensityPlot3D` which works for
data2 = {{0, 0, 0, 1}, {0, 1, 1, 2}, {0, 2, 1, 3}, {1, 2, 3, 4}, {0,
1, 0, 5}}
ListDensityPlot3D[data2]
but not doing a picture for my real data2
containing 5000 points, see a ListPointPlot3D
below
ListDensityPlot3D
doesn't work ondata2
is that it requires thex, y, z
coordinates to make up a rectangular array (though the error message generated could be clearer about this.) Trydata3 = Flatten[Table[{i, j, k, i + j + k}, {i, 0, 2}, {j, 0, 2}, {k, 0, 2}], 2]; ListDensityPlot3D[data3]
for a version that does work. $\endgroup$ListDensityPlot3D
requires at least 5 data points:data2 = {{0, 0, 0, 1}, {0, 1, 1, 2}, {0, 2, 1, 3}, {1, 1, 1, 4}, {-1, 1, 1, 3}}; ListDensityPlot3D[data2]
works for me, despite not being a rectangular array (contrary to what @MichaelSeifert suggested) $\endgroup$ListDensityPlot3D
(the usage without coordinates.) $\endgroup$data2
, which is quite special since the data is contained in a plane (and mathematically is actually 3D not 4D):data3 = Join[data2, # - {1, 0, 0, 0} & /@ data2, # + {1, 0, 0, 0} & /@ data2]; cfn = "DefaultColorFunction" /. (Method /. Charting
ResolvePlotTheme[Automatic, ListSliceDensityPlot3D]) // ColorData; With[{range = MinMax[data3[[All, -1]]]}, ListSliceDensityPlot3D[data3, {"XStackedPlanes", {0.}}, ColorFunction -> (cfn[Rescale[#, range, {0, 1}]] &), ColorFunctionScaling -> False]]` $\endgroup$