Vegas--the missing matplotlib for scala
来源:互联网 发布:u盘数据丢失怎么恢复 编辑:程序博客网 时间:2024/05/18 03:34
最近有个任务,需要把scala中聚类的实验结果用scala展示出来,由于scala 本身没有提供matplotlib 的库,于是就寻找第三方的,看看有没有提供支持scala 画散点图的库 终于发现了Vegas.
Vegas 的 git 地址为
https://github.com/vegas-viz/Vegas
使用Vegas 也很简单 只要值pom文件中加入Vegas的依赖即可
<dependency> <groupId>org.vegas-viz</groupId> <artifactId>vegas_2.11</artifactId> <version>0.3.6</version></dependency>
import vegas._import vegas.render.WindowRenderer._val plot = Vegas("Results"). withData( Seq( Map("x" -> 1, "y" -> 1,"Origin"->"a"), Map("x" -> 2, "y" -> 2,"Origin"->"b"), Map("x" -> 3, "y" -> 3,"Origin"->"c") ) ). encodeX("x", Quant). encodeY("y", Quant). encodeColor(field="Origin", dataType= Nominal). mark(Point) plot.show
0 0
- Vegas--the missing matplotlib for scala
- Excel for Starters: The Missing Manual (Missing Manual)
- Access for Starters: The Missing Manual
- Office 2008 for Macintosh: The Missing Manual
- scala 学习笔记(scala for the impatient)
- 《快学Scala》, <Scala For the Impatient>习题第一章
- 《快学Scala》, <Scala For the Impatient>习题第二章
- 《快学Scala》, <Scala For the Impatient>习题第三章
- Changing the scala version for scala-maven-plugin
- EasyMock: missing behavior definition for the preceeding method call
- Windows Vista for Starters: The Missing Manual [ILLUSTRATED]
- PowerPoint 2007 for Starters: The Missing Manual [ILLUSTRATED]
- EasyMock: missing behavior definition for the preceeding method call
- Homebrew: The missing package manager for OS X
- Missing styles. Is the correct theme chosen for this layout?
- Missing styles. Is the correct theme chosen for this layout?
- missing styles is the correct theme chosen for this layout
- openwrt生成pkg error:missing dependencies for the following libraries
- Python_pandas使用初步认识
- Android Studio NDK 开发
- C#/.net学习-10-面向对象继承2
- 大数据组项目文档整理方案
- 职工系统(容器版)
- Vegas--the missing matplotlib for scala
- 用DIV模拟TEXTAREA【QQ空间说说对话框】
- C#/.net学习-11-面向对象多态
- Sciter:SciterLoadFile它是异步的
- 微信——WXML
- odoo ORM 对象方法列表
- laravel 5.3 单用户登录简单实现
- js传递汉字类型参数值乱码问题,以及url传递多个参数报违法的参数值
- 北漂家乡买房记:6年至少亏了50% 还无法脱手!