I am currently using nPlot from rCharts package and how do I add $ signs to the y Axis?
I am thinking I need something like n1$yAxis(labels = ...)
but I don't think nPlot supports this?
test <- data.frame(object = c("A", "B"), price = c(111333, 876176))
test$Test <- "TEST"
n1 <- nPlot(price~Test, group = "object", data = test, type = "multiBarChart")
Also, it looks like nPlot is rounding to 5 significant figures (initially thought it was rounding to the nearest 10), is there a way of displaying the full value?
Thanks,
I am posting my comment as a full solution so that it is easier for others looking for it.
require(rCharts) # install the latest from the dev branch
test <- data.frame(object = c("A", "B"), price = c(111333, 876176))
test$Test <- "TEST"
n1 <- nPlot(price~Test, group = "object", data = test, type = "multiBarChart")
n1$yAxis(tickFormat = "#! function(d) {return '$' + d} !#")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With