This application takes a Priism file and writes it out as a file in CCP4's native format.
mrc2ccp4 has the standard set of Priism controls for selecting a subset of the Priism file to convert. For the conversion, enter the name of the file to be generated in the "Output file" field. If the input file uses floating-point values or complex floating-point values to represent the data, mrc2ccp4 can perform the conversion in place (in other words, the output file name can be the same as the input file name); otherwise, the output file name must be different than the input file name. By default, mrc2ccp4 will generate a file using the native byte ordering for the operating system and machine where you run mrc2ccp4. To generate a file with the non-native byte ordering, turn on the "swap bytes" toggle button.
mrc2ccp4 by default does not set a skew transformation in the header of the CCP4 file. If you turn on the "include skew" toggle button, mrc2ccp4 will include the skew transformation calculated from the rotation angles and origin in the Priism file's header: consult the "Include Skew" topic for details about the transformation.
mrc2ccp4 will only convert the first wavelength and time point that you select. mrc2ccp4 will not transfer the wavelength information from the Priism header. It only transfers the extended header if the extended header appears to contain symmetry information (i.e. the space group field in the header is not zero).
Overview | Region processing | Output file | Swap bytes | Include skew | Command line
Enter the name of the CCP4 file to generate in the field next to the "Output file" button or use the "Output file" button to select the file with a file selection dialog. As currently implemented, mrc2ccp4 will allow the input file and the output file to be the same (i.e. the conversion is performed in place) if the input file uses floating-point or complex floating-point values to represent the data.
By default, mrc2ccp4 generates CCP4 files in the native byte ordering for the machine and operating system where you run mrc2ccp4. To generate a file with the non-native byte ordering, turn on the "swap bytes" toggle button.
By default, mrc2ccp4 does not set a skew transformation in the header of the CCP4 file. If you turn on the "include skew" toggle button, mrc2ccp4 will include a transformation matrix and translation vector in the header. The transformation matrix entries (s11, s12, ...) will be the product of three matrices as given by:
[ s11 s12 s13 ] [ 1 0 0 ] [ cos(b) 0 sin(b) ] [ cos(g) -sin(g) 0 ] [ s21 s22 s23 ] = [ 0 cos(a) -sin(a) ] [ 0 1 0 ] [ sin(g) cos(g) 0 ] [ s31 s32 s33 ] [ 0 sin(a) cos(a) ] [ -sin(b) 0 cos(b) ] [ 0 0 1 ]
where a, b, and g are the 4-byte floating-point values, in units of degrees, at bytes 185 through 188, 189 through 192, and 193 through 196, respectively in the Priism header. The translation will be the product of the inverse of the S matrix times the origin values in the Priism header (o1, o2, and o3 are the 4-byte floating-point values at bytes 213 through 216, 217 through 220, and 209 through 212, respectively):
[ t1 ] [ cos(g) sin(g) 0 ] [ cos(b) 0 -sin(b) ] [ 1 0 0 ] [ o1 ] [ t2 ] = [ -sin(g) cos(g) 0 ] [ 0 1 0 ] [ 0 cos(a) sin(a) ] [ o2 ] [ t3 ] [ 0 0 1 ] [ sin(b) 0 cos(b) ] [ 0 -sin(a) cos(a) ] [ o3 ]
The matrix and translation are intended to be consistent with Priism's geometric conventions: like those conventions, they do not take into account nonorthogonal coordinate axes.
mrc2ccp4 accepts the command-line arguments described in Region.html. In addition, it has the following options:
-out=n
-swab
-skew
The example below extracts a 160 x 160 x 160 region from a.dat and writes it to a.ccp4 in the non-native byte ordering.
mrc2ccp4 a.dat -x=0:159 -y=0:159 -z=0:159 -out=a.ccp4 -swab