def setUp(self): ''' Set up test class ''' filename = os.path.join(BASE_DATA_PATH,'completeness_test_cat.csv') parser0 = CsvCatalogueParser(filename) self.catalogue = parser0.read_file() self.config = {'b-value': 1.0, 'input_mmin': 5.0, 'input_mmax': None, 'tolerance': 0.001, 'maximum_iterations': 1000} self.model = KijkoSellevolFixedb()
# Plot magnitude time density from hmtk.plotting.seismicity.catalogue_plots import plot_magnitude_time_density magnitude_bin = 0.2 time_bin = 10.0 plot_magnitude_time_density(catalogue, magnitude_bin, time_bin) # In[ ]: mmax_config = { 'b-value': 1.0, 'input_mmin': 4.5, 'input_mmax': None, 'input_mmax_uncertainty': 0.5 } mmax_ks = KijkoSellevolFixedb() mmax, mmax_sigma = mmax_ks.get_mmax(catalogue, mmax_config) print 'Mmax = %8.3f +/- %8.3f' % (mmax, mmax_sigma) # In[ ]: mmax_config = { 'b-value': 1.0, 'sigma-b': 0.05, 'input_mmin': 4.5, 'input_mmax': None, 'input_mmax_uncertainty': 0.5 }