Skip to content

References to computationally-generated sub-tables/sub-figures #1494

Answered by jjallaire
connorp asked this question in Q&A
Discussion options

You must be logged in to vote

Yikes, I don't think we actually show that in the docs for tables! Analogous to how we handle figures (which is documented, https://quarto.org/docs/authoring/cross-references.html#computations) we auto-generate the sub-table labels off of a master label. So for example:

```{r}
#| label: tbl-so-many
#| tbl-cap: So many tables!
#| tbl-subcap: 
#|   - Table One 
#|   - Table Two 
#|   - Table Three

... # some code

```

See @tbl-so-many-1 and @tbl-so-many-2

Note that you need to use the tbl prefix in your label to create a cross-referencable table.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@connorp
Comment options

Answer selected by mcanouil
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants