I have tried to center an image and I have not been able, I have found that you can center text, Centered text , but I have not found examples of how to center an image, thanks in advance to those who know
Asked
Active
Viewed 1,295 times
0
-
Possibly related: https://stackoverflow.com/q/41514579/3151675 – Tamás Sengel Jul 03 '21 at 15:57
2 Answers
4
In your chunk options.
{r chunkName, fig.align="center", out.height="90%", out.width = "90%", fig.cap=" Whatever.\\label{whatever}"}
knitr::include_graphics("figures/whatever.png")

Dharman
- 30,962
- 25
- 85
- 135

geomicrobio
- 321
- 1
- 3
- 15
-
"""""" I am customizing my Github with this gift, this is the line that inserts the gift, your help did not work for me, thank you very much – John_B Jun 30 '21 at 02:13
-
I suggest you provide more information about your problem and some code in order to have more specifications. – geomicrobio Jun 30 '21 at 15:09
0
for those rendering to docs... I accomplished this by having a well-formatted docx template and then specifying that section in my code... In my case heading 3 (###) is centered in my word doc template.
---
output:
word_document:
reference_docx: template.docx
---
...your other code...
### {width=250}

Brandon Rose MD MPH
- 445
- 5
- 7