㈠ js 做3D的柱状图和饼状图的js库有哪些求大神们介绍。只限制js库,或者纯javascript。谢谢~~
当然是highchart 好用 !!!!
㈡ 用jsp怎样生成柱状图,饼状图,折线图
jsp生成柱状图,饼状图,折线图可以借助于jfreechart。
1、柱状图的生成源码:
/**
*生产柱状图
*@version1.0
*@since
*/
@SuppressWarnings("serial")
{
@Override
protectedvoidservice(HttpServletRequestrequest,
HttpServletResponseresponse)throwsServletException,IOException{
response.setContentType("text/html");
//使用普通数据集
=newDefaultCategoryDataset();
//增加测试数据,第一个参数是访问量,最后一个是时间,中间是显示用不考虑
chartDate.addValue(55,"访问量","2010-01");
chartDate.addValue(65,"访问量","2010-02");
chartDate.addValue(59,"访问量","2010-03");
chartDate.addValue(156,"访问量","2010-04");
chartDate.addValue(452,"访问量","2010-05");
chartDate.addValue(359,"访问量","2010-06");
try{
//从数据库中获得数据集
DefaultCategoryDatasetdata=chartDate;
//使用ChartFactory创建3D柱状图,不想使用3D,直接使用createBarChart
JFreeChartchart=ChartFactory.createBarChart3D(
"网站月访问量统计",//图表标题
"时间",//目录轴的显示标签
"访问量",//数值轴的显示标签
data,//数据集
PlotOrientation.VERTICAL,//图表方向,此处为垂直方向
//PlotOrientation.HORIZONTAL,//图表方向,此处为水平方向
true,//是否显示图例
true,//是否生成工具
false//是否生成URL链接
);
//设置整个图片的背景色
chart.setBackgroundPaint(Color.PINK);
//设置图片有边框
chart.setBorderVisible(true);
Fontkfont=newFont("宋体",Font.PLAIN,12);//底部
FonttitleFont=newFont("宋体",Font.BOLD,25);//图片标题
//图片标题
chart.setTitle(newTextTitle(chart.getTitle().getText(),titleFont));
//底部
chart.getLegend().setItemFont(kfont);
//得到坐标设置字体解决乱码
CategoryPlotcategoryplot=(CategoryPlot)chart.getPlot();
categoryplot.setDomainGridlinesVisible(true);
categoryplot.setRangeCrosshairVisible(true);
categoryplot.setRangeCrosshairPaint(Color.blue);
NumberAxisnumberaxis=(NumberAxis)categoryplot.getRangeAxis();
numberaxis.setStandardTickUnits(NumberAxis.createIntegerTickUnits());
BarRendererbarrenderer=(BarRenderer)categoryplot.getRenderer();
barrenderer.setBaseItemLabelFont(newFont("宋体",Font.PLAIN,12));
barrenderer.setSeriesItemLabelFont(1,newFont("宋体",Font.PLAIN,12));
CategoryAxisdomainAxis=categoryplot.getDomainAxis();
/*------设置X轴坐标上的文字-----------*/
domainAxis.setTickLabelFont(newFont("sans-serif",Font.PLAIN,11));
/*------设置X轴的标题文字------------*/
domainAxis.setLabelFont(newFont("宋体",Font.PLAIN,12));
/*------设置Y轴坐标上的文字-----------*/
numberaxis.setTickLabelFont(newFont("sans-serif",Font.PLAIN,12));
/*------设置Y轴的标题文字------------*/
numberaxis.setLabelFont(newFont("宋体",Font.PLAIN,12));
/*------这句代码解决了底部汉字乱码的问题-----------*/
chart.getLegend().setItemFont(newFont("宋体",Font.PLAIN,12));
//生成图片并输出
ChartUtilities.writeChartAsJPEG(response.getOutputStream(),1.0f,
chart,500,300,null);
}catch(Exceptione){
e.printStackTrace();
}
}
}
2、生成饼状统计图:
/**
*生成饼状统计图
*@version1.0
*@since
*/
@SuppressWarnings("serial")
{
protectedvoidservice(HttpServletRequestrequest,
HttpServletResponseresponse)throwsServletException,IOException{
response.setContentType("text/html");
//默认数据类型
DefaultPieDatasetdataType=newDefaultPieDataset();
//数据参数内容,数量
dataType.setValue("IE6",156);
dataType.setValue("IE7",230);
dataType.setValue("IE8",45);
dataType.setValue("火狐",640);
dataType.setValue("谷歌",245);
try{
DefaultPieDatasetdata=dataType;
//生成普通饼状图除掉3D即可
//生产3D饼状图
PiePlot3Dplot=newPiePlot3D(data);
JFreeChartchart=newJFreeChart(
"用户使用的浏览器类型",//图形标题
JFreeChart.DEFAULT_TITLE_FONT,//标题字体
plot,//图标标题对象
true//是否显示图例
);
//设置整个图片的背景色
chart.setBackgroundPaint(Color.PINK);
//设置图片有边框
chart.setBorderVisible(true);
//配置字体
Fontkfont=newFont("宋体",Font.PLAIN,12);//底部
FonttitleFont=newFont("宋体",Font.BOLD,25);//图片标题
//图片标题
chart.setTitle(newTextTitle(chart.getTitle().getText(),titleFont));
//底部
chart.getLegend().setItemFont(kfont);
ChartUtilities.writeChartAsJPEG(response.getOutputStream(),1.0f,
chart,500,300,null);
}catch(Exceptione){
e.printStackTrace();
}
}
}
3、柱状分布统计图:
/**
*柱状分布统计图
*@version1.0
*@since
*/
@SuppressWarnings("serial")
{
protectedvoidservice(HttpServletRequestrequest,
HttpServletResponseresponse)throwsServletException,IOException{
response.setContentType("text/html");
=newDefaultCategoryDataset();
//这是一组数据
dataTime.addValue(52,"0-6","2010-1-1");
dataTime.addValue(86,"6-12","2010-1-1");
dataTime.addValue(126,"12-18","2010-1-1");
dataTime.addValue(42,"18-24","2010-1-1");
//这是一组数据
dataTime.addValue(452,"0-6","2010-1-2");
dataTime.addValue(96,"6-12","2010-1-2");
dataTime.addValue(254,"12-18","2010-1-2");
dataTime.addValue(126,"18-24","2010-1-2");
//这是一组数据
dataTime.addValue(256,"0-6","2010-1-3");
dataTime.addValue(86,"6-12","2010-1-3");
dataTime.addValue(365,"12-18","2010-1-3");
dataTime.addValue(24,"18-24","2010-1-3");
try{
DefaultCategoryDatasetdata=dataTime;
//使用ChartFactory创建3D柱状图,不想使用3D,直接使用createBarChart
JFreeChartchart=ChartFactory.createBarChart3D(
"网站时间段访问量统计",
"时间",
"访问量",
data,
PlotOrientation.VERTICAL,
true,
false,
false
);
//设置整个图片的背景色
chart.setBackgroundPaint(Color.PINK);
//设置图片有边框
chart.setBorderVisible(true);
Fontkfont=newFont("宋体",Font.PLAIN,12);//底部
FonttitleFont=newFont("宋体",Font.BOLD,25);//图片标题
//图片标题
chart.setTitle(newTextTitle(chart.getTitle().getText(),titleFont));
//底部
chart.getLegend().setItemFont(kfont);
//得到坐标设置字体解决乱码
CategoryPlotcategoryplot=(CategoryPlot)chart.getPlot();
categoryplot.setDomainGridlinesVisible(true);
categoryplot.setRangeCrosshairVisible(true);
categoryplot.setRangeCrosshairPaint(Color.blue);
NumberAxisnumberaxis=(NumberAxis)categoryplot.getRangeAxis();
numberaxis.setStandardTickUnits(NumberAxis.createIntegerTickUnits());
BarRendererbarrenderer=(BarRenderer)categoryplot.getRenderer();
barrenderer.setBaseItemLabelFont(newFont("宋体",Font.PLAIN,12));
barrenderer.setSeriesItemLabelFont(1,newFont("宋体",Font.PLAIN,12));
CategoryAxisdomainAxis=categoryplot.getDomainAxis();
/*------设置X轴坐标上的文字-----------*/
domainAxis.setTickLabelFont(newFont("sans-serif",Font.PLAIN,11));
/*------设置X轴的标题文字------------*/
domainAxis.setLabelFont(newFont("宋体",Font.PLAIN,12));
/*------设置Y轴坐标上的文字-----------*/
numberaxis.setTickLabelFont(newFont("sans-serif",Font.PLAIN,12));
/*------设置Y轴的标题文字------------*/
numberaxis.setLabelFont(newFont("宋体",Font.PLAIN,12));
/*------这句代码解决了底部汉字乱码的问题-----------*/
chart.getLegend().setItemFont(newFont("宋体",Font.PLAIN,12));
ChartUtilities.writeChartAsJPEG(response.getOutputStream(),1.0f,
chart,500,300,null);
}catch(Exceptiones){
es.printStackTrace();
}
}
}
㈢ 【R语言】--- 饼状图
饼状图,又称为饼图,能够划分几个扇形的圆形统计图。可以描述量、频率、占比的相对关系。R语言中,可以用graphics包的pie()函数、ggplot2包的geom_bar()配合coord_polar()函数绘制,3D 的饼状图,可以使用 plotrix包的pie3D()函数。本文详细介绍饼状图的绘制。
x: 数值向量,表示每个扇形的面积
labels: 字符型向量,表示各扇形面积标签
edges: 多边形的边数(圆的轮廓类似很多边的多边形)
radius: 饼图半径
main: 饼图标题
clockwise: 逻辑值,用来指示饼图各个切片是否按顺时针做出分割
angle: 设置底纹的斜率
density: 底纹的密度,默认值为 NULL
col: 是表示每个扇形的颜色,相当于调色板
[1] Robert I. Kabacoff (着). R语言实战(高涛/肖楠/陈钢 译). 北京: 人民邮电出版社.
[2] https://www.runoob.com/r/r-pie-charts.html
[3] https://zhuanlan.hu.com/p/80415566
㈣ wps饼状图如何弄成立体的
1、首先,我们打开我们的电脑,然后我们打开wps,之后我们在wps中输入如图所示的数据;
㈤ chartlet控件如何调整3D饼状图的厚度
JFreeChart chart = ChartFactory.createPieChart3D("Pie Chart 3D Demo 3",
dataset, true, true, false);
PiePlot3D plot = (PiePlot3D) chart.getPlot();
plot.setDepthFactor(0.055d); //饼图的高度
把这个设置加上就行了
㈥ 请问下在网页前端中怎样实现直线图和饼状图的效果具体显示如下
这个是有插件的。可以研究一下水晶报表之类的控件看看 或者JQUERY里面也有这样的功能
㈦ 如何使用illustrator制作立体饼状图
分区上色用实时上色工具
下面有光源
可以增加光源来增强白光的强度
描边效果
㈧ wps怎么做三维饼图
以WPS的PPT文档为例,制作三维饼图的方法如下:
1、首先打开WPS的PPT窗口,进入后再点击工具栏中的“插入”,如图所示。
㈨ ppt如何做3d饼状图
做PPT图表时,一般采用在Excel中创作好图表后,在粘帖到PPT中,Excel和PPT中操作方法类似,(以ppt2013创作为例)点击菜单栏中,依次点击“插入”→“图标”→“饼图”→“3D饼图”后点击确定。
㈩ WPS表格制作图表的问题,如何让图表拥有3D感。
您好,很高兴为您解答!
你可以选定你需要展示的数据,“插入”——“图表”试试,不过3D效果WPS现还不支持,后续会推出,欢迎关注后续版本信息,
如果您有论文排版、模版下载、论文遇到难题,可以访问:http://docer.wps.cn/zt/lunwen?from=qyzd
更多WPS办公软件教程,请访问:http://bbs.wps.cn,祝你使用愉快,谢谢
如有疑问,请点击我的头像提问。祝您生活愉快!