Learn R Programming

radtools (version 1.0.6)

img_data_to_3D_mat: Convert image data to 3D matrix of intensities

Description

Convert image data to 3D matrix of intensities

Usage

img_data_to_3D_mat(img_data, coord_extra_dim)

Arguments

img_data

Image data returned by e.g. read_dicom or read_nifti1

coord_extra_dim

Coordinates in extra dimensions (beyond 3) that define the particular 3D image of interest. Not applicable for DICOM; pass NULL in that case.

Value

3D array of intensities where third dimension is slice

Examples

Run this code
# NOT RUN {
data(sample_nifti_img)
img_data_to_3D_mat(sample_nifti_img)
# }
# NOT RUN {
img_data_to_3D_mat(nifti_data_4D, coord_extra_dim = 10)
# }

Run the code above in your browser using DataLab