This page demonstrates how to build custom plotters with dygraphs. The plotter option allows you to write your own drawing logic. This can be used to achieve powerful customization. View source to see how the examples work.

Bar Chart

Here a specialized plotter is used to draw a bar plot rather than a line plot:

Daily Widget Sales
Widgets Sold
0
2
4
6
8
10
12
14
16
20 Jul
21 Jul
22 Jul
23 Jul
24 Jul
25 Jul

Candle Chart

Here a specialized plotter is used to combined four series into a unified "Candle" plot:

380
400
420
440
460
480
500
520
Jan 2012
Feb 2012

Bar & Line Chart

The plotter option may be set on a per-series basis to create mixed charts:

0
10
20
30
40
50
60
70
07 Jan
14 Jan

Multi-column Bar Chart

0
10
20
30
40
50
60
70
07 Jan
14 Jan

Mixed high/low bands and lines

You can tweak the standard plotters list to achieve effects which would be difficult otherwise, e.g. drawing series with only confidence intervals and showing high/low bands only for some series.

0
1
2
3
4
5
6
7
01 Oct
08 Oct
15 Oct
22 Oct
29 Oct
05 Nov
12 Nov
19 Nov
26 Nov

Smooth Lines

See the smooth-plots demo for an example of a custom plotter which connects points using bezier curves instead of straight lines.