Home > Software design >  I am unable to add table caption to some of the tables in a quarto web page in R
I am unable to add table caption to some of the tables in a quarto web page in R

Time:01-08

I am trying to create a quarto web page. In this web page, I am unable to get table caption for some of the tables. In particular, this happens when the {easystats} package is involved.

```{r}
library(easystats)
library(broom)
```

Then I am creating a regression model using the mtcars dataset.

```{r}
lm_model <- lm(mpg~cyl drat, data = mtcars)
```

Now I am trying to create table of regression information.

```{r}
#| tbl-cap: "Easystats"
#| label: tbl-easystats
model_parameters(lm_model)
```

Another way to extract same info using {broom} package.

```{r}
#| tbl-cap: "Broom"
#| label: tbl-broom
tidy(lm_model)
```

Out of these two, the "Broom" table gets the caption when I render the document, but the "Easystats" package doesn't get the caption. In the place of the caption, it shows ?Caption. Is it something to do with the easystats package or is there some other issue?

Created on 2023-01-08 with reprex v2.0.2

CodePudding user response:

From EasyStats in Quarto


  • Related