shared.path: Access Shared Path from Box Drive for Mojave Users

View source: R/box_paths_allyn.R

shared.pathR Documentation

Access Shared Path from Box Drive for Mojave Users

Description

This function creates paths to shared Data and Functions folders stored either inside the Mills Lab folder or outside the Mills Lab folder in other top level locations on box.

Usage

shared.path(
  os.use = "unix",
  group = c("RES Data", "Mills Lab", "Climate Change Ecology Lab", "NSF OKN", "root"),
  folder = "Functions/",
  user.name = NULL
)

Arguments

os.use

Character string defining operating system. Either "unix"/"mac" or "windows"

group

Character string of top-level directory within box to open. Ex. Box/RES_Data Either RES (things shared across the entire research department) or Mills Lab (things shared within the Mills Lab). Additional shortcuts are NSF OKN for knowledge graph data resources and root for the minimal path to box.

folder

Sub-folder within box you wish to access

user.name

User name needed to set root directory for Windows users

Value

path.out Path to shared folder. We will then use these paths within shared code to load shared data or source shared functions.

Examples

# res.data.path<- shared.path(os.use = os.use, group = "RES", folder = "Data/")

# Not Run
# gom.shapefile<- st_read(paste0(res.data.path, "Shapefiles/GoM_sf.shp"))

gulfofmaine/gmRi documentation built on Jan. 26, 2025, 5:12 a.m.