This is a basic form of a histogram.
axis is the axis;
tickets is the ruler on the axis, tickets the second parameter can make the number of [0, 1] appear as a percentage;
rangeroundbands in [0, Width] on the interval division, just suitable for the histogram, rangepoints in [0, Width] on the point division;
transform is the number of transformation coordinates relative to the parent node;
The function type executes before the load TSV file, and the program is executed asynchronously.
Bar Chart III:http://bl.ocks.org/mbostock/7441121
The final minimalist form of the histogram given by tutorial.
by the demonstration of the tickets method, it is found that the number of points (line) in the graph is only related to the incoming parameters when the first parameter of tickets is passed in.
log in the form of a axis. Ticksize The first parameter indicates the length of the line on the axis.
Special axis, display line on the dot line single-bit there are different CSS style.
Axis Date, vertical axis price, draw a curve.
D3.time.format, D3.time.scale two time related objects.
The most important is the D3.svg.line function, you can add a D attribute to the path and draw a curve.
multi-series line Chart:http://bl.ocks.org/mbostock/3884955
horizontal date, longitudinal axis temperature, draw the temperature contrast curve of different cities.
d3.scale.category10 distinguish different colors;
interpolate to the curve of the painting to add some modification;
comparing tricky is the cities of data re-processing, so it is convenient to draw different curves in batch.
The D3 example reads data from the TSV, and in reality we usually use Ajax to read the background data:Http://stackoverflow.com/questions/22784164/what-is-the-best-way-to-update-d3-charts-using-ajax
how to represent multi-series chart in a variety of ways, such as line, histogram:Http://www.delimited.io/blog/2014/3/3/creating-multi-series-charts-in-d3-lines-bars-area-and-streamgraphs
API to find:Https://github.com/mbostock/d3/wiki/API-Reference
How to draw multiple curves with D3 in one step