From 81640d30f96d40aa1f649c3f1d0f54f2b9fb96df Mon Sep 17 00:00:00 2001 From: Sebastianw Wehling-Benatelli Date: Wed, 31 Aug 2016 13:41:18 +0200 Subject: [PATCH] [refs #200] ongoing work on parameter derivation --- QtPyLoT.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/QtPyLoT.py b/QtPyLoT.py index 8c8f9926..1a0ff6d2 100755 --- a/QtPyLoT.py +++ b/QtPyLoT.py @@ -947,7 +947,14 @@ class MainWindow(QMainWindow): self.getData().applyEVTData(lt.read_location(locpath), type='event') def calc_magnitude(self): - if self.getData().getEvtData().origins: + e = self.getData().getEvtData() + if e.origins: + o = e.origins[0] + for a in o.arrivals: + pid = a.pick_id + pick = pid.get_referred_object() + station = self.getStationID(pick.waveform_id.station_code) + wf = self.getData().getWFData().select(station=station) mag = None return mag else: