Learn R Programming

⚠️There's a newer version (1.7.30) of this package.Take me there.

wsrf: An R Package for Scalable Weighted Subspace Random Forests

The wsrf is a parallel implementation of the Weighted Subspace Random Forest algorithm (wsrf) of \cite{xu2012classifying}. A novel variable weighting method is used for variable subspace selection in place of the traditional approach of random variable sampling. This new approach is particularly useful in building models for high dimensional data---often consisting of thousands of variables. Parallel computation is used to take advantage of multi-core machines and clusters of machines to build random forest models from high dimensional data with reduced elapsed times.

Documentation & Examples

The package ships with a PDF vignette including more details and a few examples.

Installation

Currently, wsrf requires R (>= 3.0.0), Rcpp (>= 0.10.2). For the use of multi-threading, a C++ compiler with C++11 standard support of threads or the Boost C++ library with version above 1.54 is required. The choice is available at installation time depending on what is available to the user. To install the latest version of the package, from within \proglang{R} run:

install.packages("wsrf", type = "source", configure.args = "--enable-c11=yes")

The latest GCC supports C++11, and if C++11 is not available or the Operating System you want to run wsrf is Windows:

install.packages("wsrf", type = "source", configure.args = "--enable-c11=no")

or just:

install.packages("wsrf")

Finally if you want to use Boost for multithreading, wsrf can be installed with the appropriate configuration options:

install.packages("wsrf",
                 type = "source",
                 configure.args = "--with-boost-include=<Boost include path>
                                   --with-boost-lib=<Boost lib path>")

A useful function wsrfParallelInfo() can be used for checking parallelism is used or not.

License

GPL (>= 2)

Copy Link

Version

Install

install.packages('wsrf')

Monthly Downloads

399

Version

1.5.47

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

He Zhao

Last Published

July 11th, 2016

Functions in wsrf (1.5.47)

combine.wsrf

Combine Ensembles of Trees
predict.wsrf

Predict Method for wsrf Model
oob.error.rate.wsrf

Out-of-Bag Error Rate
strength.wsrf

Strength
varCounts.wsrf

Number of Times of Variables Selected as Split Condition
subset.wsrf

Subset of a Forest
print.wsrf

Print Method for wsrf model
wsrf

Build a Forest of Weighted Subspace Decision Trees
correlation.wsrf

Correlation
importance.wsrf

Extract Variable Importance Measure
wsrfParallelInfo

Query about underlying parallel implementation information