def plot(self, channel_names, kind='histogram',
             gates=None, gate_colors=None,
             ids=None, row_labels=None, col_labels=None,
             xlim='auto', ylim='auto',
             autolabel=True,
             **kwargs):
        """
        Produces a grid plot with each subplot corresponding to the data at the given position.

        Parameters
        ---------------
        {FCMeasurement_plot_pars}
        {graph_plotFCM_pars}
        {_graph_grid_layout}

        Returns
        -------
        {_graph_grid_layout_returns}

        Examples
        --------

        Below, plate is an instance of FCOrderedCollection

        >>> plate.plot(['SSC-A', 'FSC-A'], kind='histogram', autolabel=True)
        >>> plate.plot(['SSC-A', 'FSC-A'], xlim=(0, 10000))
        >>> plate.plot(['B1-A', 'Y2-A'], kind='scatter', color='red', s=1, alpha=0.3)
        >>> plate.plot(['B1-A', 'Y2-A'], bins=100, alpha=0.3)
        >>> plate.plot(['B1-A', 'Y2-A'], bins=[linspace(-1000, 10000, 100), linspace(-1000, 10000, 100)], alpha=0.3)

        .. note::

            For more details see documentation for FCMeasurement.plot
            **kwargs passes arguments to both grid_plot and to FCMeasurement.plot.
        """
        ##
        # Note
        # -------
        # The function assumes that grid_plot and FCMeasurement.plot use unique key words.
        # Any key word arguments that appear in both functions are passed only to grid_plot in the end.

        ##
        # Automatically figure out which of the kwargs should
        # be sent to grid_plot instead of two sample.plot
        # (May not be a robust solution, we'll see as the code evolves

        grid_arg_list = inspect.getargspec(OrderedCollection.grid_plot).args

        grid_plot_kwargs = {'ids': ids,
                            'row_labels': row_labels,
                            'col_labels': col_labels}

        for key, value in list(kwargs.items()):
            if key in grid_arg_list:
                kwargs.pop(key)
                grid_plot_kwargs[key] = value

        ##
        # Make sure channel names is a list to make the code simpler below
        channel_names = to_list(channel_names)

        ##
        # Determine data limits for binning
        #

        if kind == 'histogram':
            nbins = kwargs.get('bins', 200)

            if isinstance(nbins, int):
                min_list = []
                max_list = []
                for sample in self:
                    min_list.append(self[sample].data[channel_names].min().values)
                    max_list.append(self[sample].data[channel_names].max().values)

                min_list = list(zip(*min_list))
                max_list = list(zip(*max_list))

                bins = []

                for i, c in enumerate(channel_names):
                    min_v = min(min_list[i])
                    max_v = max(max_list[i])
                    bins.append(np.linspace(min_v, max_v, nbins))

                # Check if 1d
                if len(channel_names) == 1:
                    bins = bins[0]  # bins should be an ndarray, not a list of ndarrays

                kwargs['bins'] = bins

        ##########
        # Defining the plotting function that will be used.
        # At the moment grid_plot handles the labeling
        # (rather than sample.plot or the base function
        # in GoreUtilities.graph

        def plot_sample(sample, ax):
            return sample.plot(channel_names, ax=ax,
                               gates=gates, gate_colors=gate_colors,
                               colorbar=False,
                               kind=kind, autolabel=False, **kwargs)

        xlabel, ylabel = None, None

        if autolabel:
            cnames = to_list(channel_names)
            xlabel = cnames[0]
            if len(cnames) == 2:
                ylabel = cnames[1]

        return self.grid_plot(plot_sample, xlim=xlim, ylim=ylim,
                              xlabel=xlabel, ylabel=ylabel,
                              **grid_plot_kwargs)
Produces a grid plot with each subplot corresponding to the data at the given position.

        Parameters
        ---------------
        {FCMeasurement_plot_pars}
        {graph_plotFCM_pars}
        {_graph_grid_layout}

        Returns
        -------
        {_graph_grid_layout_returns}

        Examples
        --------

        Below, plate is an instance of FCOrderedCollection

        >>> plate.plot(['SSC-A', 'FSC-A'], kind='histogram', autolabel=True)
        >>> plate.plot(['SSC-A', 'FSC-A'], xlim=(0, 10000))
        >>> plate.plot(['B1-A', 'Y2-A'], kind='scatter', color='red', s=1, alpha=0.3)
        >>> plate.plot(['B1-A', 'Y2-A'], bins=100, alpha=0.3)
        >>> plate.plot(['B1-A', 'Y2-A'], bins=[linspace(-1000, 10000, 100), linspace(-1000, 10000, 100)], alpha=0.3)

        .. note::

            For more details see documentation for FCMeasurement.plot
            **kwargs passes arguments to both grid_plot and to FCMeasurement.plot.