integrate the array with the trapezoidal rule.

        .. note::
            This feature is limited to simple cartesian geometry, i.e. coord
            must be one dimensional.

        Parameters
        ----------
        dim: str, or a sequence of str
            Coordinate(s) used for the integration.
        datetime_unit
            Can be specify the unit if datetime coordinate is used. One of
            {'Y', 'M', 'W', 'D', 'h', 'm', 's', 'ms', 'us', 'ns', 'ps', 'fs',
             'as'}

        Returns
        -------
        integrated: Dataset

        See also
        --------
        DataArray.integrate
        numpy.trapz: corresponding numpy function

def integrate(self, coord, datetime_unit=None):
        """ integrate the array with the trapezoidal rule.

        .. note::
            This feature is limited to simple cartesian geometry, i.e. coord
            must be one dimensional.

        Parameters
        ----------
        dim: str, or a sequence of str
            Coordinate(s) used for the integration.
        datetime_unit
            Can be specify the unit if datetime coordinate is used. One of
            {'Y', 'M', 'W', 'D', 'h', 'm', 's', 'ms', 'us', 'ns', 'ps', 'fs',
             'as'}

        Returns
        -------
        integrated: Dataset

        See also
        --------
        DataArray.integrate
        numpy.trapz: corresponding numpy function
        """
        if not isinstance(coord, (list, tuple)):
            coord = (coord, )
        result = self
        for c in coord:
            result = result._integrate_one(c, datetime_unit=datetime_unit)
        return result