I\'m trying to automate the extraction of a number of files compressed with 7-zip. I need to automate this process, because a) there are many years of data I\'d like to unl
If you have 7z
executable in your path, you can simple use system
command
system('7z e -o <output_dir> <archive_name>')
This can be done with the archive package.
library(archive)
tf <- tempfile() ; td <- tempdir()
file.path <- "ftp://ftp.ibge.gov.br/Orcamentos_Familiares/Pesquisa_de_Orcamentos_Familiares_2008_2009/Microdados/Dados.zip"
download.file( file.path , tf , mode = "wb" )
archive(tf)
See https://github.com/jimhester/archive