Is there a way, in knitr to move the fig.cap above the figure? I need them above so that when the list-of-figure\'s hyperlink is selected for a certain table it navigates t
Maybe too late, but I think Yihui answered this.
You can change the knit hook for all figures to have the caption above the figure. For example, here is a version of a chunk from an .Rmd document. If you tell knitr to change the option for figure to have the document look first at and then at the actual .
```{r setup}
library(knitr)
knit_hooks$set(plot = function(x, options) {
paste('<figure><figcaption>', options$fig.cap, '</figcaption><img src="',
opts_knit$get('base.url'), paste(x, collapse = '.'),
'"></figure>',
sep = '')
})
```