How to use the psyplot.docstring.docstrings.get_sectionsf function in psyplot

To help you get started, we’ve selected a few psyplot examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Chilipp / psyplot / psyplot / project.py View on Github external
    @docstrings.get_sectionsf('Project.scp')
    @dedent
    def scp(cls, project):
        """
        Set the current project

        Parameters
        ----------
        project: Project or None
            The project to set. If it is None, the current subproject is set
            to empty. If it is a sub project (see:attr:`Project.is_main`),
            the current subproject is set to this project. Otherwise it
            replaces the current main project

        See Also
        --------
        scp: The global version for setting the current project
github Chilipp / psyplot / psyplot / project.py View on Github external
    @docstrings.get_sectionsf('Project.close')
    @dedent
    def close(self, figs=True, data=False, ds=False, remove_only=False):
        """
        Close this project instance

        Parameters
        ----------
        figs: bool
            Close the figures
        data: bool
            delete the arrays from the (main) project
        ds: bool
            If True, close the dataset as well
        remove_only: bool
            If True and `figs` is True, the figures are not closed but the
            plotters are removed"""
github Chilipp / psyplot / psyplot / __main__.py View on Github external
@docstrings.get_sectionsf('make_plot')
@docstrings.dedent
def make_plot(fnames=[], name=[], dims=None, plot_method=None,
              output=None, project=None, engine=None, formatoptions=None,
              tight=False, rc_file=None, encoding=None, enable_post=False,
              seaborn_style=None, output_project=None,
              concat_dim=get_default_value(xr.open_mfdataset, 'concat_dim'),
              chname={}):
    """
    Eventually start the QApplication or only make a plot

    Parameters
    ----------
    fnames: list of str
        Either the filenames to show, or, if the `project` parameter is set,
        the a list of `,`-separated filenames to make a mapping from the
        original filename to a new one
github Chilipp / psyplot / psyplot / plotter.py View on Github external
    @docstrings.get_sectionsf('Formatoption.set_value')
    @dedent
    def set_value(self, value, validate=True, todefault=False):
        """
        Set (and validate) the value in the plotter. This method is called by
        the plotter when it attempts to change the value of the formatoption.

        Parameters
        ----------
        value
            Value to set
        validate: bool
            if True, validate the `value` before it is set
        todefault: bool
            True if the value is updated to the default value"""
        # do nothing if the key is shared
        if self.key in self.plotter._shared:
github Chilipp / psyplot / psyplot / project.py View on Github external
    @docstrings.get_sectionsf('Project')
    @docstrings.dedent
    def __init__(self, *args, **kwargs):
        """
        Parameters
        ----------
        %(ArrayList.parameters)s
        main: Project
            The main project this subproject belongs to (or None if this
            project is the main project)
        num: int
            The number of the project
        """
        self.main = kwargs.pop('main', None)
        self._plot = ProjectPlotter(self)
        self.num = kwargs.pop('num', 1)
        self._ds_counter = count()
github Chilipp / psyplot / psyplot / plotter.py View on Github external
    @docstrings.get_sectionsf('Plotter.unshare_me')
    @docstrings.dedent
    def unshare_me(self, keys=None, auto_update=False, draw=None,
                   update_other=True):
        """
        Close the sharing connection of this plotter with others

        This method undoes the sharing connections made by the :meth:`share`
        method and release this plotter again.

        Parameters
        ----------
        keys: string or iterable of strings
            The formatoptions to unshare, or group names of formatoptions to
            unshare all formatoptions of that group (see the
            :attr:`fmt_groups` property). If None, all formatoptions of this
            plotter are unshared.
github Chilipp / psyplot / psyplot / plotter.py View on Github external
    @docstrings.get_sectionsf('Plotter._register_update')
    @docstrings.dedent
    def _register_update(self, fmt={}, replot=False, force=False,
                         todefault=False):
        """
        Register formatoptions for the update

        Parameters
        ----------
        fmt: dict
            Keys can be any valid formatoptions with the corresponding values
            (see the :attr:`formatoptions` attribute)
        replot: bool
            Boolean that determines whether the data specific formatoptions
            shall be updated in any case or not.
        %(InteractiveBase._register_update.parameters.force|todefault)s"""
        if self.disabled:
github Chilipp / psyplot / psyplot / plotter.py View on Github external
    @docstrings.get_sectionsf('Plotter')
    @docstrings.dedent
    def __init__(self, data=None, ax=None, auto_update=None, project=None,
                 draw=False, make_plot=True, clear=False,
                 enable_post=False, **kwargs):
        """
        Parameters
        ----------
        data: InteractiveArray or ArrayList, optional
            Data object that shall be visualized. If given and `plot` is True,
            the :meth:`initialize_plot` method is called at the end. Otherwise
            you can call this method later by yourself
        ax: matplotlib.axes.Axes
            Matplotlib Axes to plot on. If None, a new one will be created as
            soon as the :meth:`initialize_plot` method is called
        %(InteractiveBase.parameters.auto_update)s
        %(InteractiveBase.start_update.parameters.draw)s