jjhelmus / nmrglue

A module for working with NMR data in Python
BSD 3-Clause "New" or "Revised" License
208 stars 85 forks source link

Created spinsolve.py #147

Closed LCageman closed 3 years ago

LCageman commented 3 years ago

I created the read and guess_udic for spinsolve data, as mentioned in issue #146. The read function will work on a directory and a filename can be specified, otherwise the standard names are tried. When I compared to other fileio scripts I realized that I put everything into one function instead of using smaller functions. I can still do this for a next iteration. I also use the fileio/jcampdx.py script here to read the (optional) .dx file, I'm not sure if that is preferred or if it's better to copy (only) the necessary code here. guess_udic uses acqu.par file parameters (should be always present), otherwise the .dx file header parameters are used (only when having a .dx file)

LCageman commented 3 years ago

I seem to have made a bit of a mess in the commits and can't find how to fix it. I wanted to change 'fileio/init.py', but somehow it happened twice. Therefore "0659e70" can be ignored.

Also, find test data attached here (supplied by @NichVC) Spinsolve.Data.+.Documentation.zip

kaustubhmote commented 3 years ago

This looks really good! Give me a couple of days for testing different datasets and I think this should be ready for a quick merge. Thanks!

kaustubhmote commented 3 years ago

This works as expected, and is now merged. Thanks! If you have the bandwidth, maybe a few additions might be nice:

  1. A read_pdata function that prioritises the processed data (just for convenience).
  2. Update to the documentation (doc/source/tutorial.rst).
  3. A couple of tests to go with this.
LCageman commented 3 years ago

Thanks @kaustubhmote! I'll find some time in the next weeks for your suggestions.