Constructs paths to your project's files. Declare the relative path of a file within your project with 'i_am()'. Use the 'here()' function as a drop-in replacement for 'file.path()', it will always locate the files relative to your project root.
A simple interface to
The logic to find a project root based on certain criteria is packaged in the
rprojroot package. Many projects might not need the full power, and the complexity that comes with it. Meet
library(here)here()#>  "/home/muelleki/git/R/here"here("DESCRIPTION")#>  "/home/muelleki/git/R/here/DESCRIPTION"here("R", "here.R")#>  "/home/muelleki/git/R/here/R/here.R"
here isn't on CRAN yet, install from GitHub via
Initial CRAN release.
.herefile or can be either an RStudio project, an R package, a
remakeproject, a Projectile project, or a VCS repository.
set_here()function creates a
.herefile so that a directory is recognized as root by
dr_here()function explains the reasoning of
here()for the current session.