timeModelIntegral | R Documentation |
Compose the function of the model and the functions representing its variables, condModel a list a function reprensenting each variables.
timeModelIntegral( model, conditions, param = list(), control = list(), interpolation = "constant" )
model |
|
conditions |
|
param |
|
control |
|
interpolation |
|
Return a new function that only depend on time (represented as x
).
#Example of the integral of a rate model in function of time conditions <- data.frame(time = seq(0,30,length.out = 10), temp = rnorm(10, 10, 5)) model <- "modelLinear" param = list(a = 1, T0 = 10) #Get the function representing the integral of the model, can be evaluated at any time within those of conditions g <- timeModelIntegral(model, conditions, param) x <- seq(0,30,length.out = 20) g(x) #Plot x <- seq(0,30,length.out = 1000) g <- timeModelIntegral(model, conditions, param) plot(conditions$time,g(conditions$time)) lines(x,g(x))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.