weight_function {optedr}R 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.


[Package optedr version 2.0.0 Index]