knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)

lhmetools

Travis build status Codecov test coverage

The goal of {lhmetools} is to bundle all generic functions frequently used in LHMET.

System requirements

To extract files from a rar archive we have created the function unrar(). This function allows extract files using unrar[^1] tool from the command line. unrar tool can be installed using your Linux distributions' package manager.

$ sudo apt update && sudo apt install --assume-yes unrar # Ubuntu and Debian

Windows users should install the 7-zip, a free software that can be easily installed from R using installr::install.7zip().

install.packages("installr") # only for windows
install.7zip()

[^1]: It's developed by RARLAB and made available in Linux and other Unix based operating systems.

Installation

You can install {lhmetools} from GitHub with:

# install.packages("devtools")
devtools::install_github("lhmet/lhmetools")

List of funcions

This is a basic example which shows you how to extract files:

library(lhmetools)
## basic example code
rarfile_url <- "https://ndownloader.figshare.com/files/13366451"
dest_file <- tempfile(fileext = ".rar")
download.file(rarfile_url, dest_file, mode = 'wb')
(extracted_files <- unrar(dest_file))


lhmet/lhmetools documentation built on July 26, 2024, 1:48 p.m.