Finally dug out the notes I made for passing peaks to nlinLS for fitting.
I did indeed encounter the initial linewidth guess problem also, and I got
around it by inserting a guess as described. The bit about adding a
TROUBLE column to the outputed peaks should be obsolete now as Wim added
this at the time at my request. Any code is 2006 vintage, so it almost
certainly needs data model bit checking before use.
To do the fitting really well, it would be nice to take processing into
acount also in nlinLS. I posted to the nmpipe mailing list on this
http://tech.groups.yahoo.com/group/nmrpipe/message/1256
but never did get any replies - if anyone has any insight into this I
would love to hear it.
--
Dr. Brian O. Smith ---------------------- B Smith at bio gla ac uk
Division of Biochemistry & Molecular Biology,
Institute Biomedical & Life Sciences,
Joseph Black Building, University of Glasgow, Glasgow G12 8QQ, UK.
Tel: 0141 330 5167/6459/3089 Fax: 0141 330 8640
How to fit peaks using nlinLS
nlinLS doesn't like 0.0 estimates for XW YW XW_HZ and YW_HZ so it's a good idea
to set sensible estimates
- could be set in datamodel before export by setting AbstractPeakDim.decayRate:
for peak in top.project.findFirstNmrExperiment(name = 'gNHSQC').findFirstDataSource(name = '3/spc').findFirstPeakList().getPeaks():
for dim in peak.getPeakDims():
dim.decayRate = 40.0
(check that your version of formatConverter has
fwhm = fwhm_Hz * self.dataDimRef.dataDim.numPoints / self.dataDimRef.dataDim.spectralWidth
^^^^^^^
in python/ccpnmr/format/converters/NmrDrawFormat.py)
Export peak table from analysis in nmrDraw format using the formatConverter
Add a TROUBLE (format %4d) column to the end of the headings line for nlinLS to
report the success or otherwise of the fit into.
CLUSTIDs must be set for nlinLS
(could be set in formatConverter NmrDrawFormat.py self.clustId but concept not
supported in analysis yet?)
- consider using clustTab.tcl e.g. for an 15N HSQC:
clustTab.tcl -in nmrDraw.tbl -x X_PPM Y_PPM -dist 0.1 1.0 -out clustTab.tbl
If you are using Azara (or other non nmrPipe) data you will need to convert to
nmrPipe format. For Azara this can be accomplished by:
- unblocking the data using Azara "unblock"
e.g unblock.scr:
input spc.par
output unblocked
- converting the unblocked data to nmrPipe format using bin2pipe
e.g spc.com (modify for your points, referencing etc.):
#!/bin/csh
bin2pipe -in unblocked \
-xN 2048 -yN 128 \
-xT 2048 -yT 128 \
-xMODE Real -yMODE Real \
-xSW 8389.262 -ySW 2433.090 \
-xOBS 600.133 -yOBS 60.818 \
-xCAR 4.945 -yCAR 120.296 \
-xLAB HN -yLAB N \
-ndim 2 -aq2D States \
-out spc.ft2 -verb -ov
To recreate the Azara window functions you used to feed to nlinLS via the -apod flag:
For each dim of your file create a cut down script e.g.
input ser.par
output d1win
script_com 2
range 1 1
end_script
script_com 1
complex
set2 1 768 1.0 0
gaussian_sw 20 1.3 0
zerofill 1
fft
phase 0 25785
ifft
scale2 1 2048 1.2753e-3 0.0 !rescale div by 784.117249 (max found using look_at)
set2 769 2048 0.0 0.0 !trash shifted bit at end
reduce
end_script
The acquistion dimension shown above is a special case for Bruker digitally
oversampled data where the effects of the digital filter were undone by a large
first order phase shift. The scripts will be much simpler for other cases. Note
that if you had a non power of 2 data points originally, then zerofill 1 only
doubles the original number of points and any additional zerofilling required to
get to a power of 2 is done by the ft function - you may need to zerofill an
extra time and then use range to cut back to the right length.
Before you can use feed the shape you have created to nlinLS you will need to
unblock it and convert to pipe format in a similar way to the raw data. The xyz2pipe
script might look like:
#!/bin/csh
bin2pipe -in d1win_unblocked \
-xN 2048 \
-xT 2048 \
-xMODE Real \
-xSW 8389.262 \
-xOBS 600.133 \
-xCAR 4.945 \
-xLAB HN \
-ndim 1 \
-out d1win.fid -verb -ov
Run nlinLS through autofit.tcl
autoFit.tcl -specName spc.ft2 -simName sim.ft2 -inTab clustTab.tbl
|