Chart.js中文文档-雷达图
雷达图或蛛网图(Radar chart)
简介
A radar chart is a way of showing multiple data points and the variation between them.
They are often useful for comparing the points of two or more different data sets
使用案例
newChart(ctx).Radar(data,options);
数据结构
var data ={
labels :["Eating","Drinking","Sleeping","Designing","Coding","Partying","Running"],
datasets :[{
fillColor :"rgba(220,220,220,0.5)",
strokeColor :"rgba(220,220,220,1)",
pointColor :"rgba(220,220,220,1)",
pointStrokeColor :"#fff",
data :[65,59,90,81,56,55,40]},{
fillColor :"rgba(151,187,205,0.5)",
strokeColor :"rgba(151,187,205,1)",
pointColor :"rgba(151,187,205,1)",
pointStrokeColor :"#fff",
data :[28,48,40,19,96,27,100]}]}
For a radar chart, usually you will want to show a label on each point of the chart, so we include an array of strings that we show around each point in the chart. If you do not want this, you can either not include the array of labels, or choose to hide them in the chart options.
For the radar chart data, we have an array of datasets. Each of these is an object, with a fill colour, a stroke colour, a colour for the fill of each point, and a colour for the stroke of each point. We also have an array of data values.
图表
Radar.defaults ={//Boolean - If we show the scale above the chart data
scaleOverlay :false,//Boolean - If we want to override with a hard coded scale
scaleOverride :false,//** Required if scaleOverride is true **//Number - The number of steps in a hard coded scale
scaleSteps :null,//Number - The value jump in the hard coded scale
scaleStepWidth :null,//Number - The centre starting value
scaleStartValue :null,//Boolean - Whether to show lines for each scale point
scaleShowLine :true,//String - Colour of the scale line
scaleLineColor :"rgba(0,0,0,.1)",//Number - Pixel width of the scale line
scaleLineWidth :1,//Boolean - Whether to show labels on the scale
scaleShowLabels :false,//Interpolated JS string - can access value
scaleLabel :"<%=value%>",//String - Scale label font declaration for the scale label
scaleFontFamily :"'Arial'",//Number - Scale label font size in pixels
scaleFontSize :12,//String - Scale label font weight style
scaleFontStyle :"normal",//String - Scale label font colour
scaleFontColor :"#666",//Boolean - Show a backdrop to the scale label
scaleShowLabelBackdrop :true,//String - The colour of the label backdrop
scaleBackdropColor :"rgba(255,255,255,0.75)",//Number - The backdrop padding above & below the label in pixels
scaleBackdropPaddingY :2,//Number - The backdrop padding to the side of the label in pixels
scaleBackdropPaddingX :2,//Boolean - Whether we show the angle lines out of the radar
angleShowLineOut :true,//String - Colour of the angle line
angleLineColor :"rgba(0,0,0,.1)",//Number - Pixel width of the angle line
angleLineWidth :1,//String - Point label font declaration
pointLabelFontFamily :"'Arial'",//String - Point label font weight
pointLabelFontStyle :"normal",//Number - Point label font size in pixels
pointLabelFontSize :12,//String - Point label font colour
pointLabelFontColor :"#666",//Boolean - Whether to show a dot for each point
pointDot :true,//Number - Radius of each point dot in pixels
pointDotRadius :3,//Number - Pixel width of point dot stroke
pointDotStrokeWidth :1,//Boolean - Whether to show a stroke for datasets
datasetStroke :true,//Number - Pixel width of dataset stroke
datasetStrokeWidth :2,//Boolean - Whether to fill the dataset with a colour
datasetFill :true,//Boolean - Whether to animate the chart
animation :true,//Number - Number of animation steps
animationSteps :60,//String - Animation easing effect
animationEasing :"easeOutQuart",//Function - Fires when the animation is complete
onAnimationComplete :null}
Chart.js本站下载地址:
1.Chart.js
Chart.js中文文档-雷达图的更多相关文章
- Sails.js中文文档
Sails.js中文文档 http://sailsdoc.swift.ren/ Sails.js是一个Web框架,可以于轻松构建自定义,企业级Node.js Apps.它在设计上类似于像Ruby ...
- Handlebars.js 中文文档
Home » 前端 » Handlebars.js 中文文档 Handlebars.js 中文文档 Posted in 前端 By KeenWon On 2014年4月3日 Views: ...
- Sails.js中文文档,Sails中文文档
Sails.js中文文档 http://sailsdoc.swift.ren/ Sails.js是一个Web框架,可以于轻松构建自定义,企业级Node.js Apps.它在设计上类似于像Ruby ...
- sharp.js中文文档
高性能node.js图像处理库,使用libvips库来实现. 英文地址:sharp.pixelplumbing.com/ 中文文档地址:yunlzhang.github.io/sharp-docum…
- React.js 中文文档
转自http://react-china.org/t/react-js/398的jsgeeker 中文文档地址 http://reactjs.cn GitHub地址 https://github.co ...
- hammer.js中文文档
转自:http://www.uedsc.com/hammerjs-api.html HammerJS是一个优秀的.轻量级的触屏设备手势库,现在已经更新到2.04版本,跟1.0版本有点天壤地别了,毕竟改 ...
- velocity.js 中文文档 (教程)
velocity.js 是一个简单易用.高性能.功能丰富的轻量级JS动画库.它能和 jQuery 完美协作,并和$.animate()有相同的 API, 但它不依赖 jQuery,可单独使用. Vel ...
- Etherscan API 中文文档-交易以及检查交易收据状态
本文原文链接 点击这里获取Etherscan API 中文文档(完整版) 完整内容排版更好,推荐读者前往阅读. 交易(Transaction) 交易相关的 API,接口的参数说明请参考Ethersca ...
- Etherscan API 中文文档-智能合约
本文原文链接 点击这里获取Etherscan API 中文文档(完整版) 完整内容排版更好,推荐读者前往阅读. 智能合约(Contracts) 智能合约相关的 API,接口的参数说明请参考Ethers ...
随机推荐
- NHibernate开发入门
首先,我们了解一下ORM是什么?ORM指对象关系映射(英语:Object Relational Mapping,简称ORM,或O/RM,或O/R mapping),是一种程序技术,用于实现面向对象编程 ...
- files list file for package 'xxx' is missing final newline
#!/usr/bin/python # 8th November, 2009 # update manager failed, giving me the error: # 'files list f ...
- [8.3] Magic Index
A magic index in an array A[0...n-1] is defined to be an index such that A[i] = i. Given a sorted ar ...
- Flask下如何处理Requests 上传中文文件名的问题
一.问题的由来 最近有个项目,叫做文档服务资源中心,类似于七牛,为各个业务系统提供统一的文件资源服务,包括文件的存储.操作管理.下载.预览等.在做文件存储的时候,遇到了这个当指定上传的文件名为 ...
- StringBuilder(字符串拼接类)
StringBuilder是在using System.Text命名空间下的一个成员. 在做字符串拼接的时候,因为字符串是引用类型,新的字符串是会再内存中创建的,所以用+号拼接字符串是比较耗效率的. ...
- UVA103 dp基础题,DAG模型
1.UVA103 嵌套n维空间 DAG模型记忆化搜索,或者 最长上升子序列. 2.dp[i]=max( dp[j]+1),(第i个小于第j个) (1) //DAG模型记忆化搜索 #include< ...
- 原生js模拟锚点,实现点击后,内容定位到本页的对应位置
今天在做angularJS项目过程中,遇见了一个需求,在一个页面中有多个表格,每个表格都有对应的分页,点击顶部对应的模块,可以定位到每个表格模块具体的位置. 页面如下所示: 在angular中,为了使 ...
- java包(package)的命名规范
Java的包名都有小写单词组成,类名首字母大写:包的路径符合所开发的 系统模块的 定义,比如生产对生产,物资对物资,基础类对基础类.以便看了包名就明白是哪个模块,从而直接到对应包里找相应的实现. 由 ...
- SpringMVC 框架的搭建及基本功能的实现
首先新建一个WEB项目 导入jar包 我们基于Spring mvc框架进行开发,需要依赖一下的spring jar包: spring-aop-4.0.4.RELEASE.jar spring-bean ...
- Xcode 调试技巧
一 NSLog调试 官方文档:Logs an error message to the Apple System Log facility. 即NSLog不是作为普通的debug log的,而是err ...