library(lodown)
# examine all available CENSO microdata files
censo_cat <-
get_catalog("censo" ,
output_dir = file.path(path.expand("~"), "CENSO"))
# 2010 only
censo_cat <- subset(censo_cat, year == 2010)
# download the microdata to your local computer
lodown("censo", censo_cat)
Gives the error
Error in read_SAScii_monetdb(this_dom, sas_ri = censo_sas(catalog[i, "dom_sas"]), :
Error in rsqlite_send_query(conn@ptr, statement) :
near "COPY": syntax error
In addition: Warning message:
Closing open result set, pending rows
I'm trying to run the proposed code for Brazilian Censo Demografico.
Running
Gives the error
in the very first file - ftp://ftp.ibge.gov.br/Censos/Censo_Demografico_2010/Resultados_Gerais_da_Amostra/Microdados/AC.zip
Session Info is:
Any hints on fixing this?