-
Notifications
You must be signed in to change notification settings - Fork 1
Column Chart
rodneykinney edited this page May 1, 2015
·
4 revisions
import quisp.Plot._
column(data)
.title("World's largest cities")
.legend.enabled(false)
.xAxis.categorical(true)
.xAxis.rotateTickLabels(true)
.yAxis.label("Population")
.options.fractionalBarWidth(.7)
column(data)
.title.text("World's largest cities")
.legend.enabled(false)
.xAxis.axisType(quisp.enums.AxisType.category)
.xAxis.additionalField("labels", Map("rotation" -> -45))
.yAxis.title.text("Population")
.series(0).showPointLabels(
quisp.highcharts.PointLabelFormat(
borderColor = java.awt.Color.black,
color = java.awt.Color.WHITE,
rotation = Some(-90),
align = quisp.enums.HAlign.right,
x = Some(4),
y = Some(3)
))
val data = List(
("Shanghai", 23.7),
("Lagos", 16.1),
("Instanbul", 14.2),
("Karachi", 14.0),
("Mumbai", 12.5),
("Moscow", 12.1),
("Sao_Paulo", 11.8),
("Beijing", 11.7),
("Guangzhou", 11.1),
("Delhi", 11.1),
("Shenzhen", 10.5),
("Seoul", 10.4),
("Jakarta", 10.0),
("Kinshasa", 9.3),
("Tianjin", 9.3),
("Tokyo", 9.0),
("Cairo", 8.9),
("Dhaka", 8.9),
("Mexico_City", 8.9),
("Lima", 8.9)
)