Learn R Programming

SticsRFiles (version 1.7.0)

read_params_table: Getting parameters data from tables files (Excel sheet, csv)

Description

Getting parameters data from tables files (Excel sheet, csv)

Usage

read_params_table(file_path, sheet_name = NULL, num_na = "NA", char_na = "NA")

Value

A tibble of parameters

Arguments

file_path

Excel or csv file path (including name of the file)

sheet_name

Name of an Excel sheet (useless for csv files)

num_na

Replacement value for numerical NA values (default: NA)

char_na

Replacement value for character NA values (default: "")

Details

After data are loaded, numerical and string NA values are replaced respectively with num_na or char_na

Examples

Run this code

usm_xl_file <- download_usm_xl(
  file_name = "inputs_stics_example.xlsx",
  verbose = FALSE
)
read_params_table(usm_xl_file, sheet = "USMs")
usm_csv_file <- download_usm_csv(
  file = "inputs_stics_example_USMs.csv",
  stics_version = "V9.2"
)
read_params_table(file_path = usm_csv_file)

Run the code above in your browser using DataLab