map

Cryo-EM: How to change box size and pixel size

Short info that could be of interest for people new in cryo-E.

From the command line in a linux terminal you can look up the box size of the map you just created in Chimera by using EMAN2:

e2iminfo.py map_you_want_to_know_BoxSize_off.mrc

You can then change the box size (in pixels) the map by using Relion from the command line.

For example if you want to change the box size of your map to 300x300x300 pixels from whatever it was before, you just type:

relion_image_handler --i map_you_want_to_change.mrc --new_box 300 --o new_boxSize_map.mrc

This will write a new map (called new_boxSize_map.mrc) with a box size of 300x300x300 pixels.

You can also use relion_image_handler (among other things) for rescaling a map to a new pixel size (in Å).

Let say you want to change the pixel size of your map from before to 4 Å:

relion_image_handler --i map_you_want_to_change.mrc --rescale_angpix 4 --o new_pixelSize_map.mrc

11 thoughts on “Cryo-EM: How to change box size and pixel size”

  1. thanks for your share. but I have a problem, when I use the follow command to change the pixel size, it’s warning that –new_angpix is not a valid argument. I don’t know how to solve it, could you help me? Thanks!

    relion_image_handler –i map_you_want_to_change.mrc –new_angpix 4 –o new_pixelSize_map.mrc

    1. Hi sorry for the very late answer. It is actually my mistake, because it should say “–rescale_angpix” instead of “–new_angpix” in my example. If you use that it will work. Sorry about that, I will update the entry! /Ruki

  2. Thanks for the tutorial Ruki, I run into an issue when i try open my resized MRC file back into chimera. After shifting the box size to 300 and pixel size to 1 A I get an error that reads:
    “Error reading file (filename), format mrc
    Bad MRC grid size
    (38467,38467,-2134331577)”
    Do you know what the problem could be or how to fix it?
    Thanks

      1. Hi Rohan,

        Please feel free to share the solution as well as the question. This is similar to the mailing list where ppl figure out the solution to their own question themselves, but do not share the solution with the list.
        Cheers Ruki

  3. Or you can just do this using only eman2:
    e2proc3d inputVolume.mrc outputVolume.mrc –scale=S

    with S=inputPixSize/outputPixSize

    1. Thank you very much for contributing! Yes this can be done many different ways with different programs, some more intuitive than others though. If you work with Eman2 your way seems very fast also. Thx for sharing!

  4. Hello,
    I have question about changing box size and pixel size. I generated a map from the pdb file in chimrea and it looks good. Itried to change the pixel size using relion_image_handler but volume just become a ball like structure. here are th ecommands i used:
    relion_image_handler –i old.mrc –rescale_angpix 1.009 –o newp.mrc
    and
    relion_image_handler –i newp.mrc –new_box 196 –o newp_newB.mrc

    Any help was appreciated?

    thanks

Leave a Reply

Your email address will not be published. Required fields are marked *