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

contr.simplex

Orthonormal Contrast Generator


Description

Generates orthonormal (orthogonal and normalized) contrasts. Each row is the vertex of an N-dimensional simplex. The only exception are contrasts for the 2-level case, which return 1 and -1.

Usage

contr.simplex(n, size = NULL)

Arguments

n

The number of levels in the catagorical variable.

size

Default '1'. The length of the simplex vector.

Value

A matrix of Orthonormal contrasts.

Examples

contr.simplex(4)

skpr

Design of Experiments Suite: Generate and Evaluate Optimal Designs

v0.66.5
GPL-3
Authors
Tyler Morgan-Wall [aut, cre], George Khoury [aut]
Initial release

We don't support your browser anymore

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