evanyeyeye / rainbow

Read chromatography and mass spectrometry binary files.
GNU General Public License v3.0
29 stars 15 forks source link

Can't use Rainbows to access Chemstation directory and HPLC datafiles. #5

Closed ddalland closed 8 months ago

ddalland commented 10 months ago

Thank you for providing this Python code, which I am hoping to use for a chemistry project. Unfortunately, it is not working for me so far. When I run the following cell in Jupyter notebook to read the Chemstation data in folder 55.D: "import rainbow as rb datadir = rb.read('/Users/ (...) /VTNA-4/55.D')" Datadir only contains a name '55.D' and the metadata: {'vendor': 'Agilent', 'vialpos': '55'}. When I then try to read one of my .ch files (datadir.get_file('dad1C.ch')), I get an error message saying that "Data file dad1C.ch not found in 55.D.". I have also tried to apply the method rb.agilent.chemstation.parse_ch('dad1C.ch'), but this returns None, suggesting that the file cannot be read. Do you know my rainbows is not working in my case? I can access the data using a program called UniChrom, but this is less useful than using Python. A colleague of mine has used rainbows successfully in the way I have attempted, but he has used data from a newer version of the chemstation software, maybe that makes the difference?

PS: the files in my directory 55.D are as follows: ['.ipynb_checkpoints', 'ACQRES.REG', 'dad1.uv', 'dad1A.ch', 'dad1B.ch', 'dad1C.ch', 'dad1D.ch', 'dad1E.ch', 'LCDIAG.REG', 'Report.TXT', 'Report00.CSV', 'REPORT01.CSV', 'REPORT02.CSV', 'REPORT03.CSV', 'REPORT04.CSV', 'REPORT05.CSV', 'RUN.LOG', 'SAMPLE.MAC', 'Untitled.ipynb']

ekwan commented 10 months ago

Would you be able to share the .D file as a zip so we can look at it?

ddalland commented 10 months ago

Yes, sure. Here it is along with another one in case that's useful. Thank you! 55.D.zip 37.D.zip

ekwan commented 10 months ago

My colleague James is looking into this and we will get back to you!

ekwan commented 10 months ago

We looked at this and it seems to be a different format. What version of ChemStation are you using? Are you able to provide a decoded version from UniChrom?

ddalland commented 10 months ago

Thank you for looking into it. The HPLC and chemstation software is of the old type (new at the time of Windows vista I think), but I don't know which format exactly, I can ask my colleagues and get back to you. I have sent pdf's, a csv and some screenshots showing what I got when I opened the .ch and .uv files in 55.D using UniChrom. opened data.zip

ekwan commented 10 months ago

Hi! Thanks very much! Please give us a week or so to look at this. We'll get back to you!

ddalland commented 9 months ago

Hi! Did you get time to have a look at it? I might need to find another solution if you didn't find a way around it. Thanks

ekwan commented 9 months ago

Sorry not yet. We can have a look this week.

On Sun, Nov 26, 2023 at 5:34 AM ddalland @.***> wrote:

Hi! Did you get time to have a look at it? I might need to find another solution if you didn't find a way around it. Thanks

— Reply to this email directly, view it on GitHub https://github.com/evanyeyeye/rainbow/issues/5#issuecomment-1826746884, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABOBNITAAXCODM2CZ7NQSGLYGMLL7AVCNFSM6AAAAAA6X5ZWO6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMRWG42DMOBYGQ . You are receiving this because you commented.Message ID: @.***>

ekwan commented 9 months ago

(It was Thanksgiving last week, so everyone was with their family.)

On Sun, Nov 26, 2023 at 6:06 AM Eugene Kwan @.***> wrote:

Sorry not yet. We can have a look this week.

On Sun, Nov 26, 2023 at 5:34 AM ddalland @.***> wrote:

Hi! Did you get time to have a look at it? I might need to find another solution if you didn't find a way around it. Thanks

— Reply to this email directly, view it on GitHub https://github.com/evanyeyeye/rainbow/issues/5#issuecomment-1826746884, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABOBNITAAXCODM2CZ7NQSGLYGMLL7AVCNFSM6AAAAAA6X5ZWO6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMRWG42DMOBYGQ . You are receiving this because you commented.Message ID: @.***>

ekwan commented 9 months ago

Looks like we fixed the problem. James will post here soon. Have you got some more files we can test on?

ddalland commented 9 months ago

No worries! I hope thanksgiving was great. Thank you for working on it! Here are 4 HPLC sample files where I have opened 2 of the .ch files for each folder and saved the corresponding .csv files and report pdf files. [Uploading HPLC data.zip…]()

ekwan commented 9 months ago

Thanks! Something is wrong with that link...

ddalland commented 9 months ago

Woops, I hope this works: HPLC data.zip

JMarvi3 commented 9 months ago

@ddalland Could you take a look at Pull Request #7 to ensure that it resolves your issue?

Also, could we have your permission to use one of your data directories, redacted (identifying information removed), as part of a unit test for Rainbow?

ddalland commented 9 months ago

I have checked, and it does fix it. Thank you! I would not mind if you use any of the data directories for any purpose.

ekwan commented 8 months ago

Closed by PR #7.