# d3.max ```js var xScale = d3.scale.ordinal() .domain(dataset) .rangeBands([0,w],0.3, 0.1); ```
### use: ```js .attr('width', xScale.rangeBand()) .attr('x', function(each_data, index){ return xScale(each_data); }) ```
本文共 270 字,大约阅读时间需要 1 分钟。
# d3.max ```js var xScale = d3.scale.ordinal() .domain(dataset) .rangeBands([0,w],0.3, 0.1); ```
### use: ```js .attr('width', xScale.rangeBand()) .attr('x', function(each_data, index){ return xScale(each_data); }) ```
转载地址:http://znrhx.baihongyu.com/