Man page for scgts4ag
USAGE:
scgts4ag [-O <dest-dir>] [options]
{ set-file | drop-files... }
PURPOSE:
Prepares 1s SCG data suitable for sampling at drop times.
Output file name is derived from label and date, e.g.
G_V_091106-1s.ts
Optionally produces the sampled AG+SCG tsf-files, the
.smp-files.
The path/name of a .smp file will be:
./<dest-dir>/<dfbn><mark>.smp
where dfbn = `basename drop-file .txt`
Default mark = <empty> ; use the -M option to define
one.
Production of MC-files is not included since you might want
to concatenate some .smp-files. Consider ~/TD/agsmp2mc
A catalog dest-dir/files.lst
(~/TD/a/Allsmp/files.lst) is maintained:
<smp-file> <ag-file> = <AG-file(resolved
link)> <SCG-file> <Julian-start>
You ought to keep a backup-copy.
This script should be issued from ~/TD
OPTIONS:
-no-prompt | -GO
- avoid a few pauses
{-new|-old|-upd} <campaign>
- is compulsory, introducing a campaign name.
-new - ..
-upd - currently no difference, backup existing
${odir}files.lst
-old - don't change ${odir}files.lst
-always-enough - By
default, projects must have a duration of 1/2 day at
least.
The test can be by-passed with this option.
-O dest-dir
- destination directory, `/´ will be appended
Default: ./o/ Is significant for the -S
option,
so the -O option should be given early.
Usually: -O a/Allsmp
-ts outf-template - Template
for the BIN-ts output file name,
Default is ${fnb}_${mrk}_%-1s.ts
, where
fnb = label part-1 of the SCG
input file,
mrk = label part-2
`%L´ will be replaced by the label part-1_part-2
`%´ will be replaced by the project's start date.
-M mark
- Your choice, adding a short string to the ASCII-file names.
Consider a first letter to make it read easy, like -abcd
-S { - | tse-file } - Do the
sampling stage. By default, only the SCG data
retrieval is carried out. If the sampling command file
(the tse-file) is given, the name will be prepended
with the dest-dir path; therefore: Don't specify a path here.
A `%´ character will be replaced with the drop-file
basename
(`.txt´ is cut away):
Sampling result:
If drop file name = a/b/AS_2010Apr18a.drop.txt
and dest-dir = c/d
then the file that is produced is
c/d/AS_2010Apr18a.drop<mark>.smp
By default, mark = <empty>. To define one, use
-M mark
The tse-file can be re-used in a tslist invocation;
then the name of the result file for the sampling process
must be set in the environment, parameter SMPRESULT,
else the default ./tmp.smp will be in effect.
Default tse-file: ./tmp/smp.tse
-T #offs
- under -S
Offset the sample time by #offs seconds (integer).
procag.pl is called with -T #offs
instead of -S
The resulting tse-file will have records
SAMPLE O=#offs At ....
If offset changes, process one project at a
time!
-sigma
- Select column "Sigma" for weighting.
Default = "Error" (!)
-E tse-file,trg
- a tsfedit file for filtering (please no decimation!)
Default: ~/TD/deci.tse,F30
The purpose is to mitigate microseismic noise in the SG.
-E NONE
- assume that SCG-file is already filtered for microseisms.
-d dt-mark
- the time-interval part of the file name if
decimation is necessary.
Default = -1s for no decimation. Implemented?
-Ed tse-file,trg dt-mark
- combines options -E -d
-SCG inf-template -
template for path and name of the SCG mc-files (input).
Default: ~/TD/d/G1_garb_%%%%%%-1s.mc
Must contain six %'s as a wildcard for the date YYMMDD
-L label
- The label for the SCG-data from G1_garb -files
Default: 'G|V'
-L NONE
- ... if the files are unlabeled.
-ilp
- "input low-passed data",
combines the options -SCG -L NONE ~/TD/tmp/G1_g_%%%%%%-1s.ts
-U
- Use this option if SCG data is in Volt.
Default is to restore to original Volt values.
Hard-wired value: -774.421 nm/s^2/V ( applied as -SO/$scale
)
-u #add
-
Similar to -U ; in addition this option supplies a
constant
that is added to the sampled SCG series.
-C component
- The component of the AG-files (string in table-head)
Default: G_inst (the special "instantaneous"
g-value)
-f
- force recalculation of SCG-files (with tslapp / tslist)
-t
- "Test", don't produce anything, only show the commands
that would be issued (with -n produce a new files.lst
-n
- create a new file catalog dest-dir/file.lst from
scratch.
If you want to create a new files.lst without sampling,
combine -t -n
-fl newfiles.lst -
catalog to this file instead [files.lst]
EXAMPLES:
cd
~/TD
scgts4ag -O a/Allsmp -sigma -S - a/Alldrops/*.drop.txt
scgts4ag -O a/Allsmp -sigma -S
%.smp.tse -n a/Alldrops/*.drop.txt
In the second example, one of the sampling command path-and-file
names
will be a/Allsmp/Onsala_AA_20130422a.drop.smp.tse
scgts4ag
-O a/Allsmp -sigma -S - -L
'G|B' -u -3900 -M .red -C G_red \
a/Alldrops/AA_2009Nov06a.drop.txt
will retrieve AG-data with the g-soft model applied (G_red)
and SCG-data with the models applied (label GRAV|BRES).
This exceptional
content is emphasized with the mark ".red" in the resulting
smp-file name.
By virtue of -u -3900 , the SCG-values are in nm/s^2
and 3900 nm/s^2 is subtracted.
The resulting smp-file is ./a/Allsmp/AA_2009Nov06a.drop.red.smp
scgts4ag -no-prompt -upd 201502b -O a/Allsmp-s
-always-enough \
-SCG
tmp/G1_g_%%%%%%-1s.ts -L NONE -E NONE -n -S %.smp.tse \
a/Alldrops/*A?_201502*.drop.txt > ! scgts4ag.log
uses un-besseled SCG-files (unlabeled
ts-files => -L NONE )
that need no further lp-filtering
(=> -E NONE ) and puts the
result files
.bye