Plots a two dimensional representation of the firing rates.
            Each spike is binned according to two labels (`label_x`='x' and `label_y`='y'),
            which give a 2d histogram with `bins` many bins in each direction.
            By default, the number of bins orients itself on the dimensions of the 
            respective labels, sampling them from the minimum to the maximum with 
            `resolution`, which defaults to 1. 

            `bins` and `resolution` can be tuples corresponding to the x and y values.

def plot_spatial_firing_rate(self,label_x='x',label_y='y',bins=None,resolution=1.0,geometry=None,weight_function=None,normalize_time=True,normalize_n=False,start_units_with_0=True,**kwargs):
        """
            Plots a two dimensional representation of the firing rates.
            Each spike is binned according to two labels (`label_x`='x' and `label_y`='y'),
            which give a 2d histogram with `bins` many bins in each direction.
            By default, the number of bins orients itself on the dimensions of the 
            respective labels, sampling them from the minimum to the maximum with 
            `resolution`, which defaults to 1. 

            `bins` and `resolution` can be tuples corresponding to the x and y values.

        """
        if bool(self):
            import matplotlib.pylab as plt
            if bins is None:
                if type(resolution) is tuple:
                    bins = (self.linspace_bins(label_x,resolution=resolution[0]),self.linspace_bins(label_y,resolution=resolution[1]))
                else:
                    bins = (self.linspace_bins(label_x,resolution=resolution),self.linspace_bins(label_y,resolution=resolution))
            H,xed,yed = self.spatial_firing_rate(label_x=label_x,label_y=label_y,bins=bins,geometry=geometry,weight_function=weight_function,normalize_time=normalize_time,normalize_n=False,start_units_with_0=start_units_with_0)
            Y, X = np.meshgrid(yed, xed)
            kwargs['cmap'] = kwargs.get('cmap','gray')
            plt.pcolormesh(X, Y, H,**kwargs)
            plt.gca().set_aspect('equal')