weight_function: Weight function per distribution

View source: R/utils.R

weight_functionR Documentation

Weight function per distribution

Description

Weight function per distribution

Usage

weight_function(model, char_vars, values, distribution = "Homoscedasticity")

Arguments

model

formula describing the model to use. Must use x as the variable.

char_vars

character vector with the parameters of the models, as written in the formula

values

numeric vector with the parameters nominal values, in the same order as given in parameters.

distribution

character variable specifying the probability distribution of the response. Can be one of the following:

  • 'Homoscedasticity'

  • 'Gamma', which can be used for exponential or normal heteroscedastic with constant relative error

  • 'Poisson'

  • 'Logistic'

  • 'Log-Normal' (work in progress)

Value

one variable function that represents the square of the structure of variance, in case of heteroscedastic variance of the response.


optedr documentation built on Nov. 18, 2022, 5:12 p.m.