Description Usage Arguments Value Note Author(s) See Also Examples
View source: R/KAT.checkData.R
Load your data into an R session and save as an RData file that can be analyzed by the KAT function. Also check that dimensions of vectors and arrays are consistent.
1 2 | KAT.checkData(file.name, vector.times, map.CC, mask.ROI, vector.AIF, map.tlag=NULL,
write.data.to.file=TRUE)
|
file.name |
Give a name to the RData file that will be generated with this
function. A |
vector.times |
The nt x 1 time vector; can have units of seconds or minutes. KAT
will automatically assign units based on the following
assumptions: units are minutes if tmax < 100 and seconds
if tmax >= 100. Please make sure that these
assumptions are consistent with your data. You will have to manually
convert the time vector into seconds or minutes prior to running |
map.CC |
The nx x ny x ns x nt contrast agent intensity/concentration array. |
mask.ROI |
The nx x ny x ns ROI mask array where voxels within the ROI are assigned a 1 and those outside assigned a 0. |
vector.AIF |
The nt x 1 arterial (vascular) input function. |
map.tlag |
The nx x ny x ns array that contains per-voxel tag times estimated outside of KAT, to be applied to the vascular input function. Units must be same as those used for vector.times. This argument is optional. |
write.data.to.file |
Should the original data, loaded into R, be saved in a single RData file for future use? Default=TRUE. NOTE: if set to FALSE, usage for this function must be exactly as follows: R> dcemri.data <- KAT.checkData(args) R> KAT(args) where the |
Returns an RData file that can be read by the KAT
function.
The KAT
function can also read data stored as an uncompressed MATLAB 5 file.
Gregory Z. Ferl
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ## Create temporary directory for benchmark example code output files
temp_dir <- tempdir(check=FALSE)
##
current_dir <- getwd()
setwd(temp_dir)
##
## Run example code
data(dcemri.data, package="KATforDCEMRI")
a1=dcemri.data$vectorTimes
a2=dcemri.data$mapCC
a3=dcemri.data$maskROI
a4=dcemri.data$vectorAIF
KAT.checkData("f",vector.times=a1,map.CC=a2,mask.ROI=a3,vector.AIF=a4,write.data.to.file=TRUE)
##
setwd(current_dir)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.