code: def closest(self, coords=[], **kwargs):
          
          if kwargs and coords:
              raise ValueError("Specify coordinate using as either a list "
                               "keyword arguments not both")
          if kwargs:
              coords = []
              getter = []
              for k, v in kwargs.items():
                  idx = self.get_dimension_index(k)
                  if np.isscalar(v):
                      coords.append((0, v) if idx else (v, 0))
                  else:
                      if isinstance(v, list):
                          coords = [(0, c) if idx else (c, 0) for c in v]
                      if len(coords) not in [0, len(v)]:
                          raise ValueError("Length of samples must match")
                      elif len(coords):
                          coords = [(t[abs(idx-1)], c) if idx else (c, t[abs(idx-1)])
                                    for c, t in zip(v, coords)]
                  getter.append(idx)
          else:
              getter = [0, 1]
          getter = itemgetter(*sorted(getter))
          if len(coords) == 1:
              coords = coords[0]
          if isinstance(coords, tuple):
              return getter(self.closest_cell_center(*coords))
          else:
              return [getter(self.closest_cell_center(*el)) for el in coords]
docs: Given a single coordinate or multiple coordinates as
          a tuple or list of tuples or keyword arguments matching
          the dimension closest will find the closest actual x/y
          coordinates.