Reading events from an Antelope database - geoscience-community-codes/GISMO GitHub Wiki

To load event data from an Antelope/Datascope CSS3.0 database you will need to have [Antelope] (http://www.brtt.com/software.html) installed, including the Antelope toolbox for MATLAB.

SCAFFOLD: NOTE THAT CURRENTLY NOT USING THE RTDB200903 AT ALL !!!!!!!!

For the purpose of this exercise we will be using data from Redoubt volcano from 2009/03/20 to 2009/03/23. We will use snippets from two catalogs that are provided with GISMO in Antelope format:

  • The real-time catalog (rtdb200903).
  • The analyst-reviewed offical AVO catalog (avodb200903).

Both catalog segments are included in the "demo" directory. We will now load the official AVO catalog into an Events object:

>> if admin.antelope_exists
       dbpath = demodb('avo');
       catalogObject = readEvents('antelope', 'dbpath', dbpath);
   end

This should load 1441 events. What if we only want events within 20km of Redoubt volcano? The optional parameter 'subset_expression' can be used, with an appropriate Datascope expression, e.g.

>> redoubtLon = -152.7431; redoubtLat = 60.4853;
>> if admin.antelope_exists
       catalogObject = readEvents('antelope', 'dbpath', dbpath, ...
              'subset_expression', 'deg2km(distance(lat, lon, redoubtLat, redoubtLon))<20.0');
   end

Now there should be 1397 events. Let's save this dataset to a MAT file:

>> catalogObject.save('avo_redoubt.mat')