Diff for "DBedit" - MRC CBU Imaging Wiki
location: Diff for "DBedit"
Differences between revisions 4 and 5
Revision 4 as of 2006-10-12 14:50:19
Size: 1316
Editor: devel03
Comment:
Revision 5 as of 2013-03-07 21:23:55
Size: 1317
Editor: localhost
Comment: converted to 1.6 markup
Deletions are marked like this. Additions are marked like this.
Line 7: Line 7:
To compile on Windows, get hold of the [http://sources.redhat.com/cygwin/ Cygwin utilities and gcc compiler] - see the [http://gnumex.sourceforge.net Cygwin / mex file] page for some tips that may be relevant. Then compile with the command line (which expects Cygwin to be on your path): To compile on Windows, get hold of the [[http://sources.redhat.com/cygwin/|Cygwin utilities and gcc compiler]] - see the [[http://gnumex.sourceforge.net|Cygwin / mex file]] page for some tips that may be relevant. Then compile with the command line (which expects Cygwin to be on your path):
Line 11: Line 11:
dbedit shows and sets fields in the [wiki:FormatAnalyze Analyze] header from the command line. The usage is: dbedit shows and sets fields in the [[FormatAnalyze|Analyze]] header from the command line. The usage is:

dbedit

dbedit is a program written by John Ashburner a long time ago, that he has kindly given us permission to distribute. You can get the source, and Sun / Windows binaries at http://imaging.mrc-cbu.cam.ac.uk/downloads/Dbedit/dbedit.tar.gz. To compile on Unix, run the command:

gcc -o dbedit dbedit.c anautils.c

To compile on Windows, get hold of the Cygwin utilities and gcc compiler - see the Cygwin / mex file page for some tips that may be relevant. Then compile with the command line (which expects Cygwin to be on your path):

gcc -mno-cygwin -o dbedit.exe dbedit.c anautils.c

dbedit shows and sets fields in the Analyze header from the command line. The usage is:

dbedit file.hdr atr1 [=val1] |all [atr2 [=val2] [atr3 [=val3] ..]]

To see all the possible fields in a header, and the names that dbedit uses, type:

dbedit

To see all the values of the fields in a particular analyze header:

dbedit myfile.hdr all

To set a field in a header, such as the size of the voxel dimensions in Z:

dbedit myfile.hdr "dime.pixdim [3] =5"

(the inverted commas are needed to hide the square brackets from the Unix shell)

Matthew Brett 24/1/01

CbuImaging: DBedit (last edited 2013-03-07 21:23:55 by localhost)