summaryrefslogtreecommitdiff
path: root/graphics/asymptote/doc/datagraph.asy
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/asymptote/doc/datagraph.asy')
-rw-r--r--graphics/asymptote/doc/datagraph.asy12
1 files changed, 12 insertions, 0 deletions
diff --git a/graphics/asymptote/doc/datagraph.asy b/graphics/asymptote/doc/datagraph.asy
new file mode 100644
index 0000000000..62cca8ea89
--- /dev/null
+++ b/graphics/asymptote/doc/datagraph.asy
@@ -0,0 +1,12 @@
+import graph;
+
+size(200,150,IgnoreAspect);
+
+real[] x={0,1,2,3};
+real[] y=x^2;
+
+draw(graph(x,y),red);
+
+xaxis("$x$",BottomTop,LeftTicks);
+yaxis("$y$",LeftRight,
+ RightTicks(Label(fontsize(8pt)),new real[]{0,4,9}));