Initial release of Maemo 5 port of gnuplot
[gnuplot] / demo / pointsize.dem
1 #
2 # Read individual point sizes from extra column of input file
3 # Ethan A Merritt - October 2004
4 #
5 unset key
6 unset border
7 unset yzeroaxis
8 unset xtics
9 unset ytics
10 unset ztics
11
12 #
13 # plot a 2D map with locations marked by variable sized points
14 #
15 set title "plot with variable size points"
16 plot 'world.dat' with lines lt 3, \
17      'world.cor' using 1:2:(5.*rand(0)) with points lt 1 pt 6 ps variable
18 pause -1 "Hit return to continue"
19
20 #
21 set title "splot with variable size points\nit is possible to specify size and color separately"
22 set view map
23 unset hidden3d
24 splot 'world.dat' using 1:2:(0) with lines lt 3, \
25       'world.cor' using 1:2:(0.5-rand(0)):(5.*rand(0)) with points pt 5 ps var lt palette
26 pause -1 "Hit return to continue"
27
28 #
29 # plot a '3D version using spherical coordinate system' of the world.
30 set angles degrees
31 set title "3D version using spherical coordinate system"
32 set ticslevel 0
33 set view 70,40,0.8,1.2
34 set mapping spherical
35 set parametric
36 set samples 32
37 set isosamples 9
38 set urange [-90:90]
39 set vrange [0:360]
40 splot cos(u)*cos(v),cos(u)*sin(v),sin(u) with lines lt 5,\
41       'world.dat' with lines lt 3, \
42       'world.cor' using 1:2:(1):(5.*rand(0)) with points lt 1 pt 6 ps variable
43 pause -1 "Hit return to continue"
44
45 #
46 # hidden3d still not working fully
47 # pointsize is now handled, but axes are never obscured
48
49 set title "3D solid version through hiddenlining"
50 set hidden3d
51 set arrow from 0,0,-1.2 to 0,0,1.2 lt 5 lw 2
52 set arrow from -1.2, 0, 0 to 1.2, 0, 0 nohead lt 5 lw 1 
53 set arrow from 0, -1.2, 0 to 0, 1.2, 0 nohead lt 5 lw 1
54 splot cos(u)*cos(v),-cos(u)*sin(v),sin(u) with lines lt 5,\
55       'world.dat' u 1:2:(1.001) with lines lt 3, \
56       'world.cor' using 1:2:(1):(5.*rand(0))  with points lt 1 pt 6 ps var
57 pause -1 "Hit return to continue"
58
59 reset
60