D3js-stack diagram, d3js-Stack
:
Source code:
<% @ Page language = "java" import = "java. util. * "pageEncoding =" UTF-8 "%> <% String path = request. getContextPath (); String basePath = request. getScheme () + ": //" + request. getServerName () + ":" + request. getServerPort () + path + "/"; %> <! Doctype html public "-// W3C // dtd html 4.01 Transitional // EN">
Y and y0: y indicates the height of the rectangle (column), and y0 indicates the start height of the column (that is, where the rectangle starts to be drawn)
Explanation: (take the first row of column as an example)
The following figure shows the effect.
The starting position of the first rectangle (the Blue rectangle at the bottom) y0 is 0, and its height y (that is, the profit value in the data) is 3000; the middle rectangle is above the first rectangle, so its initial height y0 is 3000, and its height y is 2000; the starting height of the top layer rectangle is the height of the two rectangles below and 5000, and its height y is 1100. This is what y and y0 mean.
Source site: http://www.ourd3js.com/wordpress? P = 1007
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.