Reads the pump, diode array detector, autosampler and column thermostat
settings from the module register files (LPMP1.REG, LDAD1.REG,
LALS1.REG or LWLS1.REG, and LTHM1.REG) of a 'ChemStation' .M method
directory. Revisions that store a module's settings as 'RapidControl' XML
(e.g. AgilentPumpDriver1.RapidControl.MethodXML.xml) instead are read as
'OpenLab CDS' methods are by read_agilent_amx.
read_chemstation_method(
path,
what = c("pump", "dad", "sampler", "column"),
format_out = c("data.frame", "tibble", "data.table"),
gradient_format = c("wide", "long")
)A named list with one element per module read. A module the method
has no settings for is left out with a warning, and it is an error if
none of the requested modules are present. The sampler module is
returned as autosampler. The elements are those of read_agilent_amx,
with NA for a setting the method does not record:
pump: a list with scalar elements flow_mL_min, stop_time_min,
post_time_min, pressure_low_bar and pressure_high_bar, plus:
solvents: a table of the channels in use, with columns channel,
percentage (at the start of the run) and solvent (the name entered
for it, or NA).
gradient: the timetable. Wide format: time_min and a pct_<channel>
column per channel in use, plus flow_mL_min if the timetable sets the
flow. Long format: time_min, channel and percent, where a flow
channel holds the flow in mL/min. An empty timetable gives the starting
composition at time 0.
dad: a list with scalar elements peakwidth_code, slitwidth_nm,
uv_lamp_required, vis_lamp_required, spectra_from_nm,
spectra_to_nm and spectra_step_nm, plus
signals, a table of the stored signals with columns id,
wavelength_nm, bandwidth_nm, reference_nm and
reference_bandwidth_nm (NA without a reference).
peakwidth_code is the stored code for the detector's peak width
setting, which sets its data rate and response time; for example, 4 is
"> 0.1 min". It is not decoded, since detector models offer different
settings.
autosampler: a list with scalar elements thermostat_installed,
draw_speed_uL_min, eject_speed_uL_min, wait_after_draw_min,
injection_volume_uL and wash_time_s. Register files record only the
speeds and the injection volume.
column: a list with scalar element post_time_min (NA when off),
plus temp_controls, a two-row table (Left, Right) with columns
side, temperature_C, not_ready_limit_C and equilibration_time_min.
A temperature stored below absolute zero (e.g. -274) is NA; this may
mean no temperature was set.
Path to a .M directory, or to a .D directory holding a copy
of its method.
One or more instrument modules to read: any combination of
"pump", "dad", "sampler" and "column". Defaults to all four.
Class of the solvents, gradient, signals and
temp_controls tables: "data.frame", "tibble" or "data.table".
Whether to return the gradient in "wide" (default)
or "long" format.
Ethan Bass
Depending on how 'ChemStation' is configured, a .D directory may hold a
copy of the method it was acquired with, in ACQ.M or, in older revisions,
RUN.M. path can then be the .D directory itself. Its DA.M holds the
data analysis method instead, whose pump settings may not be those the run
was acquired with; reading it gives a warning.
The gradient follows the pump's timetable, with each parameter changing linearly between the times it is set. Channel A is the pump's primary channel and delivers whatever the other channels leave, so it is always included and its share is computed rather than read.
read_agilent_amx for 'OpenLab CDS' methods, and read_agilent_d
with what = "instrument" for the pump's record of what it delivered.
Other 'Agilent' parsers:
read_agilent_d(),
read_agilent_dx(),
read_agilent_rslt(),
read_chemstation_ch(),
read_chemstation_csv(),
read_chemstation_logs(),
read_chemstation_ms(),
read_chemstation_reports(),
read_chemstation_uv()
if (FALSE) {
method <- read_chemstation_method("path/to/METHOD.M")
method$pump$gradient
}
Run the code above in your browser using DataLab