Difference between revisions of "Tutorial for R1/R2 Relaxation curve-fitting analysis from NMRView files"

From relax wiki
Jump to navigation Jump to search
Line 161: Line 161:
  
 
=== Procedure in GUI ===
 
=== Procedure in GUI ===
 +
* Start relax
 +
* Then click: {{button|new analysis}} or {{key press|cmd|n}}
 +
* Then click icon for {{button|R1 relaxation}} {{next}} {{button|Next}}
 +
* Just accept name for the pipe
  
 +
* Open the relax prompt: {{key press|cmd|p}}
 +
* Paste in
 +
<source lang="python">
 +
import os; os.chdir(os.getenv('HOME') + os.sep + 'Desktop' + os.sep + 'Karin'); pwd()
 +
</source>
 +
* Then do
 +
<source lang="python">
 +
script(file='2_load_data.py')
 +
</source>
 +
* ( You can scroll through earlier commands with: {{key press|cmd|up}} )
 +
* Close the prompt window
 +
 +
Now save the current state! This saved state can now be loaded just before an analysis, and contain all setup and data.
 +
* {{menu|File|Save as (Shift+Ctrl+S)}} {{next}} Save as <code>before_analysis.bz2</code>
 +
 +
Now '''Quit relax''', and start relax again.<br>
 +
Go to: {{menu|File|Open relax state (Ctrl+O)}} {{next}} Locate <code>before_analysis.bz2</code>
 +
 +
{{Execute}}
  
 
=== Procedure in terminal ===
 
=== Procedure in terminal ===
Line 168: Line 191:
 
relax 2_load_data.py -t log.txt
 
relax 2_load_data.py -t log.txt
 
</source>
 
</source>
 
  
 
== See also ==
 
== See also ==
 
[[Category:Tutorials]]
 
[[Category:Tutorials]]

Revision as of 23:37, 31 March 2016

Data background

Based on message found at: http://thread.gmane.org/gmane.science.nmr.relax.user/1874

Data stored in several NMRView .xpk files.

relax can read the NMRView format.

The whole list of files is:

R1-methyl_hRGS4_20C_pH7_Mar2016_0ms
R1-methyl_hRGS4_20C_pH7_Mar2016_10msa
R1-methyl_hRGS4_20C_pH7_Mar2016_10msb
R1-methyl_hRGS4_20C_pH7_Mar2016_30ms
R1-methyl_hRGS4_20C_pH7_Mar2016_50ms
R1-methyl_hRGS4_20C_pH7_Mar2016_70ms
R1-methyl_hRGS4_20C_pH7_Mar2016_90msa
R1-methyl_hRGS4_20C_pH7_Mar2016_90msb
R1-methyl_hRGS4_20C_pH7_Mar2016_110ms
R1-methyl_hRGS4_20C_pH7_Mar2016_130ms
R1-methyl_hRGS4_20C_pH7_Mar2016_150ms
R1-methyl_hRGS4_20C_pH7_Mar2016_170ms
R1-methyl_hRGS4_20C_pH7_Mar2016_190ms
R1-methyl_hRGS4_20C_pH7_Mar2016_210ms
R1-methyl_hRGS4_20C_pH7_Mar2016_250ms

For determination of the errors of the intensity, there is 2x duplicated spectra (10ms, and 90ms.)

See:

NMRView format

Each file has a structure like this:

label dataset sw sf
H1 C13
R1-methyl_hRGS4_20C_pH7_Mar2016_0ms.nv
1500.2322998 3328.125
599.802978516 150.824996948
H1.L H1.P H1.W H1.B H1.E H1.J H1.U C13.L C13.P C13.W C13.B C13.E C13.J C13.U vol int stat comment flag0
0 {75.HG11} 1.03960 0.03402 0.08416 ++ {0.0} {} {75.CG1} 21.00886 0.34258 0.60154 ++ {0.0} {} 2.09171414375 0.0213 0 {} 0
1 {75.HG21} 1.04055 0.03307 0.07450 ++ {0.0} {} {75.CG2} 20.65424 0.20240 0.50941 ++ {0.0} {} 1.69693529606 0.0198 0 {} 0
....

This is 19 Columns of data.

The first line describes what datatypes is to be found in the following lines. Here:

  • Line 1 is the label of nucleus
  • Line 2 is the dataset from where the file is created from
  • Line 3 is the Sweep (Spectral) Width [sw] in Hz
  • Line 4 is the Nuclear magnetic resonance frequency at the given spectrometer field. In MHz.

Then follow a line of header description.

  • H1.L must be the label for the H1. Residue 75, atomname HG11
  • Then follows .P, .W and .B
  • Then follow .E, .J and .U.

Then comes for carbon C13.

Ind the end, there must be the (vol) peak volume integration intensity and the (int) the top peak point intensity.

The relax systemtests which test reading these files are found in:

test_suite/system_tests/chemical_shift.py
test_suite/system_tests/peak_lists.py

Run analysis in relax GUI

The Script

Procedure in GUI

  • Start relax
  • Then click: new analysis or Cmd+n
  • Then click icon for R1 relaxationNext
  • Just accept name for the pipe
  • Open the relax prompt: Cmd+p
  • Paste in
import os; os.chdir(os.getenv('HOME') + os.sep + 'Desktop' + os.sep + 'Karin'); pwd()
  • Then do
script(file='2_load_data.py')
  • ( You can scroll through earlier commands with: Cmd+ )
  • Close the prompt window

Now save the current state! This saved state can now be loaded just before an analysis, and contain all setup and data.

  • File  → Save as (Shift+Ctrl+S) → Save as before_analysis.bz2

Now Quit relax, and start relax again.
Go to: File  → Open relax state (Ctrl+O) → Locate before_analysis.bz2

Template:Execute

Procedure in terminal

The analysis can be performed by

relax 2_load_data.py -t log.txt

See also