*****************
SplitLab Exercise
*****************

***INSTALLATION***
open a terminal and cd into the directory with Splitlab

Install Splitlab by unzipping Splitlab1.0.5.zip

cd Splitlab1.0.5/
matlab
install_splitlab
     - check the boxes for Saclab and matTaup ***note the directory for matTaup***
restart Matlab

in the matlab command window:

addpath /Users/Applications/MATLAB/Splitlab1.0.5/matTaup  ****use appropriate path***
javaaddpath /Users/Applications/MATLAB/Splitlab1.0.5/matTaup/lib/matTaup.jar **use appropriate path**

***DATA****

Use rdseed to convert seed files to SAC
 rdseed -f USArray_exam.pjt.11546.seed -d -b 99999999 -o 1
 rdseed -f TA_W18A.pjt.17235.seed -d -b 99999999 -o 1
 
These are two different station event data. 

****START SPLITLAB****
Start splitlab (by typing splitlab in Matlab command window in the appropriate directory)

In the "General" panel:
    Type a new name (USArray_example.pjt)
    Change the seismic data directory to ~/splitting_data/
    Change the output directory to something like ~/splitting_data/output
    Save the project

Click on the "Station" radio button
    Use IRIS station query to find station of interest
    Enter in lat/long

Click on the "Event window" radio button
    Select start and end dates
    6.25<Mw<9.0
    90<deg<135
    25<km<1000
    make sure "Show statistics plot" on
    click "Search earthquakes"
    Update catalogue file - Update from server

Click on "Save Preferences" on left side of window

*****this part can be omitted as data is already available for you******
Click on the "Request" radio button
    Enter info and use breqfast format, but you must "Add" the address to:
        breq_fast@iris.washington.edu
    Click on "Send request mail"
        copy and paste into browser email

Click on the "Phases" radio button
    Select phases of interest
    Click on "View travel times" to make plot

Click on the "Find Files" radio button
    Use *.SAC for search string
    Use "RDSEED" for format
    Click on SAC-header extract times
    Click on Automatically associate SAC-files
    
Click on "Save Project As"

Click on "View Database"
    creates a map of events and station
    creates a table of the events 

Click on "View Seismograms"
    Click on question mark in Preview window to get list of help items
    Zoom in and out to look at arrivals
    Use number keys to filter the seismograms
    Use "Home" button on computer to zoom to SKS
    Click and drag to select time window with greyed out shading
    "Enter" button on keyboard to calcuate splits
    Define Quality in pull down menu
    Mark as "IsNull" or not 
    Save Figure if good
    Click right facing arrow in Preview window to get the next seismogram
    Save the Project


*************
Documentation
*************

http://www.gm.univ-montp2.fr/splitting/