Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我怎样才能在饼图中有动态值,
即我想要动态地拥有“重工业”、12 等等。
我不确定是否正确理解您的问题。但是您只需要动态创建数据数组。
var data= new Array(); for(var elem in tab) data.push([elem.key,elem.value]); //assuming tab is an array filled with object with attributes key and value
接着
jQuery.jqplot("chartname",[data]....