{ "cells": [ { "cell_type": "markdown", "id": "7c9e0d60-922a-4434-b39b-71f6500f7db1", "metadata": {}, "source": [ "# `break_width` Parameter in Position Scales\n", "\n", "The `break_width` parameter specifies a fixed distance between axis breaks.\n", "\n", "If the scale has an associated transformation, the distance is measured in transformed units. \\\n", "For example, on a log10 scale, `break_width=1` places breaks at every power of 10, and `break_width=0.5` — at every half-power." ] }, { "cell_type": "code", "execution_count": 1, "id": "27c90744-c88e-4500-92bd-eb26a90aec56", "metadata": {}, "outputs": [], "source": [ "import pandas as pd\n", "from lets_plot import *" ] }, { "cell_type": "code", "execution_count": 2, "id": "8ca59e39-0241-4f96-97a1-3d24c28df552", "metadata": {}, "outputs": [ { "data": { "text/html": [ "\n", "
\n", " \n", " " ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "LetsPlot.setup_html()" ] }, { "cell_type": "code", "execution_count": 3, "id": "6e2e328b-eb16-4b82-9525-b0502a84a4a0", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "(5000, 10)\n" ] } ], "source": [ "df = (pd.read_csv(\"https://raw.githubusercontent.com/JetBrains/lets-plot-docs/refs/heads/master/data/diamonds.csv\")\n", " .sample(n=5000, random_state=42))\n", "print(df.shape)" ] }, { "cell_type": "code", "execution_count": 4, "id": "f3ea8933-bb78-4dc8-b77f-afc11578e782", "metadata": {}, "outputs": [ { "data": { "text/html": [ " \n", " " ], "text/plain": [ "