Post-run Macro to export Signal Raw Data to ASCII

Dear All,

 

I'm using a GC system 7890A and controlling it with Chem-Station software.

 

I was wondering if anyone can help me in finding a way to automatically export the signal raw data to an ASCII file, ideally also with the option of choosing the folder destination.

 

I have already tried to modify the report output, however I managed to produce only a .txt file containing the integrated peaks' area, but not the signal raw data (X and Y values).

 

I think the answer lies in writing a post-run command/macro to be inserted when I edit the method that I use, however I am really unfamiliar with macro running and would be grateful if you could help me in this, or any other solutions I am not aware of.

 

Thanks in advance for your time

 

Best Regards,

 

Amedeo

Parents
  • Hi Amedeo,

    Attached is a more complete macro for you.  It will export multiple signals and place the ASCII file in the samples data directory.

    Just put the user.mac file in the C:\Chem32\Core directory and add the "EXPORTSIGNALS" macro to the post run macro in the runtime checklist.

     

    Let me know if you have any problems.

    Tim

    user.mac.zip
  • Hi hebgent!

     

    I tried your macros but keep getting parser errors.

    user.mac and extractsignal.mac are both placed in the CORE directory.

    Extractsignal.mac is set as the postrun macro.

    I have also tried user.mac as the postrun macro and have tried them both from the command line.

    There is always a parser error.

    We are using the latest release of Chemstation.

    Currently, I have 3 signals; 2 from the DAD and one from the FID.

     

    Any thoughts?

     

    Thanks!

  • Just loaded the new user.mac and reprocessed some data.

     

    Signal1   correct (DAD1A)

     

    Signal2   not correct. It is giving me the gradient pump, not DAD1B (it was not correct on the previous version either). 

                   I don't mind getting an extra csv file that contains the pump gradient. It is useful.

     

    Signal3 is not present. Signal3 should be the fluorescence detector data.

     

    Maybe the different channels from the DAD and FLD are in different data files or locations from where you are parsing it out?

     

    Is there a data file from Chemstation that I can send you that might have the raw data in it?

    I don't think the currently generated  Signal1 and Signal2 files would help you, they are simply time and signal comma delimited for 1 channel each.

    I'm sure if I send a file from a blank run, nobody will care...

  • The macro exports data in the ChromReg register but only the signals listed in the Signal Details of the method are loaded into the register.  So by adding all the desired signals to the Signal Details of the method you will get each exported.  Or if you don't like doing that because of how it changes the default reports we can reload the sample data file at the start of the macro which will load all signals.

     

    You are correct, the FLD is stored in a different register.  I'll work on adding that register to the macro.

    Tim

  • I don't have a FLD and I'm not sure about the register structure.  It should be similar to all LC register objects so it might be an easy fix.  Would you be able to attach a FLD signal file so I can test the macro?

    Thanks

    Tim

  • I've attached an updated macro.  The exported data files are now called DAD1A.txt, FLD1A.txt, FID1B.txt....and so on.

     

    The FLD data does get loaded into the ChromReg register but only if its added in the Signal details.  So I've added a LoadFile command at the beginning of the macro which loads all the signals for the current sample and then it can export them all.  It will open a "Current Chromatogram(s)" window for them and I can't figure out how to automatically close that window when it's done.  Its not a big deal because it will continue to use that one window for every sample in a sequence, leaving you with one window open at the end.

     

    Anyway, give this one a try.

    Tim

    USER.mac.zip
  • Your timing is exquisite!

     

    I have a bunch of runs that should come out around 6:00 PM...

     

    Hopefully the signals are automatically exported to make pretty slides that can be emailed to someone already on their plane taxiing down the runway... It's Hail Mary time!

     

    Thanks again!

     

    David

Reply Children
No Data
Was this helpful?