{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "## Subplot panel support" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "import smpl\n", "smpl.__version__" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "from smpl import plot\n", "fig, axs = plot.subplots(1, 3, figsize=(12, 8), sharey=True)\n", "fig.subplots_adjust(wspace=0)\n", "\n", "plot.function(lambda x: x**2,axes=axs[0],tight=False,xmin=0,xmax=1)\n", "plot.function(lambda x: x**5,axes=axs[0],tight=False,xmin=0,xmax=1)\n", "plot.function(lambda x: x**3,axes=axs[1],logx=True,tight=False,xmin=0,xmax=1)\n", "plot.function(lambda x: x**1,axes=axs[2],tight=False,xmin=0,xmax=1)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "fig, axs = plot.subplots(3, 1, figsize=(12, 8), sharex=True)\n", "fig.subplots_adjust(hspace=0)\n", "\n", "plot.function(lambda x: x**2,axes=axs[0],tight=False,xmin=0,xmax=1,ylabel=\"y\")\n", "plot.function(lambda x: x**3,axes=axs[1],logx=True,tight=False,xmin=0,xmax=1)\n", "plot.function(lambda x: x**1,axes=axs[2],tight=False,xmin=0,xmax=1,xlabel=\"x\")" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.15" } }, "nbformat": 4, "nbformat_minor": 4 }