{ "cells": [ { "cell_type": "markdown", "id": "50816dd6", "metadata": {}, "source": [ "# `stroke` aesthetic\n", "\n", "Affects the thickness of the point boundaries (in case the given shape has a boundary).\n", "\n", "Available for the following geometries: `geom_point()`, `geom_jitter()`, `geom_qq()`, `geom_qq2()`, `geom_pointrange()`, `geom_dotplot()`, `geom_ydotplot()`." ] }, { "cell_type": "code", "execution_count": 1, "id": "4548aaa5", "metadata": { "execution": { "iopub.execute_input": "2025-11-05T13:40:49.882551Z", "iopub.status.busy": "2025-11-05T13:40:49.882459Z", "iopub.status.idle": "2025-11-05T13:40:49.886017Z", "shell.execute_reply": "2025-11-05T13:40:49.885717Z" } }, "outputs": [], "source": [ "from lets_plot import *" ] }, { "cell_type": "code", "execution_count": 2, "id": "e5021e9e", "metadata": { "execution": { "iopub.execute_input": "2025-11-05T13:40:49.886742Z", "iopub.status.busy": "2025-11-05T13:40:49.886675Z", "iopub.status.idle": "2025-11-05T13:40:49.888465Z", "shell.execute_reply": "2025-11-05T13:40:49.888294Z" } }, "outputs": [ { "data": { "text/html": [ "\n", "
\n", " \n", " " ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "LetsPlot.setup_html()" ] }, { "cell_type": "code", "execution_count": 3, "id": "7ca0b26d", "metadata": { "execution": { "iopub.execute_input": "2025-11-05T13:40:49.889080Z", "iopub.status.busy": "2025-11-05T13:40:49.889011Z", "iopub.status.idle": "2025-11-05T13:40:49.890437Z", "shell.execute_reply": "2025-11-05T13:40:49.890268Z" } }, "outputs": [], "source": [ "data1 = {\n", " 'x': (list(range(7)) * 4)[:26],\n", " 'y': ([3] * 7 + [2] * 7 + [1] * 7 + [0] * 7)[:26],\n", " 'shape': list(range(26)),\n", "}" ] }, { "cell_type": "code", "execution_count": 4, "id": "1829f639", "metadata": { "execution": { "iopub.execute_input": "2025-11-05T13:40:49.891007Z", "iopub.status.busy": "2025-11-05T13:40:49.890940Z", "iopub.status.idle": "2025-11-05T13:40:49.892334Z", "shell.execute_reply": "2025-11-05T13:40:49.892166Z" } }, "outputs": [], "source": [ "p1 = ggplot(data1, aes('x', 'y')) + scale_shape_identity() + \\\n", " xlim(-1, 7) + ylim(-1, 4) + \\\n", " theme(legend_position='none')" ] }, { "cell_type": "markdown", "id": "c184ec7a", "metadata": {}, "source": [ "#### 1. Default Stroke" ] }, { "cell_type": "code", "execution_count": 5, "id": "4784b085", "metadata": { "execution": { "iopub.execute_input": "2025-11-05T13:40:49.892953Z", "iopub.status.busy": "2025-11-05T13:40:49.892883Z", "iopub.status.idle": "2025-11-05T13:40:49.928232Z", "shell.execute_reply": "2025-11-05T13:40:49.927994Z" } }, "outputs": [ { "data": { "text/html": [ " \n", " " ], "text/plain": [ "