Gnuplot density mapping

669 Views Asked by At

I have a set of points with x and y coordinates. I would like to plot the density of points in a particular region with the output being something like a heat map. Is it possible using gnuplot?

1

There are 1 best solutions below

0
On

This may be not the best solution, but here is what I used to do.

I hope you have data file data.dat, which have data entry like

x       y       z
1.486   1.528   779666
1.487   1.528   673036
1.488   1.528   565025
.       .       .
.       .       .

Now plot using the following command.

set hidden3d
set dgrid3d 50,50 qnorm 2
set view map
splot 'data_file' u 1:2:3 palette pt 5 ps 1.5

Set point size ps whichever meets your data's demand.