VerifyColSpecFormat: VerifyColSpecFormat

View source: R/VerifyColSpecFormat.R

VerifyColSpecFormatR Documentation

VerifyColSpecFormat

Description

VerifyColSpecFormat

Usage

VerifyColSpecFormat(ColSpec, Required = FALSE)

## Default S3 method:
VerifyColSpecFormat(ColSpec)

## S3 method for class 'col_spec'
VerifyColSpecFormat(ColSpec)

## S3 method for class 'tbl_df'
VerifyColSpecFormat(ColSpec)

## S3 method for class 'list'
VerifyColSpecFormat(ColSpec)

Arguments

ColSpec

A column specification.

Required

Causes an error if the column specification is required but not valid (TRUE/FALSE).

Value

A valid column specification in the format of a col_spec class that the import module can handle.

Methods (by class)

  • VerifyColSpecFormat(default): Default method throws an error to ignore unspecified data types.

  • VerifyColSpecFormat(col_spec): Handle col_spec objects and simply returns the object itself.

  • VerifyColSpecFormat(tbl_df): Specific method to handle tibble objects.

  • VerifyColSpecFormat(list): Specific method to handle lists. It converts the information from the list into a valid col_spec object.

See Also

readr::cols_condense()


SigurdJanson/shinyCSVImpoMod documentation built on Jan. 5, 2023, 3:57 a.m.