Page 1 of 2
Exporting Chromatograms from ChemStation
Posted: Tue Dec 14, 2010 5:53 pm
by irrumator11
Very inexperienced user here, so forgive my very basic question.
I am interested in exporting the chromatograms from ChemStation into Excel. I've read through the forums here, and I found info on how to export the run report into Excel, but the report only contains information about the peaks (i.e. ret. time, peak area, peak height, etc). I want to be able to re-create the entire chromatogram in excel, not just the peaks. Time on the x-axis, and a continuous line of the mAU on the y-axis. Is there a way to do this?
Re: Exporting Chromatograms from ChemStation
Posted: Tue Dec 14, 2010 8:07 pm
by GasMan
If I understand you correctly, you wish to re-create the chromatogram in Excel. If you were supplied a CSV file, would this help?
Gasman
Re: Exporting Chromatograms from ChemStation
Posted: Tue Dec 14, 2010 8:54 pm
by irrumator11
Hi GasMan,
Yes, I would like to re-create the chromatogram in Excel. If there is a way to export this information in CSV format, that would work as well.
The CSV files included in the run report only show information regarding the peaks, so that I cannot reconstruct the entire chromatogram from those CSV files.
Re: Exporting Chromatograms from ChemStation
Posted: Tue Dec 14, 2010 11:08 pm
by GasMan
If you go to the following link, you can use a macro that will download the rawdata to a CSV file. This has been used by a couple of postings with success.
viewtopic.php?f=2&t=12183&p=60793#p60793
Gasman
Re: Exporting Chromatograms from ChemStation
Posted: Tue Dec 14, 2010 11:23 pm
by irrumator11
Wow, GasMan, this is exactly what I needed! Thanks!
Is it possible to export several chromatograms from the same data file? I have four chromatograms associated with the file, and the macro only exports the first one.
Re: Exporting Chromatograms from ChemStation
Posted: Wed Dec 15, 2010 1:46 pm
by GasMan
Try this
****************************************************************
Name csvfile
Local cols,runtime,signal,i,j
for j=1 to RegSize(Chromreg)
cols=DataCols (Chromreg[j])
Open "C:\temp\Signal"+Val$(j)+".csv" For Output as #5
Print "Saving C:\temp\Signal"+Val$(j)+".csv"
For i=1 To cols
runtime=Data (Chromreg[j],0,i)
signal=Data (Chromreg[j],1,i)
print#5,runtime,",",signal
Next i
Close#5
next j
Print "Finished"
endmacro
**************************************************************
Just some minor changes
Gasman
Re: Exporting Chromatograms from ChemStation
Posted: Wed Dec 15, 2010 3:26 pm
by irrumator11
Fantastic! Thank you so much, GasMan!

Re: Exporting Chromatograms from ChemStation
Posted: Thu Dec 16, 2010 10:26 am
by lmh
for exporting a single chromatogram from LC-chemstation, it's just a menu item:
file - export - csv - active graphic window
(of course you need to have the chromatogram open as the active graphic window if you wish to do this!)
Re: Exporting Chromatograms from ChemStation
Posted: Tue May 31, 2011 2:40 am
by krisradh1432
Hi irrumator11 and GasMan,
May I know what tools you use to redraw the chromatogram. Me also using the same Agilent version. Limited function in copying the chromatogram.
Thank You.
Re: Exporting Chromatograms from ChemStation
Posted: Thu Jun 09, 2011 7:50 pm
by AICMM
Gasman,
Thanks for that macro. Used it today and it worked beautifully.
Best regards,
AICMM
Re: Exporting Chromatograms from ChemStation
Posted: Mon Jan 07, 2013 9:06 pm
by schlenkline
Thanks for sharing this macro, it works great!
Is there any way to adapt the macro to accommodate export multiple UV traces?
Re: Exporting Chromatograms from ChemStation
Posted: Mon Jan 07, 2013 10:49 pm
by shfo
There's probably a nice Chemstation macro that does this too in an easier fashion, but I've been working on a
program that can open Chemstation UV traces and export them out to CSV files (amongst other things).
Assuming you can get it to run, you would open the folder containing your *.D files from the File menu, click the "Vis" checkbox and type in the wavelengths you want (under "Traces") in the table next to the chromatogram you want, click File->Export->Visible Chromatogram, and then chose "Comma-Delimited Text" as the file-type in the Save dialog. It can also export SVG/PNGs of those plots if you don't need pretty plots from Excel.
Re: Exporting Chromatograms from ChemStation
Posted: Sun Apr 14, 2013 4:15 pm
by ejm087
Hey everyone, this seems to be a pretty widespread problem. I tried the macro that was posted here but it does not work. Let me clarify: I was able to generate the macro but when I opened up the excel file it was just one column with 10000 rows of sequential gibberish. Is there something I am not taking into account.
I am running Chemstation for LC REV. B.04.02
1200 series HPLC-ELSD
Is it possible to modify the macro to run when a batch sequence is loaded? However, there is a caveat: I know there are ways to get around this problem with chemstation's batch function in general but my issue is that I am not running any standards. My samples are all unknowns. So the batch report is useless to me.
Re: Exporting Chromatograms from ChemStation
Posted: Mon Apr 15, 2013 12:28 pm
by GasMan
The macro was written for GC ChemStation data. I am a GC user, so I do not have access to LC data. It is quite possible that the LC data files are in a different format than the GC files.
Gasman
Re: Exporting Chromatograms from ChemStation
Posted: Tue Apr 16, 2013 2:11 pm
by ejm087
That explains it. Thanks for responding.