rescale_continuous {edstan}R Documentation

Rescale continuous covariates as appropriate for edstan models

Description

This function scales a covariate to have a mean of zero and standard deviation of 0.5.

Usage

rescale_continuous(x)

Arguments

x

A numeric vector, matrix, or data frame

Value

A numeric vector, matrix, or data frame with rescaled covariates having mean of zero and standard deviation of 0.5.

Examples

vec <- rnorm(5, 100, 20)
rescale_continuous(vec)

mat <- matrix(rnorm(5*5, 100, 20), ncol = 5)
rescale_continuous(mat)

[Package edstan version 1.1.0 Index]