rstudio / rstudio/flexdashboard
Flexdashboard sizing of rows when using text and graphs
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 848
- Forks
- 298
- PR merge metrics
- No merged PRs in 30d
Description
I'm having issues with sizing on flexdashboard. When I have a graph along side some text, the row re-sizes to fit the height of the text but I want it to fit the graph when the dashboard is maximized. Is this possible? I need the dashboard to be scroll layout due to the number of graphs that will be in there.
I've tried resizing the graphs but this doesn't work.
When I don't use plotly the graph isn't stretched but still shrunk to fit the text.
Code below replicates the issue with the flexdashboard template (had issues with it printing the backticks so you'll need to remove the quotes on lines 11 and 31). Thanks.
---
title: "Example"
output:
flexdashboard::flex_dashboard:
orientation: rows
vertical_layout: scroll
---
```{r setup, include=FALSE}
library(flexdashboard)
"```"
Row
-----------------------------------------------------------------------
### Chart A
```{r}
library(ggplot2)
library(plotly)
Data <- data.frame(x = c(1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005),
y= c(2000, 5000, 10000, 7000, 18000, 20000, 2000, 2000, 5000, 35000, 7000))
g1 <- ggplot(Data, aes(x, y)) +
geom_line(size = 0.9) +
scale_x_continuous(breaks = seq(1995,2005,2)) +
scale_y_continuous(breaks = seq(0, 35000, 5000), limits=c(0,35000)) +
theme_classic()
ggplotly(g1)
"```"
###
text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text
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 running the supplied flexdashboard template with scroll layout, text, ggplot2, and plotly content to reproduce the row-sizing behavior. Investigate the dashboard layout and sizing entry points used by this template; done means graph-containing rows size to the graph when maximized without breaking scroll layout.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, r
- Domain
- data-visualization, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100