R/minc_voxel_statistics.R
mincApplyRCPP.Rd
An RCPP variant of mincApply, the primary advantage being that functions of an arbitrary number of arguments can be passed to mincApplyRCPP.
mincApplyRCPP(filenames, fun, ..., mask = NULL, maskval = NULL, filter_masked = FALSE, slab_sizes = c(1, 1, 1), return_indices = FALSE, collate = simplify2minc)
filenames | The name of the files to apply over |
---|---|
fun | the function to apply |
... | additional parameters to fun |
mask | a numeric mask vector |
maskval | An integer specifying the value inside the mask where to apply the function. If left blank (the default) then anything above 0.5 will be considered inside the mask. This argument only works for mincApply, not pMincApply. |
filter_masked | Whether or not to remove the masked values from the resultant object |
slab_sizes | a three element numeric vector indicating the size in voxels of the hyperslab to read for each file. Useful for managing memory use - larger slabs are faster but require more memory. Sizes must be an even factor of their respective volume dimensions. |
return_indices | Whether to return the voxel positions of the results generally for internal use only. |
collate | A function to (potentially) collapse the result list
examples include linkunlist and simplify2array, defaulting
to simplify2minc which creates an object of type |
a list of results subject the the collate function