I must admit that I am lost. I have never worked with a .Rnv file.
However I do not understand what
\usepackage[ansinew]{inputenc}
is doing. What happens if you try
\usepackage[utf8]{inputenc}
Otherwise, to run a quick test try knitting this as a .Rmd file and see what happens
---
title: "Playing"
author: "toucan"
date: "13/12/2021"
output: pdf_document
---
H~2~O is a liquid. 2^10^ is 1024.
C~5~ is something else.
```{r plot, echo=FALSE}
xx <- 1:20
# Québec être ça
plot(xx)
This runs for me with this setup
R version 4.1.2 (2021-11-01)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 21.10
Matrix products: default
BLAS: /usr/local/lib/R/lib/libRblas.so
LAPACK: /usr/local/lib/R/lib/libRlapack.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_CA.UTF-8 LC_COLLATE=en_US.UTF-8 LC_MONETARY=en_CA.UTF-8
[6] LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_CA.UTF-8 LC_NAME=C LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_CA.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] grid stats graphics grDevices utils datasets methods base
other attached packages:
[1] tictoc_1.0.1 vroom_1.5.7 ggbiplot_0.55 scales_1.1.1 plyr_1.8.6 fs_1.5.2 lubridate_1.8.0 forcats_0.5.1 stringr_1.4.0
[10] dplyr_1.0.7 purrr_0.3.4 readr_2.1.1 tidyr_1.1.4 tibble_3.1.6 ggplot2_3.3.5 tidyverse_1.3.1 arrow_6.0.1
loaded via a namespace (and not attached):
[1] tidyselect_1.1.1 xfun_0.29 haven_2.4.3 colorspace_2.0-2 vctrs_0.3.8 generics_0.1.1 htmltools_0.5.2 yaml_2.2.1 utf8_1.2.2
[10] rlang_0.4.12 pillar_1.6.4 glue_1.6.0 withr_2.4.3 DBI_1.1.1 bit64_4.0.5 dbplyr_2.1.1 modelr_0.1.8 readxl_1.3.1
[19] lifecycle_1.0.1 munsell_0.5.0 gtable_0.3.0 cellranger_1.1.0 rvest_1.0.2 evaluate_0.14 knitr_1.37 tzdb_0.2.0 fastmap_1.1.0
[28] parallel_4.1.2 fansi_1.0.2 broom_0.7.9 Rcpp_1.0.8 backports_1.3.0 jsonlite_1.7.3 bit_4.0.4 hms_1.1.1 digest_0.6.29
[37] stringi_1.7.6 cli_3.1.0 tools_4.1.2 magrittr_2.0.1 crayon_1.4.2 pkgconfig_2.0.3 ellipsis_0.3.2 rsconnect_0.8.24 xml2_1.3.3
[46] reprex_2.0.1 rstudioapi_0.13 assertthat_0.2.1 rmarkdown_2.11 httr_1.4.2 R6_2.5.1 compiler_4.1.2