# Open a connection to IRIS DMC webservices
iris <- new("IrisClient")
# Date of Nisqually quake
starttime <- as.POSIXct("2001-02-28",tz="GMT")
endtime <- starttime + 2*24*3600
# Use the getEvent web service to determine what events happened in this time period
events <- getEvent(iris,starttime,endtime,6.0)
events
# Event #3 is the Nisqually quake in Washington State
e <- events[3,]
# Which stations in the US network are within 5 degrees of the quake epicenter?
stations <- getStation(iris,"US","*","*","BHZ",starttime,endtime,
lat=e$latitude,long=e$longitude,maxradius=5)
stations
# Get some detailed information on any BHZ channels at the "Octopus Mountain" station
channels <- getChannel(iris,"US","OCWA","*","BHZ",starttime,endtime)
channelsRun the code above in your browser using DataLab