ajdamico / lodown

locally download and prepare publicly-available microdata
GNU General Public License v3.0
97 stars 47 forks source link

PNAD-Contínua lodown #152

Closed brunolucian closed 10 months ago

brunolucian commented 5 years ago

Hi,

I am trying to download PNAD-Contínua using lodown package with the query below:

pnadc_cat <- get_catalog( "pnadc" , output_dir = file.path( path.expand( "~" ) , "PNADC" ) ) pnadc_cat <- subset( pnadc_cat , year == 2018 & quarter == '03' ) pnadc_cat <- lodown( "pnadc" , pnadc_cat )

Before the error, R trys 10 times to download and it keeps giving the message as follow:

download issue with 'ftp://ftp.ibge.gov.br/Trabalho_e_Rendimento/Pesquisa_Nacional_por_Amostra_de_Domicilios_continua/Trimestral/Microdados/Documentacao/Dicionario_e_input_20181114.zip'

The error log is this:

Error in httr_filesize(this_url, attempts, sleepsec) : httr::HEAD( 'ftp://ftp.ibge.gov.br/Trabalho_e_Rendimento/Pesquisa_Nacional_por_Amostra_de_Domicilios_continua/Trimestral/Microdados/Documentacao/Dicionario_e_input_20181114.zip' ) failed after 10 attempts year quarter interview 26 2018 03

When I put this address at google Chrome it download correctly. Do you think that there is something else I might be trying?

My sessionInfo():

R version 3.5.1 (2018-07-02) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows >= 8 x64 (build 9200)

Matrix products: default

locale: [1] LC_COLLATE=Portuguese_Brazil.1252 [2] LC_CTYPE=Portuguese_Brazil.1252
[3] LC_MONETARY=Portuguese_Brazil.1252 [4] LC_NUMERIC=C
[5] LC_TIME=Portuguese_Brazil.1252

attached base packages: [1] stats graphics grDevices utils datasets methods
[7] base

other attached packages: [1] lodown_0.1.0

loaded via a namespace (and not attached): [1] httr_1.4.0 compiler_3.5.1 R6_2.4.0 tools_3.5.1
[5] RCurl_1.95-4.12 yaml_2.2.0 curl_3.3 digest_0.6.18
[9] bitops_1.0-6

alexandrefreitas92 commented 5 years ago

I'm having the same problem with censo.

brunolucian commented 5 years ago

@ajdamico could you help me here, i'm still with this problem. I try PNADC and CENSUS, same problem in both cases.

ajdamico commented 10 months ago

hi! apologies for the long delay. i've made a couple of big updates to asdfree.com that hopefully make the website a bit better, but i've decided to stop maintaining the lodown package so probably won't fix the bug you've reported. the new asdfree does have pnadc data, but only for the most current year. thanks