qsurvival.nllik: Negative Log-Likelihood of a Survival Function

Description Usage Arguments Value Author(s) See Also Examples

View source: R/qsurvival.nllik.R

Description

Using a survival function on a specified distribution with a given set of parameters, computes the negative log-likelihood

Usage

1
qsurvival.nllik(dist, complete.lifespans, censored.lifespans, Q, ...)

Arguments

dist

A text description of the distribution to use, e.g. emg or norm

complete.lifespans

A vector of observations of complete lifespans

censored.lifespans

A vector of incomplete observations of lifespans

Q

The percent of population in quiescence or non-dividing

...

Specific parameters to the dist specified

Value

A numeric value of the negative log-likelihood for the given parameters.

Author(s)

Darren Tyson, Shawn Garbett

See Also

mle-class q.mle.norm.estimate q.mle.emg.estimate q.rates

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
  data(ca1d.erlotinib)
  mitotic.lifespans <-
    subset(ca1d.erlotinib, !End.of.Expt & 
                           !Death        & 
                           !is.na(Lifespan))$Lifespan
  censored.lifespans <- 
    subset(ca1d.erlotinib, End.of.Expt  & 
                           !Death        & 
                           !is.na(Lifespan))$Lifespan
                           
  mle(function(mean, sd, Q){
       qsurvival.nllik("norm", mitotic.lifespans, censored.lifespans, Q, mean, sd)
     },
     method='L-BFGS-B',
     lower=list(mean=8,  sd=0.1, Q=0.01),
     upper=list(mean=30, sd=20,  Q=0.9),
     start=list(mean=mean(mitotic.lifespans), 
                sd=sd(mitotic.lifespans),
                Q = 0.5))

fracprolif documentation built on May 2, 2019, 7:59 a.m.