impulse.start.single: Starting conditions for single sigmoid model

Description Usage Arguments Value

View source: R/impulse.R

Description

This function determines k sets of initial starting conditions for single sigmoid fitting by choosing combinations of points from the data randomly. h0 and h1 (initial and final values) are taken from points chosen at random from data with the highest and lowest y-axis values. t1 and b1 are then estimated from two randomly chosen points in the middle of the data (along the y-axis). If k is larger than the number of possible combinations that fit these conditions, additional sets of starting conditions are chosen totally randomly that fit within the bounds of the existing data with a small margin of padding.

Usage

1
impulse.start.single(x, y, k, h.frac = 0.2, l.frac = 0.2, interpolate = NULL)

Arguments

x

(Numeric vector) Expression data to fit (x)

y

(Numeric vector) Expression data to fit (y)

k

(Numeric) Number of starting conditions to determine

h.frac

(Numeric, 0 to 1) Portion of data (highest along y-axis) to use to estimate h0/h1

l.frac

(Numeric, 0 to 1) Portion of data (lowest along y-axis) to use to estimate h0/h1

interpolate

(Numeric or NULL) If low number of data points, can interpolate them linearly to this number of points. Default (NULL) does not do any interpolation.

Value

Returns a data frame of potential starting conditions for fitting functions for double sigmoid ("impulse") model


farrellja/URD documentation built on June 17, 2020, 4:48 a.m.