|
1 | | -## Copyright (C) 2019 Qianqian Fang <q.fang@neu.edu> |
2 | | -## |
3 | | -## This program is free software; you can redistribute it and/or modify it under |
4 | | -## the terms of the GNU General Public License as published by the Free Software |
5 | | -## Foundation; either version 3 of the License, or (at your option) any later |
6 | | -## version. |
7 | | -## |
8 | | -## This program is distributed in the hope that it will be useful, but WITHOUT |
9 | | -## ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
10 | | -## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more |
11 | | -## details. |
12 | | -## |
13 | | -## You should have received a copy of the GNU General Public License along with |
14 | | -## this program; if not, see <http://www.gnu.org/licenses/>. |
| 1 | +%% Copyright (C) 2019 Qianqian Fang <q.fang@neu.edu> |
| 2 | +%% |
| 3 | +%% This program is free software; you can redistribute it and/or modify it under |
| 4 | +%% the terms of the GNU General Public License as published by the Free Software |
| 5 | +%% Foundation; either version 3 of the License, or (at your option) any later |
| 6 | +%% version. |
| 7 | +%% |
| 8 | +%% This program is distributed in the hope that it will be useful, but WITHOUT |
| 9 | +%% ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
| 10 | +%% FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more |
| 11 | +%% details. |
| 12 | +%% |
| 13 | +%% You should have received a copy of the GNU General Public License along with |
| 14 | +%% this program; if not, see <http://www.gnu.org/licenses/>. |
15 | 15 |
|
16 | | -## -*- texinfo -*- |
17 | | -## @deftypefn {Function File} {} niftiwrite (@var{img}, @var{filename}) |
18 | | -## @deftypefnx {Function File} {} niftiwrite (@var{img}, @var{filename}, @var{info}) |
19 | | -## @deftypefnx {Function File} {} niftiwrite (@var{img}, @var{filename}, @var{info},...) |
20 | | -## Write image data and metadata to a NIfTI-1/2 and Analyze7.5 formatted image file |
21 | | -## |
22 | | -## Writing the image data @var{img} and metadata @var{info} to a NIfTI-1 |
23 | | -## file or a two-part NIfTI or Analyze7.5 files specified by @var{filename}. |
24 | | -## The accepted file suffixes include .nii and .nii.gz. |
25 | | -## |
26 | | -## @seealso{niftiinfo, niftiread} |
27 | | -## @end deftypefn |
| 16 | +%% -*- texinfo -*- |
| 17 | +%% @deftypefn {Function File} {} niftiwrite (@var{img}, @var{filename}) |
| 18 | +%% @deftypefnx {Function File} {} niftiwrite (@var{img}, @var{filename}, @var{info}) |
| 19 | +%% @deftypefnx {Function File} {} niftiwrite (@var{img}, @var{filename}, @var{info},...) |
| 20 | +%% Write image data and metadata to a NIfTI-1/2 and Analyze7.5 formatted image file |
| 21 | +%% |
| 22 | +%% Writing image data @var{img} and metadata @var{info} to a NIfTI-1 |
| 23 | +%% file or a two-part NIfTI or Analyze7.5 files specified by @var{filename}. |
| 24 | +%% The accepted file suffixes include .nii and .nii.gz. |
| 25 | +%% |
| 26 | +%% @seealso{niftiinfo, niftiread} |
| 27 | +%% @end deftypefn |
28 | 28 |
|
29 | 29 | function niftiwrite (img, filename, varargin) |
30 | 30 |
|
@@ -64,7 +64,7 @@ function niftiwrite (img, filename, varargin) |
64 | 64 | endfunction |
65 | 65 |
|
66 | 66 | %!demo |
67 | | -%! ## Reading a |
| 67 | +%! %% Reading a |
68 | 68 | %! urlwrite('https://nifti.nimh.nih.gov/nifti-1/data/minimal.nii.gz','minimal.nii.gz') |
69 | 69 | %! gunzip ('minimal.nii.gz'); |
70 | 70 | %! header=niftiinfo('minimal.nii'); |
|
0 commit comments