Gnuplot 卷中各点的热图

Gnuplot 卷中各点的热图,gnuplot,Gnuplot,我有(x,y,z)点,坐标如下图所示 我想根据它们的浓度给点上色。 这个想法是制作一个点的热图,但在一个三维图形 我将非常感谢任何可能的帮助 注意。使用第四列中的数据值索引平滑调色板 splot DATA using 1:2:3:4 with points lc palette gnuplot开发版本现在支持点密度函数的计算,该函数可用于为单个点着色。这取决于在三维体素网格上操作的一组新命令。示例脚本和输出: set title "Gaussian 3D cloud of 3000 rand

我有(x,y,z)点,坐标如下图所示

我想根据它们的浓度给点上色。 这个想法是制作一个点的热图,但在一个三维图形

我将非常感谢任何可能的帮助


注意。

使用第四列中的数据值索引平滑调色板

splot DATA using 1:2:3:4 with points lc palette

gnuplot开发版本现在支持点密度函数的计算,该函数可用于为单个点着色。这取决于在三维体素网格上操作的一组新命令。示例脚本和输出:

set title "Gaussian 3D cloud of 3000 random samples\ncolored by local point density"
rlow = -4.0; rhigh = 4.0
set xrange [rlow:rhigh]; set yrange [rlow:rhigh]; set zrange [rlow:rhigh]
set xtics axis nomirror; set ytics axis nomirror; set ztics axis nomirror;
set xyplane at 0
set xzeroaxis lt -1; set yzeroaxis lt -1; set zzeroaxis lt -1;
set log cb; set cblabel "point density"

# define 100 x 100 x 100 voxel grid
set vgrid $vdensity size 100
vclear $vdensity    

# datablock $random has previously been loaded with 3000 points
# in a spherical Gaussian distribution about the origin
# The vfill command adds 1 to each voxel in a spherical region with radius 0.33
# around each point in $random
vfill $random using 1:2:3:(0.33):(1.0)

# plot the same points colored by local point density
splot $random using 1:2:3:(voxel($1,$2,$3)) with points pt 7 ps 0.5 lc palette

完整演示如下: