envi_files | R Documentation |
Management of ENVI files similar to functions of OS file manager.
envi_exists(pattern = ".+", path = ".", all.files = FALSE, full.names = TRUE,
recursive = FALSE, ignore.case = TRUE, exact = FALSE)
envi_list(pattern = ".+", path = ".", all.files = FALSE, full.names = recursive,
recursive = FALSE, ignore.case = TRUE, exact = FALSE)
envi_remove(pattern = ".+", path = ".", all.files = FALSE, full.names = recursive,
recursive = FALSE, ignore.case = TRUE, verbose = FALSE)
envi_copy(src, dst, overwrite = TRUE)
envi_rename(src, dst, overwrite = TRUE)
ursa_exists(fname)
pattern |
Either filename (like |
path |
Either path name (like |
all.files |
A logical value. If FALSE, only the names of visible files are returned. If TRUE, all file names will be returned. Similar to |
full.names |
A logical value. If TRUE, the directory path is prepended to the file names to give a relative file path. If FALSE, the file names (rather than paths) are returned. Similar to |
recursive |
Logical. Should the listing recurse into directories? Similar to |
ignore.case |
Logical. Should pattern-matching be case-insensitive? Similar to |
exact |
Logical. Attempt to cancel regular expressions. |
verbose |
Logical. |
src |
Strings of length 1 or more. Name or directory name or path of source ENVI files. |
dst |
Strings of length 1 or more. Name or directory name path of destination ENVI files. Length is assuming to be equal to length of |
overwrite |
Logical. |
fname |
Character. Full file name or file pattern with file path. |
Functions do not view content of any files. The major identifier of ENVI files in file system is ENVI header (*.hdr) file. Binary file is searching along 1) original *.envi, *.bin, *.img, *.dat extensions, 2) externally packing *.gz. *.bz2, *.xz extensions, or 3) packed by this package *.envigz, *.bingz extensions. Functions envi_copy()
and envi_rename()
keeps original extension of ENVI binary file; use file.rename
to rename ENVI binary file.
envi_exists()
returns integer number of found ENVI files.
envi_list()
returns character vector of found ENVI files.
envi_remove()
returns character vector of deleted ENVI files.
envi_copy()
returns 0L.
envi_rename()
returns value of file.rename
, which is applied to objects in file system.
ursa_exists()
returs TRUE
if any *.tif, *.tiff, *.bin, *.hfa file is found.
Nikita Platonov platonov@sevin.ru
session_grid(NULL)
wd <- setwd(tempdir())
a1 <- create_envi("tmp1.envi")
a2 <- create_envi("tmp2.")
close(a1,a2)
envi_list()
envi_copy("tmp1","tmp3")
envi_copy("tmp2","tmp4")
envi_list()
envi_rename("tmp3","tmp5")
envi_list()
envi_exists("nofilewithsuchname")
envi_exists("tmp[34]")
envi_remove(".+")
envi_list()
setwd(wd)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.