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,
Method_weights = TRUE,
taper_weights = TRUE,
weightscheme = 2,
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. |
Method_weights |
If no weights provided, should the weights be divided by discrete and continuous samples equally (i.e. with more continuous samples, the continuous samples each get less weight). Default is TRUE. |
taper_weights |
If no weights provided, should the weights be tapered to gradually trade off between the continuous and discrete samples after the peak? |
weightscheme |
If no weights provided, which weighting scheme should be used before accommodating Method_divide and taper_weights? 1 represents a uniform weighting before accommodating Method_divide and taper_weights. 2 represents time/AIF as used by Columbia PET Centre. Default is 2. |
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.