{ "cells": [ { "cell_type": "code", "execution_count": null, "id": "49969f7f", "metadata": {}, "outputs": [], "source": [ "from bqplot import *\n", "\n", "import numpy as np\n", "import pandas as pd\n", "\n", "np.random.seed(0)" ] }, { "cell_type": "code", "execution_count": null, "id": "da5f4803", "metadata": {}, "outputs": [], "source": [ "x = list(range(10))\n", "y = [10**i for i in range(10)]\n", "\n", "sc_x = LinearScale()\n", "sc_y = LogScale()\n", "\n", "lines = Lines(x=x, y=y,\n", " scales={'x': sc_x, 'y': sc_y})\n", "ax_x = Axis(scale=sc_x, label='Index')\n", "ax_y = Axis(scale=sc_y, orientation='vertical', label='lines')\n", "\n", "Figure(marks=[lines], axes=[ax_x, ax_y], title='Lines')" ] }, { "cell_type": "code", "execution_count": null, "id": "3d0a20a0", "metadata": {}, "outputs": [], "source": [ "x = list(range(10))\n", "y = [10**i for i in range(10)]\n", "\n", "sc_x = LinearScale()\n", "sc_y = LinearScale()\n", "\n", "lines = Lines(x=x, y=y,\n", " scales={'x': sc_x, 'y': sc_y})\n", "ax_x = Axis(scale=sc_x, label='Index')\n", "ax_y = Axis(scale=sc_y, orientation='vertical', label='lines')\n", "\n", "Figure(marks=[lines], axes=[ax_x, ax_y], title='Lines')" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "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.5" } }, "nbformat": 4, "nbformat_minor": 5 }