sat_untarzip {satres} | R Documentation |
Unzip compressed files in tar or zip format
Description
Given a vector of compressed file names or the name of a folder containing compressed files, unzip the files to the given output folder. If no output folder is indicated, it is considered the same folder where the input files are.
Usage
sat_untarzip(
file,
out_dir = NULL,
include_filename = NULL,
only_show_files = FALSE
)
Arguments
file |
A string or string vector. |
out_dir |
A string or string vector, output folder. |
include_filename |
A boolean, include file name as a folder in the output. |
only_show_files |
A boolean, only show the files that would be unzipped, and the destination folders, not unzip them. |
Details
We can indicate whether to include the file name (without the extension) as a folder in the output folder.
Value
A vector of strings, name of the processed files.
See Also
Examples
f <- system.file("extdata", package = "satres")
r <- sat_untarzip(f, only_show_files = TRUE)
f1 <- system.file("extdata", "satres.zip", package = "satres")
f2 <- system.file("extdata", "satres.tar", package = "satres")
r <- sat_untarzip(c(f1, f2), only_show_files = TRUE)
[Package satres version 1.1.1 Index]