rcmod.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:nelpy 作者: nelpy 项目源码 文件源码
def setup(context="notebook", style="ticks", palette="sweet",
        font="sans-serif", font_scale=1, rc=None):
    """Set aesthetic figure parameters.

    Each set of parameters can be set directly or temporarily, see the
    referenced functions below for more information.

    Parameters
    ----------
    context : string or dict
        Plotting context parameters, see :func:`plotting_context`
    style : string or dict
        Axes style parameters, see :func:`axes_style`
    palette : string or sequence
        Color palette, see :func:`color_palette`
    font : string
        Font family, see matplotlib font manager.
    font_scale : float, optional
        Separate scaling factor to independently scale the size of the
        font elements.
    rc : dict or None
        Dictionary of rc parameter mappings to override the above.

    """
    set_context(context, font_scale)
    set_style(style, rc={"font.family": font})
    set_palette(palette=palette)
    if rc is not None:
        mpl.rcParams.update(rc)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号