Flexdashboard formatting not appearing in knitting with Rmarkdown

Hello - I am running into trouble running flexdashboard with rmarkdown. Flexdashboard doesn't seem to be doing anything at all on my knitted website. I have run through multiple tutorials and tried various flexdashboard examples from the flexdashboard site (e.g. https://jjallaire.shinyapps.io/shiny-ggplot2-brushing/). All the elements in my rcode are appearing on my website (tables, figures, etc.) but not in the format specified by the flexdashboard code. I have uploaded a couple screenshots, one showing what the output should look like according to the flexdashboard examples page and a screenshot of what my page looks like running their source code (which is copied below for your convenience).

Any help is greatly appreciated.

---
title: "NBA Scoring (2008)"
output: 
  flexdashboard::flex_dashboard:
    orientation: rows
    social: menu
    source_code: embed
---

```{r setup, include=FALSE}
library(knitr)
library(d3heatmap)
library(flexdashboard)

url <- "http://datasets.flowingdata.com/ppg2008.csv"
nba_players <- read.csv(url, row.names = 1)
```

### Stats by Player {data-width=650}

```{r}
d3heatmap(nba_players, scale = "column")
```

### Top Scorers {data-width=350}

```{r}
knitr::kable(nba_players[1:20,c("G", "MIN", "PTS")])
```

I copied your code in RSTUDIO and click on the knit button and I get the correct rendering.
This should work as expected because the yaml header contain the correct format.

How do you render your Rmd ? Have you the flexdashboard :package: correctly install ?
Do you have the rendering log accessible ?

1 Like

Hi Chris,

Thank you for getting right back to me. You question about how the Rmd is rendered made me realize I hadn't tried clicking "build website" in the "build" panel. The "knit" button on its own does not render flexdashboard objects on my machine but the "build" option is working perfectly well.

Thanks again!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.