Output .pdf does not exist - error when i knit my rmd file to pdf
I realised my error was that I had not installed a tex software. I accomplished this by running the install.package(tinytex)
command and the install_tinytex()
function to have the tex software for use with r-markdown installed
R rgdal::readOGR issue with file path refering to linux home directory
you can either use tools::file_path_as_absolute()
like this:
library(tools)
readOGR(file_path_as_absolute('~/documents/zipcodes'), 'zipcodes')
or
path.expand()
as hrbrmstr mentioned in his comment:
readOGR(path.expand('~/documents/zipcodes'), 'zipcodes')
Another, more inconvenient way would be to use base::dirname()
in combination with paste0()
:
readOGR(paste0(dirname('~/documents/zipcodes'), 'zipcodes'), 'zipcodes')
Related Topics
Saving and Loading a Model in R
Shinydashboard Some Font Awesome Icons Not Working
R Shiny Table Not Rendering HTML
R: Eval(Parse(...)) Is Often Suboptimal
Ggplot Custom Scale Transformation with Custom Ticks
Converting Data Frame Column from Character to Numeric
Horizontal Dendrogram in R with Labels
Non-Numeric Argument to Binary Operator Error in R
Selecting a Subset of Columns in a Data.Table
Propagating Data Within a Vector
Warning Message: Line Appears to Contain Embedded Nulls