This sample script can be found in the sample_scripts directory and will be used as the template for the next sections describing how to use relax.
# Script for calculating NOEs.
# Create the data pipe.
pipe.create('NOE', 'noe')
# Load the sequence from a PDB file.
structure.read_pdb('Ap4Aase_new_3.pdb')
structure.load_spins(spin_id='@N')
structure.load_spins(spin_id='@NE1')
# Load the reference spectrum and saturated spectrum peak intensities.
spectrum.read_intensities(file='ref.list', spectrum_id='ref_ave')
spectrum.read_intensities(file='sat.list', spectrum_id='sat_ave')
# Set the spectrum types.
noe.spectrum_type('ref', 'ref_ave')
noe.spectrum_type('sat', 'sat_ave')
# Set the errors.
spectrum.baseplane_rmsd(error=3600, spectrum_id='ref_ave')
spectrum.baseplane_rmsd(error=3000, spectrum_id='sat_ave')
# Individual residue errors.
spectrum.baseplane_rmsd(error=122000, spectrum_type='ref', res_num=114)
spectrum.baseplane_rmsd(error=8500, spectrum_type='sat', res_num=114)
# Peak intensity error analysis.
spectrum.error_analysis()
# Deselect unresolved spins.
deselect.read(file='unresolved', res_num_col=1, spin_name_col=2)
# Calculate the NOEs.
minimise.calculate()
# Save the NOEs.
value.write(param='noe', file='noe.out', force=True)
# Create Grace files.
grace.write(y_data_type='peak_intensity', file='intensities.agr', force=True)
grace.write(y_data_type='noe', file='noe.agr', force=True)
# View the Grace files.
grace.view(file='intensities.agr')
grace.view(file='noe.agr')
# Write the results.
results.write(file='results', dir=None, force=True)
# Save the program state.
state.save('save', force=True)