# loading of toy-patient objects (decrease dxyz and increase beam.nb for better
# result)
step <- 4
patient <- toy.load.patient (modality = "rtdose", roi.name = "",
dxyz = rep (step, 3), beam.nb = 3)
D <- patient$rtdose[[1]]
# voxels location where the dose is greater than 99.9% Dmax
Dmax <- max (D$vol3D.data, na.rm = TRUE) # D$max.pixel
get.xyz.from.index (which (D$vol3D.data >= 0.99 * Dmax), D)
# or
get.xyz.from.index (which (D$vol3D.data >= 0.99 * Dmax, arr.ind = TRUE), D)
Run the code above in your browser using DataLab