# How to disable interpolation in ListDensityPlot3D?

As an example

ListDensityPlot3D[
Partition[
Flatten@Table[{i, j, k, If[Mod[i, 2] == 0, 1, 0]}, {i, 1, 5}, {j, 1,
5}, {k, 1, 5}], 4],
PlotLegends -> True]


gives

But my data value are discrete and composed of only 0 and 1, I don't want ListDensityPlot3D to do interpolation for me.

I want something like the different between

ListDensityPlot[Table[x y, {x, 0, 1, 0.1}, {y, 0, 1, 0.1}]]


ListDensityPlot[Table[x y, {x, 0, 1, 0.1}, {y, 0, 1, 0.1}],
InterpolationOrder -> 0]


So is there any way to make 3D density plot similar to InterpolationOrder->0 like ListDensityPlot?

• I understand that ListDensityPlot3D does a smooth plot of the points represented. I find logical what MMA does, i.e., Interpolation. I think you should think about other plotting commands. In fact, I see that your points in the example are located in separated discrete planes, so what about ListPointPlot3D? Unless you want to do interpolation in those planes. In this case I suggest to combine with Show... – José Antonio Díaz Navas Apr 24 '18 at 10:35
• Hi, @JoséAntonioDíazNavas. Thank you for reply. But I don't want something like ListPointPlot3D. I have updated my post, maybe it is clearer now – matheorem Apr 24 '18 at 13:25

Show[Image3D[Table[