File: kdensity2d.dem

package info (click to toggle)
gnuplot 4.6.0-8
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 16,920 kB
  • sloc: ansic: 84,661; cpp: 6,631; lisp: 5,013; makefile: 2,129; sh: 1,092; objc: 647; asm: 539; perl: 298; awk: 235; pascal: 194; csh: 179; tcl: 88; python: 46
file content (20 lines) | stat: -rw-r--r-- 575 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# Run 'random.dem' to generate 'random.tmp'

reset
set title "How to plot a kernel density estimate for this 2D dataset?"
plot 'random.tmp' using 1:2

pause -1 "Press Return to continue - the plot may take some time to appear"

set view map
set palette defined (0 'white', 1 'red')
set dgrid3d 50,50 gauss kdensity
set title "set dgrid3d 50,50 gauss kdensity"

splot 'random.tmp' using 1:2:(1) with pm3d

pause -1 "Press Return to continue - the plot may take some time to appear"
set dgrid3d 50,50 gauss kdensity 0.1
set title "set dgrid3d 50,50 gauss kdensity 0.1"

replot