blood_weights_create: Create Weights for Modelling Whole Blood and AIF Data

View source: R/kinfitr_bloodfuncs.R

blood_weights_createR Documentation

Create Weights for Modelling Whole Blood and AIF Data

Description

Create Weights for Modelling Whole Blood and AIF Data

Usage

blood_weights_create(
  time,
  activity,
  Method = NULL,
  Method_weights = TRUE,
  taper_weights = TRUE,
  weightscheme = 2
)

Arguments

time

The time of each measurement.

activity

The radioactivity of each measurement.

Method

Optional. The method of collection, i.e. "Discrete" or "Continuous".

Method_weights

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

Should the weights be tapered to gradually trade off between the continuous and discrete samples after the peak?

weightscheme

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.

Value

A vector of model weights

Examples

blooddata <- pbr28$blooddata[[1]]
aif <- bd_extract(blooddata, output = "AIF")
blood_weights_create(aif$time, aif$aif, aif$Method)

mathesong/kinfitr documentation built on Nov. 27, 2024, 1:38 a.m.