Create a 3D filled contour plot. Parameters ---------- X, Y, Z : array-like Input data. See `.Axes.contourf` for supported data shapes. zdir : {'x', 'y', 'z'}, default: 'z' The direction to use. offset : float, optional
(self, X, Y, Z, *args,
zdir='z', offset=None, axlim_clip=False, **kwargs)
| 2980 | |
| 2981 | @_preprocess_data() |
| 2982 | def contourf(self, X, Y, Z, *args, |
| 2983 | zdir='z', offset=None, axlim_clip=False, **kwargs): |
| 2984 | """ |
| 2985 | Create a 3D filled contour plot. |
| 2986 | |
| 2987 | Parameters |
| 2988 | ---------- |
| 2989 | X, Y, Z : array-like |
| 2990 | Input data. See `.Axes.contourf` for supported data shapes. |
| 2991 | zdir : {'x', 'y', 'z'}, default: 'z' |
| 2992 | The direction to use. |
| 2993 | offset : float, optional |
| 2994 | If specified, plot a projection of the contour lines at this |
| 2995 | position in a plane normal to *zdir*. |
| 2996 | axlim_clip : bool, default: False |
| 2997 | Whether to hide lines with a vertex outside the axes view limits. |
| 2998 | |
| 2999 | .. versionadded:: 3.10 |
| 3000 | data : indexable object, optional |
| 3001 | DATA_PARAMETER_PLACEHOLDER |
| 3002 | *args, **kwargs |
| 3003 | Other arguments are forwarded to `matplotlib.axes.Axes.contourf`. |
| 3004 | |
| 3005 | Returns |
| 3006 | ------- |
| 3007 | matplotlib.contour.QuadContourSet |
| 3008 | """ |
| 3009 | had_data = self.has_data() |
| 3010 | |
| 3011 | jX, jY, jZ = art3d.rotate_axes(X, Y, Z, zdir) |
| 3012 | cset = super().contourf(jX, jY, jZ, *args, **kwargs) |
| 3013 | levels = self._add_contourf_set(cset, zdir, offset, axlim_clip) |
| 3014 | |
| 3015 | self._auto_scale_contourf(X, Y, Z, zdir, levels, had_data) |
| 3016 | return cset |
| 3017 | |
| 3018 | contourf3D = contourf |
| 3019 |