## Simple Bsoft command lines

Every program that can read and write images, can be used as a conversion program. The following changes the unit cell parameters in the image header (note: if the second file name is the same as the first, the original file is overwritten):

bhead -verbose 7 -unitcell 42.5,60,125.7,90,120,45 2omf.grd test.mrc

Using different image processing packages often means that different conventions of axis order and image orientation are used. The following two examples rotate an image around the y axis by 90 degrees and mirror the image along the z axis:

bimg -verbose 7 -reslice zy-x 2omf.grd test.mrc

bimg -verbose 7 -reslice xy-z 2omf.grd test.mrc

The histogram of an image and information content associated with it can be calculated over 200 bins and output to a postscript file indicated by the "-p" option:

bhisto -verbose 7 -bins 200 -p output.ps 2omf.grd

An image can be scaled to 1.4 times the sampling and resized:

bint -verbose 7 -scale 1.4,1.4,1.4 2omf.grd test.mrc

Files can be compared in various ways, with the following example doing a linear least squares fit between two images and returning the difference after fitting:

bop -verbose 7 -fit 10 2omf.grd test.mrc t2.mrc

Multiple image files can be concatenated into one file as multiple images or as slices of a 3D image:

bcat -verbose 7 -output file.mrc in*.map