简体   繁体   中英

ggvis slider is squashed

I am using R version 3.2.0 (2015-04-16) from RStudio Version 0.98.1103. The platform is platform i386-w64-mingw32. I am using Windows Vista Version 6. This code

require(ggvis)
require(dplyr)

# ggvis use of a slider

mtcars %>% 
    ggvis(~wt, ~mpg, size := input_slider(10, 100), 
                opacity := input_slider(0,1) ) %>% 
    layer_points()

works, but the slider is squashed on the left of the plot and therefore difficult to use. How can I overcome this please?

This seems to be a bug in the CRAN version of ggvis .

Try:

# install.packages("devtools")
devtools::install_github("hadley/lazyeval", build_vignettes = FALSE)
devtools::install_github("hadley/dplyr", build_vignettes = FALSE)
devtools::install_github("rstudio/ggvis", build_vignettes = FALSE)

library(ggvis)

mtcars %>% 
  ggvis(~wt, ~mpg, size := input_slider(10, 100), 
        opacity := input_slider(0,1) ) %>% 
  layer_points()

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM