View source: R/kinfitr_bloodmodels.R
blmod_splines | R Documentation |
Fits two or three (if both discrete and continuous) splines to blood or AIF data to smooth it
blmod_splines(
time,
activity,
Method = NULL,
weights = NULL,
bs_before = "cr",
bs_after_c = "cr",
bs_after_d = "cr",
k_before = -1,
k_after_c = -1,
k_after_d = -1
)
time |
The time of each measurement in seconds |
activity |
The radioactivity of each measurement |
Method |
Optional. The method of collection, i.e. "Discrete" or "Continuous" |
weights |
Optional. Weights of each measurement. |
bs_before |
Optional. Defines the basis function for the points before the peak. |
bs_after_c |
Optional. Defines the basis function for the continuous points after the peak. |
bs_after_d |
Optional. Defines the basis function for the discrete points after the peak. |
k_before |
Optional. Defines the dimension of the basis for the points before the peak. |
k_after_c |
Optional. Defines the dimension of the basis for the continuous points after the peak. |
k_after_d |
Optional. Defines the dimension of the basis for the discrete points after the peak. |
A model fit including all of the individual models of class blood_splines.
blooddata <- pbr28$blooddata[[1]]
blooddata <- bd_blood_dispcor(blooddata)
blood <- bd_extract(blooddata, output = "Blood")
blood_fit <- blmod_splines(blood$time,
blood$activity,
Method = blood$Method)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.