**Why**

Once an atomic model has been built into an electron density map, or obtained by molecular replacement, you need to optimize it to best fit the experimental data while also preserving good agreement with prior chemical knowledge.

For crystallographic data, this refinement process is usually done in reciprocal space. Using a least-squares or maximum-likelihood target, the model parameters are changed so the model-derived structure factors match the amplitudes or intensities of the experimental structure factors. For example, these model parameters can include (a) atomic parameters, such as coordinates, atomic displacement parameters, occupancies, and scattering factors, and (b) non-atomic parameters that describe contributions from bulk solvent, twinning, and crystal anisotropy.

**How**

In Phenix, the primary program for refining atomic models is
*phenix.refine*. This applies optimization algorithms (minimization or
simulated annealing) to change the model parameters (typically
coordinates and atomic displacement parameters) to improve the fit of
the model to the data. At the same time, it applies restraints to prior
chemical information (such as bond lengths, angles, and torsions) to
maintain good stereochemistry. This customizable program allows multiple
refinement strategies to be combined and applied to any selected part of
the model in a single run.

**How to use the phenix.refine GUI:** Click
here

Phenix reference manual for phenix.refine

**Common issues**

**Related programs**

- phenix.rosetta_refine: This program combines crystallographic structure refinement algorithms from Phenix with physically realistic potentials for model optimization from Rosetta. The tool is useful at low resolution, where it combines a wide radius of convergence across distinct local minima with realistic geometry.
- phenix.ensemble_refinement: This program combines crystallographic refinement with molecular dynamics to produce ensemble models fitted to diffraction data. These ensemble models can contain ~50-500 individual structures, and can simultaneously account for anisotopic and anharmonic atomic distributions.
- ERRASER: This is another Rosetta method that performs real-space rebuilding of RNA structures for improved geometry and fit to data.