dbpick_combine [-v] [-keep outputdb] [-chan channel_subset] [-start start_time] [-end end_time] {-sta station_subset | -nearby sta [-dist distance]} db1 db2
dbpick_combine subsets the arrival, site, and wfdisc tables from the input databases, db1 and db2 and makes them available in the output database used for dbpick. You must have a site table available for db1 if you are using the -nearby option. No attempts are made to clean up duplicate picks or "del" picks from the input database. The arrival table is not necessary.
A dbpick waveform window is generated with the dbpick prompt appearing in the same window where you run the dbpick_combine command. Make sure you type "quit" at the dbpick prompt rather than using Cntrl-C or the window manager close button on the waveform display window. Not following this step may result in the temporary database cleanup failing.
At the moment, negative subsets are not allowed./BHZ/ /BH[ZNE]|VM./ /L.*/
Either the -sta or -nearby option must be specified./A04A/ /N0.A|M1.A/ /L.*/
/tmp/db1.arrival /tmp/db1.site /tmp/db1.wfdisc /tmp/db2.arrival /tmp/db2.site /tmp/db2.wfdisc
Temporary database files are also created in the directory of the input databases. They look something like: dbpick_combine19166 and should be automatically removed upon exit of the program unless -keep is used. See BUGS AND CAVEATS!
%dbpick_combine -nearby "A04A" -dist 1.0 -chan "/BH.|VM./" -start 2006245:00:00:00 db/usarray db2/usarray2
%dbpick_combine -nearby "40:-115" -chan "/BH.*/" db/usarray db2/usarray2
%dbpick_combine -sta "/A04A|B04A|C04A|A03A/" -chan "/BH./" db/usarray db2/usarray2
I have seen errors like:
when this program is run on large real-time databases. I have not been able to reliably reproduce the error yet. The only work-around I can suggest is that you use -end with a time before the most recent time in the wfdisc table.2007-234 16:25:49 dbcp *log*: Bad record id 81 in db pointer 2007-234 16:25:49 dbcp *log*: bad db type in dbputv
dbpick(1)
This was "in shop" code that I am freeing into the world. It may not do what you want it to do, but it worked for me. Requests for upgrades and changes may be taken into consideration, but action on them may take a long while.
No support yet for expanded subsetting capabilities (i.e. sta !~/A0.*/ && sta=~/A1.*/). I am considering this and may end up re-writing code in such a way that may not be backward compatible with the -sta and -nearby options.
Better error message and check is needed if the -sta subset is for a station that is not in the site table.
Can leave detritus database files and descriptors around if program exits abnormally.
Some of the subsets can take a significant amount of time if the database tables are large. Have patience.
There are some rm commands in this script. Bad choice of input dbs could cause an important database to be removed. Please do not use /tmp/db1.wfdisc or /tmp/db2.wfdisc as either of your input databases. Save a backup of the input dbs if you are paranoid like me.
The -keep option is untested at the moment....
Jennifer Eakins ANF Univ. of California, San Diego