scale_do: Alternative scale Methods

View source: R/scale_do.R

scale_doR Documentation

Alternative scale Methods

Description

Alternative scale using median, IQR and mad.

Usage

scale_do(x, center, scale)

Arguments

x

numeric vector

center

function

scale

function

Details

Function scale_do() performs scaling according to user-specified definition of center and scale.

Value

Function scale_do() returns a numeric vector of the same length as x.

Examples

set.seed(1315); x = rnorm(20)
x |> scale_do(center = median, scale = mad) 
x |> scale_do(center = median, scale = IQR) 

hyper.gam documentation built on June 8, 2025, 10:41 a.m.