Reads a SEER fixed width file using the column dictionary in the provided SAS file (see seer_read_col_positions() for more details). Note that the results are the raw data reported by SEER with no transformations -- all fields are imported as character strings by default. You can change this by specifying the col_types argument using readr column specification via readr::cols(), or you can set col_types = NULL to let readr guess the column type.

seer_read_fwf(file, col_positions = seer_read_col_positions(), ...,
  col_types = readr::cols(.default = readr::col_character()))

Arguments

file

Path to SEER fixed width file.

col_positions

SEER column positions, see seer_read_col_positions().

...

Arguments passed on to readr::read_fwf

locale

The locale controls defaults that vary from place to place. The default locale is US-centric (like R), but you can use locale() to create your own locale that controls things like the default time zone, encoding, decimal mark, big mark, and day/month names.

na

Character vector of strings to use for missing values. Set this option to character() to indicate no missing values.

comment

A string used to identify comments. Any text after the comment characters will be silently ignored.

skip

Number of lines to skip before reading data.

n_max

Maximum number of records to read.

guess_max

Maximum number of records to use for guessing column types.

progress

Display a progress bar? By default it will only display in an interactive session and not while knitting a document. The display is updated every 50,000 values and will only display if estimated reading time is 5 seconds or more. The automatic progress bar can be disabled by setting option readr.show_progress to FALSE.

col_types

Specification for column types, default is to return all as character strings. Use NULL to rely on readr or see readr::read_fwf() for further details.