2 import sys
; sys
.path
[:0] = ["../.."]
9 def test_minimal(c
, x
, y
):
10 g
= c
.insert(graph
.graphxyz(x
, y
, size
=3))
11 g
.plot(graph
.data
.file("data/husimi_small.dat", x
=1, y
=2, z
=3))
13 def test_line(c
, x
, y
):
14 g
= c
.insert(graph
.graphxyz(x
, y
, size
=3))
15 g
.plot(graph
.data
.file("data/husimi_small.dat", x
=1, y
=2, z
=3), [graph
.style
.line()])
17 def test_grid(c
, x
, y
):
18 g
= c
.insert(graph
.graphxyz(x
, y
, size
=3, x
=graph
.axis
.lin(title
="x axis"), y
=graph
.axis
.lin(title
="y axis"), z
=graph
.axis
.lin(title
="z axis")))
19 g
.plot(graph
.data
.file("data/husimi_small.dat", x
=1, y
=2, z
=3), [graph
.style
.grid()])
21 def test_surface(c
, x
, y
):
22 g
= c
.insert(graph
.graphxyz(x
, y
, size
=3, x
=graph
.axis
.lin(), y
=graph
.axis
.lin(), x2
=None, y2
=None))
23 g
.plot(graph
.data
.file("data/husimi_small.dat", x
=1, y
=2, z
=3, color
=4), [graph
.style
.surface()])
25 def test_surface2d(c
, x
, y
):
26 g
= c
.insert(graph
.graphxy(x
, y
, width
=6, height
=6))
27 g
.plot(graph
.data
.file("data/husimi_small.dat", x
=1, y
=2, color
=3), [graph
.style
.surface()])
33 test_surface(c
, 8, -8)
34 test_surface2d(c
, -3, -20)
36 c
.writeEPSfile("test_graph3d", page_paperformat
=document
.paperformat
.A4
)
37 c
.writePDFfile("test_graph3d", page_paperformat
=document
.paperformat
.A4
)
38 c
.writeSVGfile("test_graph3d", page_paperformat
=document
.paperformat
.A4
)