rcharts

label above points with rChart Failed with Chinese ,

99封情书 提交于 2019-12-24 14:40:10
问题 My problem is just like label above points with rChart *but my label contains Chinese code, my code is like this: library(rCharts) age <- c(1:20) tall <- seq(0.5, 1.90, length = 20) name <- rep(c("运营成本由一降为2","游戏进行推广","开始安全运行","无事件","this is"),4) Encoding(name)<-'UTF-8' df <- data.frame(age = age, tall = tall,name=name) n1 <- nPlot(age ~ tall ,data = df, type = "scatterChart") n1$xAxis(axisLabel = "the age") n1$yAxis(axisLabel = "the tall", width = 50) n1$chart(tooltipContent = "#! function

embed rChart in Markdown

*爱你&永不变心* 提交于 2019-12-24 05:01:10
问题 I am trying to embed a NVD3 chart in a Markdown document. I am on a Ubuntu64 system with RStudio 0.98.932, R 3.1.0, rCharts 0.4.2, the browser is Chrome. The instructions/code from this link: ```{r} library(rCharts) library(knitr) opts_chunk$set(comment = NA, results = "asis", comment = NA, tidy = F) hair_eye_male = subset(as.data.frame(HairEyeColor), Sex == "Male") n1 <- nPlot(Freq ~ Hair, group = 'Eye', data = hair_eye_male, type = 'multiBarChart' ) n1$set(width = 600) # n1$show('iframesrc'

Using global data in High Charts point click custom function in R Shiny

半世苍凉 提交于 2019-12-24 02:57:13
问题 I am trying to show a different table or plot in a different div when a bar on a a bar plot is clicked. I have come this far. server.R library(shiny) shinyServer(function(input,output,session) { custom_data = # a data frame in R barclick_func <- "#! function() { var cats = ['100','200','3000','4000']; var datum = [20,40,30,10]; } $('#container_subcat').highcharts({ chart: { type: 'column', }, xAxis: { categories:cats }, series: [{data :datum}] }); } !#" output$my_plot <- renderChart2({ a <-

Error on installing rCharts in R 3.1.1 (Windows)

两盒软妹~` 提交于 2019-12-24 02:49:31
问题 Is there a build of rCharts available for R 3.1.1? I tried 2 methods and both failed: Method 1: devtools::install_github('ramnathv/rCharts') Downloading github repo ramnathv/rCharts@master Error in function (type, msg, asError = TRUE) : couldn't connect to host Method 2: (Manually downloading the package and running install.packages ) install.packages("~/R/win-library/rCharts-master.zip", repos = NULL) Warning in install.packages : package ‘~/R/win-library/rCharts-master.zip’ is not available

How to include highcharts motion plugin for bubble plot using R wrapper?

蹲街弑〆低调 提交于 2019-12-24 01:28:05
问题 Highcharts motion plugin - Requires 3 adjustments to a highchart. The inclusion of the js asset An option object for motion Data to be within sequence arrays. It seems like there are two main R wrappers for Highcharts . Ramnath's rCharts and the recently released on CRAN highcharter. So my question: is it possible to animate a bubble highchart over time with the currently available wrappers and if so how? rCharts Attempt 1 Starting with a bubble chart and introducing the 3 required motion

Shiny dashboard multiple charts - overlapping

泄露秘密 提交于 2019-12-23 22:27:41
问题 I am using shiny dashboard package for my app. while trying to display 2 plots on the same page (each one in a box) they are overlapping. Also tried to use fluidRow for each plot - but still it seems both plot are connected to the same box (and overlapping) This is my code: mainPanel( fluidRow( box(showOutput("MeasuresPlot","morris"),width=6,title="Graph"), box(showOutput("ImportPlot","morris"),width=6,title="Graph2") ) ) 回答1: Your almost there, inside your fluid row you can use columns like

How to change the axis title with rCharts, dPlot and dimple

若如初见. 提交于 2019-12-22 17:58:34
问题 How can I change the axis titles of a plot generated with rCharts and the dimple.js library? For example: library(rCharts) data(mtcars) mtcars.df <- data.frame( car = rownames(mtcars), mtcars ) d1 <- dPlot(x ="disp", y="mpg", groups=c("car", "cyl"), type ="point", data=mtcars.df) d1$xAxis( type = "addMeasureAxis") d1 The desired effect is to replace the variable name "disp" with a more complete piece of text as the axis title. I've tried adding arguments to the d1$xAxis() line like title=

Change Font Size on rCharts Sankey Diagram

旧时模样 提交于 2019-12-22 11:27:13
问题 I'm using the following code to create a Sankey Diagram using rCharts. I wish to increase the font size of the text printed on the Sankey Diagram. I can't find a manual to show me how to do this. Thoughts? rm(list = ls()) require(reshape) require(rCharts) require(rjson) target <- c('TMF', 'TMF', 'TMF','Evaporation','Mill Reclaim','Void Losses','Seepage') source <- c('Precipitation & Run Off','Slurry','Other','TMF','TMF','TMF','TMF') value <- c(638,1610,755,118,1430,466,2) x <- data.frame

Change Font Size on rCharts Sankey Diagram

ⅰ亾dé卋堺 提交于 2019-12-22 11:26:24
问题 I'm using the following code to create a Sankey Diagram using rCharts. I wish to increase the font size of the text printed on the Sankey Diagram. I can't find a manual to show me how to do this. Thoughts? rm(list = ls()) require(reshape) require(rCharts) require(rjson) target <- c('TMF', 'TMF', 'TMF','Evaporation','Mill Reclaim','Void Losses','Seepage') source <- c('Precipitation & Run Off','Slurry','Other','TMF','TMF','TMF','TMF') value <- c(638,1610,755,118,1430,466,2) x <- data.frame

rPlot tooltip problems

三世轮回 提交于 2019-12-22 09:13:29
问题 I have a simple example using tooltips with rCharts that doesn't seem to work: set.seed(1) test <- data.frame(x = rnorm(100), y = rnorm(100)) rPlot(y ~ x, data = test, type = 'point', tooltip = "function(item){return item.x + '\n' + item.name + '\n' + item.y}") An empty page comes up. The plot is there if I remove the tooltip option. I'm using rCharts_0.4.1, R Under development on x86_64-apple-darwin10.8.0 (64-bit) and version 31.0.1650.63 of Chrome. Bonus question! Can tooltips contain