This calculates optical depths by integrating extensive parameters over the course of a filter. It can calculate scattering, absorption and extinction optical depths for the filter in addition to the asymmetry parameter derived from the backscattering optical depth. This is generally used as a precursor to applying the Müller 2014 (CTS) correction.

Usage

da.calc.opticaldepth [switches…​] [[station] variables times [archive]|[file]]

Switches

--absorption=SELECTION

This is the input light absorption to use in optical depth generation. This option is mutually exclusive with absorption instrument specification.

Default: All light absorptions

--absorption-instruments=SUFFIX…​

These are the instrument suffixes to use absorption data from. For example A11 would usually specifies the primary absorption instrument. This option is mutually exclusive with manual absorption variable specification.

Default: All instrument suffixes

--backscattering=SELECTION

This is the input light backscattering to use in optical depth generation. This option is mutually exclusive with scattering instrument specification.

Default: All light backscatterings

--calculate-l[=BOOLEAN]

This enables recalculation of the sample length from the spot area and flow. If the variables containing the spot area and flow are not present in the input then the option to set the incremental change in length most be set.

--dl=INPUT

This is the change in sample length used for each calculation interval. When omitted it is calculated from the start and end sample lengths.

--extinction=SELECTION

This is the input light extinction to use in optical depth generation. This option is mutually exclusive with extinction instrument specification.

Default: All light extinctions

--extinction-instruments=SUFFIX…​

These are the instrument suffixes to use extinction data from. For example E11 would usually specifies the first extinction instrument. This option is mutually exclusive with manual extinction variable specification.

Default: All instrument suffixes

--instruments=SUFFIX…​

These are the instrument suffixes to calculate for. For example S11 would usually specifies the reference nephelometer.

Default: All instrument suffixes

--length-end=INPUT

This is the input end sample length used in the calculation. When this option is set, this length is used for all channels.

Default: Resolved automatically by instrument suffix

--length-start=INPUT

This is the input start sample length used in the calculation. When this option is set, this length is used for all channels.

Default: Resolved automatically by instrument suffix

--reset-gap=INTERVAL

This is the maximum time allowed between accumulated measurements. When this time is exceeded, the integration is reset (a new filter begins). Invalid but present measurements are not considered gaps.

Undefined intervals are accepted. The interval must be greater than or equal to zero length.

--scattering=SELECTION

This is the input light scattering to use in optical depth generation. This option is mutually exclusive with scattering instrument specification.

Default: All light scatterings

--scattering-instruments=SUFFIX…​

These are the instrument suffixes to use scattering data from. For example S11 would usually specifies the reference nephelometer. This option is mutually exclusive with manual scattering variable specification.

Default: All instrument suffixes

--synchronous-zero[=BOOLEANS]

When enabled, this option causes zero change to the integrated optical depths when their corresponding instrument reports a zero in its flags. When not present the last known value continues to be integrated. This is normally used when the filter based instrument is sampling from a pickoff downstream of the zeroing instrument.

--transmittance=SELECTION

This is the input transmittance used to detect filter changes. When set this is used for all channels and all instruments so it normally only makes sense for a single channel.

Default: Resolved automatically by instrument suffix

Arguments

If no bare word input specification is supplied then data are read from standard input.

station

This argument is used to specify the station used to look up variables that do not include a station as part of an archive read specification. The station is the three letter GAW station code of the location, such as BND. The argument accepts multiple stations specified as regular expressions and separated by : or ; or ,. For example BND,MLO and (BND|MLO) are two ways of selecting both the BND and MLO stations.

The special value allstations may also be specified to select all stations.

variables

This argument may be split into multiple actual program arguments. Each part consists of one or more variable specifications separated by , (commas). The station and archive used if none are explicitly given are defined in the other arguments or inferred from system defaults. For example simply BsB_S11 selects the blue scattering from the S11 instrument and returns all cut sizes and metadata. If instead ::BsB_S11:pm10 is used then only PM10 scattering is returned. That is, the selection specifies "any" station and archive (the defaults are set in the other arguments) then requires that it has the "PM10" flavor. A specification such as bnd:BsB_S11,thd:BsB_S11 allows for data selection from multiple stations.

This may also be used to select a "record" type alias such as "S11a". In this mode all the variables defined in the alias are returned.

Finally the special value everything can be used to select all available data for the given station(s) and archive(s).

times

This argument may be split into multiple actual program arguments. This full list of time arguments defines a time bounds list that sets the range of data queried. The final resulting data are clipped to the given time bounds but any values that intersect them are returned.

archive

This argument is used to specify the archive used to look up variables that do not include an archive as part of an archive read specification. The archive is the internal name, such as raw or clean_meta. The argument accepts multiple archives specified as regular expressions and separated by : or ; or ,. For example raw(_meta)? selects both the raw and raw_meta archives.

The special value allarchives may also be used to select all available archives.

file

This argument is used to specify the the file to read data from. If it is present and exists then data is read from the given file name instead of from standard input. Alternatively - (a single dash) may be used to explicitly specify standard input.

Examples

Defaults

This will calculate all optical depths for any instrument that provides a transmittance using any available extensive parameters.

da.calc.opticaldepth bnd S11a 2015-05-01 2015-05-03

Or:

da.calc.opticaldepth input_file.c3d

Or:

da.get bnd S11a 2015-05-01 2015-05-03 | da.calc.opticaldepth
Restricted instruments

This will calculate scattering optical depth from S12 and absorption optical depth from A12 based on the filter of A11 regardless of what data is present in the input.

da.calc.opticaldepth --absorption-instruments=A12 --extinction-instruments= --instruments=A11 --scattering-instruments=S12 bnd S11a 2015-05-01 2015-05-03
Explicit scattering

This will calculate optical depth using only green scattering from the S11 instrument.

da.calc.opticaldepth --backscattering=bnd:raw:BbsG_S11 --scattering=bnd:raw:BsG_S11 bnd S11a 2015-05-01 2015-05-03