| analyzeheader.template | R Documentation |
This function returns a valid ANALYZE 7.5 header with all fields present, filled with the default
values of the format. You will most likely have to adapt at least the dim, datatype, bitpix and pix_dim
fields to your data, which is what analyzeheader.for.data does for you.
analyzeheader.template()
named list, the ANALYZE 7.5 header. The fields endian, magic, header_format and spm_origin are not
part of the ANALYZE 7.5 header: endian and magic describe how the file is stored, header_format tells
which variant of the 348 byte header this is ('analyze' or 'nifti1_pair'), and spm_origin is the
interpretation of the originator field that the SPM software uses.
The fields spm_origin and magic are derived when a file is read, they are documented in
read.analyze.header.
analyzeheader.for.data, read.analyze.header, write.analyze
analyzeheader <- analyzeheader.template()
analyzeheader$dim <- c(3L, 4L, 3L, 2L, 1L, 1L, 1L, 1L)
analyzeheader$pix_dim <- c(1., 1., 1., 1., 0., 0., 0., 0.)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.