View source: R/kinfitr_srtm_v.R
plot_srtm_vfit | R Documentation |
Function to visualise the fit of the SRTM_V model to data.
plot_srtm_vfit(srtmvout, roiname = NULL, refname = NULL)
srtmvout |
The output object of the SRTM fitting procedure. |
roiname |
Optional. The name of the Target Region to see it on the plot. |
refname |
Optional. The name of the Reference Region to see it on the plot. |
A ggplot2 object of the plot.
Granville J Matheson, mathesong@gmail.com
# Note: Reference region models, and irreversible binding models, should not
# be used for PBR28 - this is just to demonstrate function
data(pbr28)
t_tac <- pbr28$tacs[[2]]$Times / 60
reftac <- pbr28$tacs[[2]]$CBL
roitac <- pbr28$tacs[[2]]$STR
weights <- pbr28$tacs[[2]]$Weights
input <- pbr28$input[[2]]
newvals <- shift_timings(
t_tac,
roitac,
input,
inpshift = 0
)
bloodtac <- pracma::interp1(newvals$input$Time, newvals$input$Blood, t_tac)
fit <- srtm_v(t_tac, reftac, roitac, bloodtac, weights)
plot_srtm_vfit(fit)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.