logis.noise: Creating a nls model for logistic regression from fitted...

View source: R/logis.noise.R

logis.noiseR Documentation

Creating a nls model for logistic regression from fitted values of a glm model

Description

Adds some noise to the fitted values of a glm model to create a nls model for logistic regression (creating a nls model from exact fitted values can not be done, see help of nls).

Usage

logis.noise(model, intensity = 25)

Arguments

model

glm model.

intensity

intensity of the noise: lower the value, bigger the noise.

Author(s)

Maxime HERVE <maxime.herve@univ-rennes1.fr>

See Also

glm, nls

Examples

x <- 1:50
y <- c(rep(0,18),sample(0:1,14,replace=TRUE),rep(1,18))
model <- glm(y~x,family=binomial)
y2 <- logis.noise(model)
# Then model2 <- nls(y2~SSlogis(...))

RVAideMemoire documentation built on Nov. 6, 2023, 5:07 p.m.