Commit 81e98ba9 authored by Paul Asmuth's avatar Paul Asmuth
Browse files

simplify the plotting interface

parent 2a8976f3
Loading
Loading
Loading
Loading
+5 −5
Original line number Original line Diff line number Diff line
(default limit-y (0 20000000))
(limit-y (0 20000000))
(default limit-x (1404278100 1404299700))
(limit-x (1404278100 1404299700))


(plot/axes
(axes
    position (bottom left)
    position (bottom left)
    label-format-y (scientific)
    label-format-y (scientific)
    label-format-x (datetime "%H:%M:%S"))
    label-format-x (datetime "%H:%M:%S"))


(plot/grid
(grid
    color #fff)
    color #fff)


(plot/areas
(areas
    data-x (csv "test/testdata/measurement.csv" time)
    data-x (csv "test/testdata/measurement.csv" time)
    data-y (csv "test/testdata/measurement.csv" value1)
    data-y (csv "test/testdata/measurement.csv" value1)
    color #888)
    color #888)
+6 −6
Original line number Original line Diff line number Diff line
(height 480px)
(height 480px)
(width 1200px)
(width 1200px)


(default limit-y (-50 50))
(limit-y (-50 50))


(plot/axes
(axes
    position (bottom top))
    position (bottom top))


(plot/areas
(areas
    data-x (csv "test/testdata/areadata2.csv" x)
    data-x (csv "test/testdata/areadata2.csv" x)
    data-y (csv "test/testdata/areadata2.csv" z)
    data-y (csv "test/testdata/areadata2.csv" z)
    data-y-low (csv "test/testdata/areadata2.csv" y)
    data-y-low (csv "test/testdata/areadata2.csv" y)
    color #ccc)
    color #ccc)


(plot/areas
(areas
    data-x (csv "test/testdata/areadata2.csv" x)
    data-x (csv "test/testdata/areadata2.csv" x)
    data-y (csv "test/testdata/areadata2.csv" z2)
    data-y (csv "test/testdata/areadata2.csv" z2)
    data-y-low (csv "test/testdata/areadata2.csv" y2)
    data-y-low (csv "test/testdata/areadata2.csv" y2)
    color #888)
    color #888)


(plot/lines
(lines
    data-x (10 20 30 40 50)
    data-x (10 20 30 40 50)
    data-y (1.23 10.32 -6.23 4.43 3.45)
    data-y (1.23 10.32 -6.23 4.43 3.45)
    marker-size 4pt)
    marker-size 4pt)


(figure/legend
(legend
    position (bottom right)
    position (bottom right)
    item-flow on
    item-flow on
    item (label "Series A" color #ccc)
    item (label "Series A" color #ccc)
+4 −4
Original line number Original line Diff line number Diff line
(height 480px)
(height 480px)
(width 1200px)
(width 1200px)


(default limit-x (0 150))
(limit-x (0 150))
(default limit-y (1404278100 1404299700))
(limit-y (1404278100 1404299700))


(plot/axes
(axes
    position  (left bottom)
    position  (left bottom)
    label-format-y (datetime "%H:%M:%S"))
    label-format-y (datetime "%H:%M:%S"))


(plot/areas
(areas
    data-x (csv "test/testdata/measurement.csv" value2)
    data-x (csv "test/testdata/measurement.csv" value2)
    data-y (csv "test/testdata/measurement.csv" time)
    data-y (csv "test/testdata/measurement.csv" time)
    direction horizontal
    direction horizontal
+8 −8
Original line number Original line Diff line number Diff line
(width 1600px)
(width 2048px)
(height 900px)
(height 512px)
(dpi 240)
(dpi 240)


(default scale-x (categorical (A B C D E F)))
(scale-x (categorical (A B C D E F)))
(default limit-y (0 80))
(limit-y (0 80))


(plot/axes
(axes
    label-placement-y (linear-interval 10 10 70))
    label-placement-y (linear-interval 10 10 70))


(plot/grid
(grid
    color (rgba 0 0 0 .05)
    color (rgba 0 0 0 .05)
    stroke-style (dashed)
    stroke-style (dashed)
    tick-placement-x (none))
    tick-placement-x (none))


(plot/bars
(bars
    data-x (csv "test/testdata/bardata.csv" var3)
    data-x (csv "test/testdata/bardata.csv" var3)
    data-y (csv "test/testdata/bardata.csv" var1)
    data-y (csv "test/testdata/bardata.csv" var1)
    width (1em)
    width (1em)
    offset (-.8em)
    offset (-.8em)
    color #444)
    color #444)


(plot/bars
(bars
    data-x (csv "test/testdata/bardata.csv" var3)
    data-x (csv "test/testdata/bardata.csv" var3)
    data-y (csv "test/testdata/bardata.csv" var2)
    data-y (csv "test/testdata/bardata.csv" var2)
    width (1em)
    width (1em)
+82 −82

File changed.

Preview size limit exceeded, changes collapsed.

Loading