wcalc: Calculate the column widths of a fixed-width file

wcalcR Documentation

Calculate the column widths of a fixed-width file

Description

Calculate column widths of a plain text fixed-width file from column numbers on which each field begins.

Usage

wcalc(p)

Arguments

p

numeric vector of column numbers, should start with 1 and end with the number of the last column in a file+1

Details

The first element of the p argument should be 1 as it is the first column of the first field. Subsequent numbers should correspond to the column numbers that begin other fields. The last number of p should be the end of the last field + 1 or, equivalently, the begining of the next (non-existing) field.

Value

Numeric vector of column widths.

Examples


# TODO add examples


mbojan/mbtools documentation built on Oct. 16, 2023, 8:18 p.m.