rstudio / rstudio/flexdashboard
vertical_scroll not working with facet_wrap
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 848
- Forks
- 298
- PR merge metrics
- No merged PRs in 30d
Description
I want the flex dashboard to take up the full screen (full width, full height) and scroll to fit a large number of plots in a facet wrap. Code is provided below and produces un-readable plots super compressed vertically. how can I achieve this in flex dashboard?
output of knitting below: https://imgur.com/a/LyfZTw3
---
title: "facet test"
output:
flexdashboard::flex_dashboard:
orientation: columns
vertical_layout: scroll
---
```{r setup, include=FALSE}
library(flexdashboard)
library(nycflights13)
library(tidyr)
library(dplyr)
library(ggplot2)
```
Column
-----------------------------------------------------------------------
### Chart A
```{r dfs and plots, include=FALSE, warning=FALSE, cache=FALSE}
df <- flights %>%
group_by(dest, time_hour) %>%
summarise(n = n()) %>%
ungroup()
sp <- ggplot(df, aes(x=time_hour, y=n)) + geom_line()
fr <- sp + facet_wrap(~ dest)
```
```{r facet, out.width = '100%', warning=FALSE, echo=FALSE, message=FALSE, error=TRUE}
fr
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the provided R example with flexdashboard, facet_wrap, and vertical_layout: scroll. Inspect how the dashboard handles the facet output and available sizing or scrolling options. Done means the dashboard uses the available screen height and width, scrolls through the facets, and keeps the plots readable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data-visualization, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100