Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a way to plot multiple charts in RStudio's viewer? #59

Open
Fluxionist opened this issue Jun 9, 2015 · 3 comments
Open

Is there a way to plot multiple charts in RStudio's viewer? #59

Fluxionist opened this issue Jun 9, 2015 · 3 comments

Comments

@Fluxionist
Copy link

Sorry if I am posting at the wrong place. What I want is a stock price chart above a trading volume chart. I know that you can use group to synchronize them, but in RStudio two dygraphs are plotted separately into different pages. Is there a way to put these two (or even more) charts on the same plot in RStudio's viewer, like ggplot2's facets?

@jjallaire
Copy link
Member

No there isn't a way to do this in the Viewer. However, if you create an R
Markdown document you can create the layout you want and then set the
option to preview R Markdown within the Viewer.

On Tue, Jun 9, 2015 at 8:11 AM, Fluxionist notifications@github.com wrote:

Sorry if I am posting at the wrong place. What I want is a stock price
chart above a trading volume chart. I know that you can use group to
synchronize them, but in RStudio two dygraphs are plotted separately into
different pages. Is there a way to put these two (or even more) charts on
the same plot in RStudio's viewer, like ggplot2's facets?


Reply to this email directly or view it on GitHub
#59.

@MySchizoBuddy
Copy link

an example would be helpful

@AMarthaller
Copy link

An easy way to do this is to create your dyGraph variables in an R file and the just source it in an RMarkdown file and press the Knit to HTML button.

{r, echo=FALSE, include=FALSE}
source("DyGraphSample.R")

{r, echo=FALSE}
dyGraph1
dyGraph2

You must include the ``` marks before the {x} directives above but the site supports RMarkdown and I'm not sure how to escape it.

@klaukh klaukh mentioned this issue Aug 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants