def readSTATION0(path, stations):
stalist = []<EOL>f = open(path + '<STR_LIT>', '<STR_LIT:r>')<EOL>for line in f:<EOL><INDENT>if line[<NUM_LIT:1>:<NUM_LIT:6>].strip() in stations:<EOL><INDENT>station = line[<NUM_LIT:1>:<NUM_LIT:6>].strip()<EOL>lat = line[<NUM_LIT:6>:<NUM_LIT>]  <EOL>if lat[-<NUM_LIT:1>] == '<STR_LIT:S>':<EOL><INDENT>NS = -<NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>NS = <NUM_LIT:1><EOL><DEDENT>if lat[<NUM_LIT:4>] == '<STR_LIT:.>':<EOL><INDENT>lat = (int(lat[<NUM_LIT:0>:<NUM_LIT:2>]) + float(lat[<NUM_LIT:2>:-<NUM_LIT:1>]) / <NUM_LIT>) * NS<EOL><DEDENT>else:<EOL><INDENT>lat = (int(lat[<NUM_LIT:0>:<NUM_LIT:2>]) + float(lat[<NUM_LIT:2>:<NUM_LIT:4>] + '<STR_LIT:.>' + lat[<NUM_LIT:4>:-<NUM_LIT:1>]) /<EOL><NUM_LIT>) * NS<EOL><DEDENT>lon = line[<NUM_LIT>:<NUM_LIT>]<EOL>if lon[-<NUM_LIT:1>] == '<STR_LIT>':<EOL><INDENT>EW = -<NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>EW = <NUM_LIT:1><EOL><DEDENT>if lon[<NUM_LIT:5>] == '<STR_LIT:.>':<EOL><INDENT>lon = (int(lon[<NUM_LIT:0>:<NUM_LIT:3>]) + float(lon[<NUM_LIT:3>:-<NUM_LIT:1>]) / <NUM_LIT>) * EW<EOL><DEDENT>else:<EOL><INDENT>lon = (int(lon[<NUM_LIT:0>:<NUM_LIT:3>]) + float(lon[<NUM_LIT:3>:<NUM_LIT:5>] + '<STR_LIT:.>' + lon[<NUM_LIT:5>:-<NUM_LIT:1>]) /<EOL><NUM_LIT>) * EW<EOL><DEDENT>elev = float(line[<NUM_LIT>:-<NUM_LIT:1>].strip())<EOL>if line[<NUM_LIT:0>] == '<STR_LIT:->':<EOL><INDENT>elev *= -<NUM_LIT:1><EOL><DEDENT>stalist.append((station, lat, lon, elev))<EOL><DEDENT><DEDENT>f.close()<EOL>f = open('<STR_LIT>', '<STR_LIT:w>')<EOL>for sta in stalist:<EOL><INDENT>line = '<STR_LIT>'.join([sta[<NUM_LIT:0>].ljust(<NUM_LIT:5>), _cc_round(sta[<NUM_LIT:1>], <NUM_LIT:4>).ljust(<NUM_LIT:10>),<EOL>_cc_round(sta[<NUM_LIT:2>], <NUM_LIT:4>).ljust(<NUM_LIT:10>),<EOL>_cc_round(sta[<NUM_LIT:3>] / <NUM_LIT:1000>, <NUM_LIT:4>).rjust(<NUM_LIT:7>), '<STR_LIT:\n>'])<EOL>f.write(line)<EOL><DEDENT>f.close()<EOL>return stalist<EOL>
Read a Seisan STATION0.HYP file on the path given.

    Outputs the information, and writes to station.dat file.

    :type path: str
    :param path: Path to the STATION0.HYP file
    :type stations: list
    :param stations: Stations to look for

    :returns: List of tuples of station, lat, long, elevation
    :rtype: list

    >>> # Get the path to the test data
    >>> import eqcorrscan
    >>> import os
    >>> TEST_PATH = os.path.dirname(eqcorrscan.__file__) + '/tests/test_data'
    >>> readSTATION0(TEST_PATH, ['WHFS', 'WHAT2', 'BOB'])
    [('WHFS', -43.261, 170.359, 60.0), ('WHAT2', -43.2793, \
170.36038333333335, 95.0), ('BOB', 41.408166666666666, \
-174.87116666666665, 101.0)]