Learn R Programming

RSEIS (version 2.1-6)

setupDB: Set up a seismic data base

Description

Set up a data base storing the location and times for a set of seismic data.

Usage

setupDB(DB, token = TRUE, split = "\\.")

Arguments

DB
[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
token
logical, use tokens in the file names of the fn's to extract station and component names for selection. default=TRUE
split
character string to split if using token, default is a period.

Value

  • DB with epoch time and station information appended,
  • t1epoch start time
  • t2expoch end time = t1+nsamps*sample rate n seconds
  • stastation
  • compcomponent

Details

If token is FALSE, then the station name and component are selected using substr, i.e. by column number.

See Also

EPOCHday, T12.pix, Mine.seis

Examples

Run this code
###  location of data base file
datadir1 = '/home/lees/Site/Santiaguito/SG09'
d1 = 'segyDB'
#### scan in the data base file
DB = scan(file=paste(sep="/", datadir1, d1), list(fn="", yr=0, jd=0,
hr=0, mi=0, sec=0, dur=0))
#### interactively fix the DB list
DB = setupDB(DB)

Run the code above in your browser using DataLab