obspy.neries.client.Client.saveWaveform¶
- Client.saveWaveform(filename, network, station, location, channel, starttime, endtime, format=u'MSEED')[source]¶
Writes a retrieved waveform directly into a file.
This method ensures the storage of the unmodified waveform data delivered by the NERIES Web service, e.g. preserving the record based quality flags of MiniSEED files which would be neglected reading it with obspy.mseed.
Parameters: - filename (str) Name of the output file.
- network (str) Network code, e.g. 'BW'.
- station (str) Station code, e.g. 'MANZ'.
- location (str) Location code, e.g. '01'. Location code may contain wild cards.
- channel (str) Channel code, e.g. 'EHE'. Channel code may contain wild cards.
- starttime (UTCDateTime) Start date and time.
- endtime (UTCDateTime) End date and time.
- format (str, optional) Output format. Either as full SEED ('FSEED') or Mini-SEED ('MSEED') volume. Defaults to 'MSEED'.
Returns: None
Example
>>> from obspy.neries import Client >>> c = Client(user='test@obspy.org') >>> dt = UTCDateTime("2009-04-01T00:00:00") >>> st = c.saveWaveform("outfile.fseed", "NL", "WIT", "", "BH*", ... dt, dt+30, format="FSEED")