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

Creating multiple plots within a loop can break the Plot pane #727

Open
Tracked by #4734
DavisVaughan opened this issue Jun 12, 2023 · 3 comments
Open
Tracked by #4734

Creating multiple plots within a loop can break the Plot pane #727

DavisVaughan opened this issue Jun 12, 2023 · 3 comments
Labels
area: plots Issues related to Plots category. bug Something isn't working lang: r

Comments

@DavisVaughan
Copy link
Contributor

It seems like only some of the plots will actually render?

Screen.Recording.2023-06-12.at.9.49.39.AM.mov
@DavisVaughan DavisVaughan added this to the Internal Preview milestone Jun 13, 2023
@juliasilge juliasilge added the bug Something isn't working label Feb 16, 2024
@wesm wesm added area: plots Issues related to Plots category. and removed bug Something isn't working labels Feb 29, 2024
@timtmok timtmok added the bug Something isn't working label Feb 29, 2024
@DavisVaughan
Copy link
Contributor Author

From beta user https://github.com/posit-dev/positron-beta/discussions/211

for (i in 1:5) {
  plot(rnorm(10), runif(10))
}

@juliasilge
Copy link
Contributor

From GH Discussions #4614:

library(ggplot2)
library(purrr)

economics_list <- split(economics_long, economics_long$variable)

# In the RStudio IDE: all images get rendered to the Plots pane, and the user
# can navigate back and forth between the rendered images.
#
# In Positron: only the last image gets rendered, it's impossible to navigate
# to previous ones.
# 
economics_list |> 
  imap(
    \(df, nm) df |> 
      ggplot(aes(date, value)) +
      geom_line() +
      labs(title = nm)
      )

@testlabauto
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: plots Issues related to Plots category. bug Something isn't working lang: r
Projects
None yet
Development

No branches or pull requests

5 participants