{
  "__type": "IngestedDoc",
  "__tag": 4010,
  "_content": {
    "Notes": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Warns": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Raises": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Yields": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Methods": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Returns": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Summary": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "::"
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Receives": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Warnings": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Attributes": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Parameters": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Extended Summary": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Blockquote",
          "__tag": 4059,
          "children": [
            {
              "__type": "Paragraph",
              "__tag": 4045,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "%matplotlib [-l] [gui]"
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Set up matplotlib to work interactively."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "This function lets you activate matplotlib interactive support at any point during an IPython session. It does not import anything into the interactive namespace."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "If you are using the inline matplotlib backend in the IPython Notebook you can set which figure formats are enabled using the following      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "In [1]: from matplotlib_inline.backend_inline import set_matplotlib_formats\n\nIn [2]: set_matplotlib_formats('pdf', 'svg')",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The default for inline figures sets "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "bbox_inches",
              "domain": null,
              "role": null,
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " to 'tight'. This can cause discrepancies between the displayed image and the identical image created using "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "savefig",
              "domain": null,
              "role": null,
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". This behavior can be disabled using the "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "%config",
              "domain": null,
              "role": null,
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " magic      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "In [3]: %config InlineBackend.print_figure_kwargs = {'bbox_inches':None}",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "In addition, see the docstrings of "
            },
            {
              "__type": "CrossRef",
              "__tag": 4002,
              "value": "matplotlib_inline.backend_inline.set_matplotlib_formats",
              "reference": {
                "__type": "RefInfo",
                "__tag": 4000,
                "module": "matplotlib_inline",
                "version": "*",
                "kind": "api",
                "path": "matplotlib_inline.backend_inline:set_matplotlib_formats"
              },
              "kind": "module"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "CrossRef",
              "__tag": 4002,
              "value": "matplotlib_inline.backend_inline.set_matplotlib_close",
              "reference": {
                "__type": "RefInfo",
                "__tag": 4000,
                "module": "matplotlib_inline",
                "version": "*",
                "kind": "api",
                "path": "matplotlib_inline.backend_inline:set_matplotlib_close"
              },
              "kind": "module"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " for more information on changing additional behaviors of the inline backend."
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Other Parameters": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    }
  },
  "_ordered_sections": [
    "Summary",
    "Extended Summary",
    "Parameters",
    "Attributes",
    "Methods",
    "Returns",
    "Yields",
    "Receives",
    "Other Parameters",
    "Raises",
    "Warns",
    "Warnings",
    "Notes"
  ],
  "item_file": "/IPython/core/magics/pylab.py",
  "item_line": 41,
  "item_type": "function",
  "aliases": [
    "IPython.core.magics.PylabMagics.matplotlib"
  ],
  "example_section_data": {
    "__type": "Section",
    "__tag": 4015,
    "children": [
      {
        "__type": "Text",
        "__tag": 4046,
        "value": "To enable the inline backend for usage with the IPython Notebook::\n\n    In [1]: %matplotlib inline\n\nIn this case, where the matplotlib default is TkAgg::\n\n    In [2]: %matplotlib\n    Using matplotlib backend: TkAgg\n\nBut you can explicitly request a different GUI backend::\n\n    In [3]: %matplotlib qt\n\nYou can list the available backends using the -l/--list option::\n\n   In [4]: %matplotlib --list\n   Available matplotlib backends: ['osx', 'qt4', 'qt5', 'gtk3', 'gtk4', 'notebook', 'wx', 'qt', 'nbagg',\n   'gtk', 'tk', 'inline']\n\npositional arguments:\n  gui         Name of the matplotlib backend to use such as 'qt' or 'widget'. If given, the corresponding matplotlib backend is used, otherwise it will be matplotlib's default (which you can set in your matplotlib config file).\n\noptions:\n  -l, --list  Show available matplotlib backends"
      }
    ],
    "title": [],
    "level": 0,
    "target": null
  },
  "see_also": [],
  "signature": {
    "__type": "SignatureNode",
    "__tag": 4029,
    "kind": "function",
    "parameters": [
      {
        "__type": "SigParam",
        "__tag": 4030,
        "name": "self",
        "annotation": {
          "__type": "Empty",
          "__tag": 4031
        },
        "kind": "POSITIONAL_OR_KEYWORD",
        "default": {
          "__type": "Empty",
          "__tag": 4031
        }
      },
      {
        "__type": "SigParam",
        "__tag": 4030,
        "name": "line",
        "annotation": {
          "__type": "Empty",
          "__tag": 4031
        },
        "kind": "POSITIONAL_OR_KEYWORD",
        "default": ""
      }
    ],
    "return_annotation": {
      "__type": "Empty",
      "__tag": 4031
    },
    "target_name": "matplotlib"
  },
  "references": null,
  "qa": "IPython.core.magics.pylab:PylabMagics.matplotlib",
  "arbitrary": [],
  "local_refs": []
}