timeShift | R Documentation |
Evaluate the time elapsed between two bounds (x1, x2) into a scaled domain given a rate model and condtions that represent its variables.
timeShift( x1, scaledPeriod, model, conditions, param = list(), control = list(), interpolation = "constant", assignConstant = "lower" )
x1 |
|
scaledPeriod |
|
model |
|
conditions |
|
param |
|
control |
|
interpolation |
|
assignConstant |
|
Note that x1
and the calculated x2
must be in the time range provided by conditions. See the details section of timescale
for the structure of conditions
and model
and the calculation.
Return a vector of the same length as x1
and x2
representing the scaled time elapsed between those values.
#Setting entries conditions <- data.frame(time = seq(0,50,length.out = 100), temp = rnorm(10, 10, 5)) model <- "modelLinear" param = list(a = 1, T0 = 10) x1 = seq(1,10,length.out = 10) scaledPeriod = rep(10,10) #Calculating x2 time values x2 <- timeShift(x1, scaledPeriod = scaledPeriod, model = model, conditions = conditions, param = param) x2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.