header_to_fwf_position: Converts header line into a vector of column names

View source: R/header_to_fwf_position.R

header_to_fwf_positionR Documentation

Converts header line into a vector of column names

Description

Converts header line into a vector of column names

Usage

header_to_fwf_position(
  header,
  left_justified = "EXCODE",
  col_types = NULL,
  col_names = NULL,
  read_only = NULL
)

Arguments

header

A length-one character vector of a header line from a DSSAT format output file

left_justified

A character vector of column names that should be left justified

Value

a tibble containing the begin position, end position, and name for each column from the original header line

Examples


header_line <-
  "@YEAR DOY   DAS   SRAA    ES1D    ES2D    ES3D    ES4D    ES5D    ES6D    ES7D    ES8D"
DSSAT:::header_to_fwf_position(header_line)

DSSAT documentation built on Nov. 9, 2023, 1:08 a.m.