as_data_file: Return the data file name corresponding to the given...

Description Usage Arguments Examples

View source: R/scmake.R

Description

If ind_file does not have the indicator extension, an error will be generated.

Usage

1
as_data_file(ind_file, ind_ext = getOption("scipiper.ind_ext"))

Arguments

ind_file

the indicator name (with path as needed) whose corresponding data file name should be returned

ind_ext

the indicator file extension to expect at the end of ind_file

Examples

1
2
3
4
5
6
as_data_file('mydata.rds.ind') # 'mydata.rds'
as_data_file('mydata.rds.st', ind_ext='st') # 'mydata.rds'
## Not run: 
as_data_file('mydata.rds') # Error: "ind_file is not an indicator file"

## End(Not run)

USGS-R/scipiper documentation built on Aug. 14, 2018, 5:23 a.m.