Questions tagged [ggvis]

The goal of ggvis is to make it easy to describe interactive web graphics in R. It fuses the ideas of ggplot2 and shiny, rendering graphics on the web with vega (so one can draw on the canvas or using svg). It is less flexible than raw d3 or vega, but much more succinct and is tailored to the needs of exploratory data analysis.

From the author(s):

ggvis is a data visualization package for R which lets you:

  • Declaratively describe data graphics with a syntax that is similar to ggplot2.
  • View and interact with the graphics on your local computer, or use them in an interactive web application with shiny.
  • Data manipulation and transformation are done in R, and the graphics are rendered in a web browser, using vega. For RStudio users, ggvis graphics display in a viewer panel, which is possible because RStudio is a web browser.

Data manipulation and transformation are done in R, and the graphics are rendered in a web browser, using Vega. For RStudio users, ggvis graphics display in a viewer panel, which is possible because RStudio is a web browser.

486 questions
0
votes
1 answer

Multiple R plots with tooltips in one figure?

I want to create a new figure with interactive R-plots (with tooltips). To show how I wish to have my plots I give an example using the mtcars data. I am using the package scatterD3 to get tooltips: library(scatterD3) data(mtcars) tooltips <-…
R_FF92
  • 552
  • 1
  • 5
  • 19
0
votes
0 answers

Shiny Ggvis Interactivity

I have a plot with ggvis in my shiny app, my question is if I can click on a point of the plot and after that ... do something like in my case, fill a table with information about this point. Thank you
Náthali
  • 937
  • 2
  • 10
  • 22
0
votes
1 answer

change ggvis plot layer dynamically

I would like to change the layer of a ggvis plot using a selectInput widget using a dynamic interface. The problem is that when I choose a different layer after creating the plot, it changes but it just disappear really quick. Below is a simplified…
Geovany
  • 5,389
  • 21
  • 37
0
votes
1 answer

Special symbols in ggvis #no2

I know that the question about how to integrate greek symbols into axis titles in ggvis plots was answered by Thomas K in Special symbols in ggvis library(ggvis) title <- "CH\u2084 (\u03BC mol)" mtcars %>% ggvis(~wt, ~mpg) %>% layer_points()…
Laura
  • 3
  • 4
0
votes
1 answer

multiple line graph with ggvis in R

I am sure this is an easy question but I found only difficult answers... I just started to do some R programming and I really like the dplyr and ggvis package.. However I could not figure out how to combine multiple line graphs in one diagram. I…
Laura
  • 3
  • 4
0
votes
1 answer

Save ggvis html to file

Goal: I would like to be able to create static ggvis plots and pass a parameter for a directory path where the html file is saved. Mock Data: require(ggvis) # Create mock data to work with dfa <- data.frame( date_a = seq(from=…
Stan
  • 905
  • 9
  • 20
0
votes
1 answer

How to convert state name to latitude and longitude to create choropleth with ggvis in R?

I want to create a choropleth for income values in each state with package ggvis. Below is my data. I think latitude and longitude columns are required for mapping the data. Anyone knows that how can I convert the state name to latitude and…
wsda
  • 1,335
  • 1
  • 12
  • 16
0
votes
1 answer

ggvis: Transforming numeric values in the dataset using a slider

I am trying to use input_slider(1,10) to transform the values in my dataset by multiplying them by a selected value. For example, if the the selected value is 2, I would like the values to become 120*2, 140*2, 100*2. Here is my example: mydata <-…
Dambo
  • 3,318
  • 5
  • 30
  • 79
0
votes
1 answer

Strange behavior of y axis in histograms

I want to put a set of histograms of different variables all on the same scaled y axis using ggivs. However, once my axes get meaningfully larger than the highest count for a variable they start to get very strange and even start plotting the bars…
Elin
  • 6,507
  • 3
  • 25
  • 47
0
votes
1 answer

markdown+shiny+ggvis: graphics updated in new browser window

When using ggvis with shiny+markdown, everytime my graphic is updated, a new browser window is open. Consider the following MWE: --- title: "a" author: "b" date: "2015" output: html_document runtime: shiny --- Works fine when using base…
Ricardo Magalhães Cruz
  • 3,504
  • 6
  • 33
  • 57
0
votes
1 answer

Linked brushing not refreshing with ggvis and shiny

As a part of my shiny app, i am trying to have linked brushing so that i can subset my data via a brush and display that data in a separate ggvis plot relevant (simple) code is as follows: lb <- linked_brush(keys = 1:nrow(filteredData()),…
James Maine
  • 289
  • 2
  • 10
0
votes
0 answers

ggvis how to make gradient legend go top to bottom instead of left to right

Say we make a ggvis plot such as this one: mtcars %>% ggvis(x = ~wt, y = ~mpg, fill = ~cyl) %>% layer_points() %>% add_legend("fill", title = "Cylinders") How would I make the gradient legend go from top to bottom instead of from left to…
Andrew Taylor
  • 3,438
  • 1
  • 26
  • 47
0
votes
1 answer

Summing values for a month in R

please see data sample as follows: 3326 2015-03-03 Wm Eu Apple 2L 60 3327 2015-03-03 Tp Euro 2 Layer 420 3328 2015-03-03 Tpe 3-Layer 80 3329 2015-03-03 14/3 Bgs 145 3330 2015-03-04 T/P …
RFC_DA
  • 3
  • 4
0
votes
0 answers

How do I control the axis labels on a ggvis plot where the variables to be plotted are selected interactively?

I am trying to create an interactive visualization with the ggvis package. Specifically, the user should be able to select which of the variables should be plotted on which axes. One way to do this was already presented in answer 2 of this question.…
0
votes
2 answers

Returning Values from handle_hover() or handle_click() in ggvis

I was just hoping to figure out how i can use handle_hover() or handle_click() to return a value outside of the environment of the visualization. Ultimately i want to use this to return a key value so i can link two graphs onto a shiny…
James Maine
  • 289
  • 2
  • 10