Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

FactorToBinary

Converts a Factor into its indicator matrix


Description

Converts a factor into a binary matrix with as many columns as categories of the factor.

Usage

FactorToBinary(y, Name = NULL)

Arguments

y

A factor.

Name

Name to use in the final matrix.

Value

An indicator binary matrix.

Author(s)

Jose Luis Vicente-Villardon

Examples

y=factor(c(1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 2, 2, 2, 1, 1, 1))
FactorToBinary(y)

PERMANOVA

Multivariate Analysis of Variance Based on Distances and Permutations

v0.1.0
GPL (>= 2)
Authors
Laura Vicente-Gonzalez, Jose Luis Vicente-Villardon
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.