|
2011-05-27 19:36:111738
|
jjQuery Plugin Graph (±×·¡ÇÁ Ç÷¯±×ÀÎ) |
|
È£¼®
|
|
| ÀÏ¹Ý | |
|
http://cshong.tistory.com/270
jQuery - http://jquery.com
jQuery.min.js
Protovis - http://vis.stanford.edu/protovis
Protovis-3.1.zip
1. ¿øÇÏ´Â °÷¿¡ ´ÙÀ½ÀÇ ÀÚ¹Ù½ºÅ©¸³Æ® Äڵ带 ³Ö¾î¼ »ç¿ëÇÑ´Ù.
var vis = new pv.Panel()
.width(150)
.height(150);
vis.add(pv.Bar)
.data([1, 1.2, 1.7, 1.5, .7, .3])
.width(20)
.height(function(d) d * 80)
.bottom(0)
.left(function() this.index * 25);
vis.render();
2. ´ÙÀ½°ú °°ÀÌ »ç¿ëÇϸé Â÷Æ®¿¡ °¡À̵å¶óÀÎÀ» »ç¿ëÇÒ ¼öµµ ÀÖ´Ù.
var vis = new pv.Panel()
.width(150)
.height(150);
vis.add(pv.Rule)
.data(pv.range(0, 2, .5))
.bottom(function(d) d * 80 + .5)
.add(pv.Label);
vis.add(pv.Bar)
.data([1, 1.2, 1.7, 1.5, .7])
.width(20)
.height(function(d) d * 80)
.bottom(0)
.left(function() this.index * 25 + 25)
.anchor("bottom").add(pv.Label);
vis.render();
|
|
|
|
|