I am trying to auto-number images in with Bookdown. It was working fine while my section headers were numbered, but when I remove the numbering in the sections, the figure numbers also disappear:
## This is a subheading {-}
```{r hp, fig.cap="Relationship between horsepower and miles per gallon",
echo = FALSE}
plot(mtcars$hp, mtcars$mpg)
```
This is some text where I want to refer to the figure
(Figure \@ref(fig:hp))
.
Is it possible to have un-numbered subheadings, and still have the figures auto-number throughout the document (i.e., instead of it calling "Figure 1.1", "Figure 1.2", etc., you just get "Figure 1", "Figure 2")?