# xarray.plot.FacetGrid.map

#### FacetGrid.map(func, \*args, \*\*kwargs)[[source]](https://github.com/pydata/xarray/blob/main/xarray/plot/facetgrid.py#L1033-L1073)

Apply a plotting function to each facet’s subset of the data.

* **Parameters:**
  * **func** ([`callable()`](https://docs.python.org/3/builtins/functions.html#callable)) – A plotting function that takes data and keyword arguments. It
    must plot to the currently active matplotlib Axes and take a
    color keyword argument. If faceting on the hue dimension,
    it must also take a label keyword argument.
  * **\*args** (`Hashable`) – Column names in self.data that identify variables with data to
    plot. The data for each variable is passed to func in the
    order the variables are specified in the call.
  * **\*\*kwargs** (`keyword arguments`) – All keyword arguments are passed to the plotting function.
* **Returns:**
  **self** (`FacetGrid object`)
