Knitting an Rmd file deletes data files in a needed folder, halting the knitting?
My Rmd script was made to convert FTIR-ATR .asc files to .txt (Chunk 1), delete the first 56 lines of the .txt (Chunk 2), create folders based on an acronym used in the file name (Chunk 3), create subfolders in the previous folders based on the numbers in the file name (Chunk 4), create a file in each of the subfolders that averages the data in those folders (Chunk 5), and finally create a graph of one of the averaged data sets to compare to a baseline dataset (which lives in a folder in the same space as those made in Chunk 3). Chunks 1-5 knit smoothly, but when I get to Chunk 6, it fails to knit the PDF and deletes the datafiles in the baseline dataset. Just running the script itself does not do this, it only seems to happen when attempting to knit to a PDF. I do have knitr::opts_chunk$set(echo = TRUE) in the beginning of the file. I get the error and script below:
Issue with Knitting RMarkdown Files After Updating R and RStudio: Error in comment_chars[[engine]] %||% “#”
After installing the new version of R and RStudio, there is an issue with knitting rmd files. I tried to knit even the rmd that appears automatically when you select the creation of a new rmd file in RStudio, but it also shows the error:
Rmarkdown to pdf fails to render, giving LaTeX Error: Command numberwithin undefined. Has anyone seen this problem and solved it?
I can no longer use RMarkdown to render pdfs. Rmarkdown continues to render to HTML and Word. I am working in Windows 11 and RStudio 2023.12.1 Build 402.