code: def select_catalogue_within_cell(self, selector, distance,
                                       upper_depth=None, lower_depth=None):
          '''
          Selects catalogue of earthquakes within distance from point
  
          :param selector:
              Populated instance of :class:
              `openquake.hmtk.seismicity.selector.CatalogueSelector`
          :param distance:
              Distance from point (km) for selection
          '''
  
          self.catalogue = selector.cartesian_square_centred_on_point(
              self.geometry, distance)
  
          if self.catalogue.get_number_events() < 5:
              # Throw a warning regarding the small number of earthquakes in
              # the source!
              warnings.warn('Source %s (%s) has fewer than 5 events'
                            % (self.id, self.name)f select_catalogue_within_cell(self, selector, distance,
                                       upper_depth=None, lower_depth=None):
          '''
          Selects catalogue of earthquakes within distance from point
  
          :param selector:
              Populated instance of :class:
              `openquake.hmtk.seismicity.selector.CatalogueSelector`
          :param distance:
              Distance from point (km) for selection
          '''
  
          self.catalogue = selector.cartesian_square_centred_on_point(
              self.geometry, distance)
  
          if self.catalogue.get_number_events() < 5:
              # Throw a warning regarding the small number of earthquakes in
              # the source!
              warnings.warn('Source %s (%s) has fewer than 5 events'
                            % (self.id, self.name))
docs: Selects catalogue of earthquakes within distance from point
  
          :param selector:
              Populated instance of :class:
              `openquake.hmtk.seismicity.selector.CatalogueSelector`
          :param distance:
              Distance from point (km) for selection