danicat / read.dbc

An R package for reading data in the DBC (compressed DBF) format used by DATASUS.
69 stars 29 forks source link

add stringsAsFactors = F functionality #6

Closed lucasmation closed 6 years ago

lucasmation commented 7 years ago

The package is great. For the SIM data, all the variables are imported as factor variables. It would be nice to add the "stringsAsFactors", so that people can turn that behavior off (stringsAsFactors = F)

michelbieleveld commented 6 years ago

This is already possible. Just supply as.is=TRUE as an additional parameter when you open the file;

read.dbc(filename, as.is=TRUE)

danicat commented 6 years ago

Thanks for that information @michelbieleveld. It has been a while since I last worked on it so I didn't remember that option. Since we are using read.dbf on the background (after decompression) any parameter allowed for read.dbf is also allowed for read.dbc.