diff options
author | bnewbold <bnewbold@robocracy.org> | 2016-02-21 14:09:55 -0800 |
---|---|---|
committer | bnewbold <bnewbold@robocracy.org> | 2016-02-21 14:09:55 -0800 |
commit | 439655aaa40568acd0b4f536e67f6b90031ee147 (patch) | |
tree | c94bc6acc9a526812a862d34673c875e56541a6c /examples/graphs/axis.jl | |
parent | 13db261935cd85bc91563999f451bc93081b34de (diff) | |
download | PyX.jl-439655aaa40568acd0b4f536e67f6b90031ee147.tar.gz PyX.jl-439655aaa40568acd0b4f536e67f6b90031ee147.zip |
add examples (all ports from PyX 0.14.1)
Diffstat (limited to 'examples/graphs/axis.jl')
-rw-r--r-- | examples/graphs/axis.jl | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/examples/graphs/axis.jl b/examples/graphs/axis.jl new file mode 100644 index 0000000..cc699bb --- /dev/null +++ b/examples/graphs/axis.jl @@ -0,0 +1,20 @@ + +#from pyx import * +# +#g = graph.graphxy(width=8, +# x=graph.axis.log(min=1e-1, max=1e4, title=r"$x$-axis"), +# y=graph.axis.lin(max=5, title=r"$y$-axis")) +#g.plot(graph.data.function("y(x)=tan(log(1/x))**2")) +#g.writeEPSfile("axis") +#g.writePDFfile("axis") +#g.writeSVGfile("axis") + +using PyX +using LaTeXStrings + +g = graph.graphxy(width=8, + x=graph_axis.log(min=1e-1, max=1e4, title=L"$x$-axis"), + y=graph_axis.lin(max=5, title=L"$y$-axis")) +plot(g, graph_data_function("y(x)=tan(log(1/x))**2")) +writeEPSfile(g, "axis") +writePDFfile(g, "axis") |