Description Usage Arguments Value Author(s) See Also Examples
There exist 2 different ways to get an instantiated MincVolumeIO object: (1) create one as a result of loading a pre-existing minc volume, and (2) create an empty volume from scratch. This method deals with the second way.
1 2 3 4 5 6 7 8 9 10 | ## S4 method for signature 'character,numeric,numeric,numeric,missing,missing'
mincIO.makeNewVolume(filename,dimLengths,dimSteps,dimStarts,likeTemplate,likeFile)
## S4 method for signature
## 'character,missing,missing,missing,character,missing'
mincIO.makeNewVolume(filename,dimLengths,dimSteps,dimStarts,likeTemplate,likeFile)
## S4 method for signature
## 'character,missing,missing,missing,missing,character'
mincIO.makeNewVolume(filename,dimLengths,dimSteps,dimStarts,likeTemplate,likeFile)
|
filename |
The filename of the minc volume to be created. The name is only placed into the MincInfo header.
While no IO is actually performed as this time, the |
dimLengths |
A vector of 3 integers specifying the number of elements in the x, y, and z dimensions (in that order) |
dimSteps |
A vector of 3 doubles specifying the step size of elements in the x, y, and z dimensions (also in that order) |
dimStarts |
A vector of 3 doubles specifying the start offsets of elements in the x, y, and z dimensions (yet again in that order) |
likeTemplate |
In order to facilitate volume creation, rather than specifying all of the above arguments,
one can specify 1 of 3 volume templates whose characteristics are already known to the system. The 3
valid template names are: (1) |
likeFile |
One also has the option of specifying a “like” volume. The properties of the new volume shall then be set to match those of the “like” volume. |
An instantiated, empty, MincVolumeIO object that has been initialized to zeros.
Jim Nikelski nikelski@bic.mni.mcgill.ca
MincVolumeIO
mincIO.readVolume
mincIO.writeVolume
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | ## Not run:
\dontshow{
# clear debug flag and get full volume pathname
# ... dunno why zzz.R debug setting is not passed
R_DEBUG_rmincIO <- 1
volDir <- system.file("packageData/volumes", package="rmincIO")
}
# create from scratch
vol <- mincIO.makeNewVolume("mymakeNewVolume.mnc", dimLengths=c(128,128,80),
dimSteps=c(1.34, 1.72, 1.50),
dimStarts=c(-85.76, -126.08, -37.50))
# use a template
vol1 <- mincIO.makeNewVolume("myIcbmTemplateVolume.mnc", likeTemplate="icbm152")
vol2 <- mincIO.makeNewVolume("my305LinTemplateVolume.mnc", likeTemplate="mni305linear")
vol3 <- mincIO.makeNewVolume("my305PetTemplateVolume.mnc", likeTemplate="mni305PET")
# use a "like" volume
vol <- mincIO.makeNewVolume("myLikeVolume", likeFile="myOwnWackySampling.mnc")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.