getEstimates: Function to Estimate x Given y.

Description Usage Arguments Details Value Warning Note Author(s) See Also Examples

Description

This function takes as its first argument a model returned by nplr(). By inverting the logistic model, it estimates the x values corresponding to one (or a vector of) y target(s) provided. The standard error of the model, defined as the mean squared error on the fitted values, is used to estimate a confidence interval on the predicted x values, according to the specified conf.level. see Details.

Usage

1
2
  ## S4 method for signature 'nplr'
getEstimates(object, targets = seq(.9, .1, by = -.1), B = 1e4, conf.level = .95)

Arguments

object

: an object of class nplr.

targets

: one, of a vector of, numerical value(s) for which the corresponding x has to be estimated. Default are target values from .9 to .1.

B

: the length of the y distribution from which the x confidence interval is estimated.

conf.level

: the estimated x confidence interval, bounded by (1-conf.level)/2 and 1 - (1-conf.level)/2 (by default .95, which gives x.025 and x.975).

Details

In n-parameter logistic regressions, none of the parameters follow any particular distribution from which confidence intervals can be estimated. To overcome this issue, the standard error is used to generate a normal distribution of the target(s) passed to the function. The quantiles of that distribution are used in order to provide estimated bounds for the corresponding x value, with respect to conf.level. See also Warning.

Value

A data set containing:

y

: the target value.

x.05

: the lower bound of the estimated 95% confidence interval (default). If another value is passed to conf.level, x will be labelled as x.(1-conf.level)/2.

x

: the estimated value.

x.95

: the upper bound of the estimated 95% confidence interval (default). If another value is passed to conf.level, x will be labelled as x.1-(1-conf.level)/2.

Warning

Notice that, if any target<=B or target>=T, in other words outside the 2 asymptotes, the maximal (or minimal) possible value the model can estimates is returned.

Note

The data used in the examples are samples from the NCI-60 Growth Inhibition Data: https://wiki.nci.nih.gov/display/NCIDTPdata/NCI-60+Growth+Inhibition+Data, except for multicell.tsv which are simulated data.

Author(s)

Frederic Commo, Brian M. Bot

See Also

nplr, plot.nplr, , nplrAccessors

Examples

1
2
3
4
5
6
7
# Using the PC-3 data
  require(nplr)
  path <- system.file("extdata", "pc3.txt", package="nplr")
  pc3 <- read.delim(path)
  model <- nplr(x = pc3$CONC, y = pc3$GIPROP)
  getEstimates(model)
  getEstimates(model, c(.3, .6), conf.level = .9)

Example output

Testing pars...
The 5-parameters model showed better performance
    y        x.025            x        x.975
1 0.9 1.913337e-07 3.181425e-07 4.523117e-07
2 0.8 4.707413e-07 6.223618e-07 7.860367e-07
3 0.7 8.197975e-07 1.017702e-06 1.256111e-06
4 0.6 1.297772e-06 1.593305e-06 1.959833e-06
5 0.5 2.020452e-06 2.522415e-06 3.143087e-06
6 0.4 3.327136e-06 4.219737e-06 5.533948e-06
7 0.3 5.790696e-06 7.916255e-06 1.131965e-05
8 0.2 1.203604e-05 1.873892e-05 3.172580e-05
9 0.1 3.595525e-05 8.030163e-05 2.906545e-04
    y         x.05            x         x.95
1 0.3 6.106426e-06 7.916255e-06 1.050592e-05
2 0.6 1.348081e-06 1.593305e-06 1.886003e-06

nplr documentation built on May 2, 2019, 9:27 a.m.