{"id":15017764,"url":"https://github.com/jetbrains/lets-plot-kotlin","last_synced_at":"2026-05-27T00:02:28.487Z","repository":{"id":37077517,"uuid":"172682391","full_name":"JetBrains/lets-plot-kotlin","owner":"JetBrains","description":"Grammar of Graphics for Kotlin","archived":false,"fork":false,"pushed_at":"2026-05-25T21:17:26.000Z","size":100696,"stargazers_count":485,"open_issues_count":15,"forks_count":39,"subscribers_count":202,"default_branch":"master","last_synced_at":"2026-05-25T23:17:13.272Z","etag":null,"topics":["charts","geotools","ggplot","ggplot2","graphics","jupyter","jupyter-notebooks","jvm","kotlin","kotlin-api","plot","plot-library","plots","plots-in-kotlin"],"latest_commit_sha":null,"homepage":"https://lets-plot.org/kotlin/","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JetBrains.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2019-02-26T09:42:50.000Z","updated_at":"2026-04-26T08:53:07.000Z","dependencies_parsed_at":"2023-12-25T16:48:37.898Z","dependency_job_id":"e3899ac4-1cd0-4e3e-a090-9b6c7d2b28fa","html_url":"https://github.com/JetBrains/lets-plot-kotlin","commit_stats":{"total_commits":1003,"total_committers":17,"mean_commits":59.0,"dds":0.3200398803589233,"last_synced_commit":"f6edab1a67783d14e2378675f065ef7111bdc1a0"},"previous_names":[],"tags_count":66,"template":false,"template_full_name":null,"purl":"pkg:github/JetBrains/lets-plot-kotlin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JetBrains%2Flets-plot-kotlin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JetBrains%2Flets-plot-kotlin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JetBrains%2Flets-plot-kotlin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JetBrains%2Flets-plot-kotlin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JetBrains","download_url":"https://codeload.github.com/JetBrains/lets-plot-kotlin/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JetBrains%2Flets-plot-kotlin/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33543974,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"ssl_error","status_checked_at":"2026-05-26T15:22:15.568Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["charts","geotools","ggplot","ggplot2","graphics","jupyter","jupyter-notebooks","jvm","kotlin","kotlin-api","plot","plot-library","plots","plots-in-kotlin"],"created_at":"2024-09-24T19:50:57.837Z","updated_at":"2026-05-27T00:02:28.482Z","avatar_url":"https://github.com/JetBrains.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Lets-Plot Kotlin API\nA **Grammar of Graphics** for Kotlin.\n\n[![official JetBrains project](http://jb.gg/badges/official-flat-square.svg)](https://confluence.jetbrains.com/display/ALL/JetBrains+on+GitHub)\n[![License MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/LICENSE)\n[![Latest Release](https://img.shields.io/github/v/release/JetBrains/lets-plot-kotlin)](https://github.com/JetBrains/lets-plot-kotlin/releases/latest)\n\n**Lets-Plot Kotlin API** is a \u003ca href=\"https://lets-plot.org/kotlin\"\u003eKotlin API\u003c/a\u003e for [Lets-Plot Multiplatform](https://github.com/JetBrains/lets-plot) \n plotting library, \\\nwhich is built on the principles of layered graphics first described in the \\\nLeland Wilkinson work [The Grammar of Graphics](https://www.goodreads.com/book/show/2549408.The_Grammar_of_Graphics).\n\n\u003ctable\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\n            \u003ca href=\"https://ggplot2-book.org/index.html\" target=\"_blank\"\u003e \n               \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/docs/images/ggplot2-elegant-graphics-for-data-analysis.jpeg\" \n                    width=\"150\" height=\"228\" alt=\"book cover\"\u003e\n            \u003c/a\u003e\n        \u003c/td\u003e\n        \u003ctd\u003e\n            \u003cp\u003eLets-Plot \u003ca href=\"https://lets-plot.org/kotlin\"\u003eKotlin API\u003c/a\u003e is largely based on the API\u003cbr\u003eprovided by \n            \u003ca href=\"https://ggplot2.tidyverse.org/\"\u003eggplot2\u003c/a\u003e package well-known to data scientists who use R.\u003c/p\u003e\n            \u003cp\u003eTo learn more about the \u003ci\u003eGrammar of Graphics\u003c/i\u003e,\u003cbr\u003ewe recommend an excellent book called\u003cbr\u003e \n            \u003ca href=\"https://ggplot2-book.org/index.html\" target=\"_blank\"\u003e“ggplot2: Elegant Graphics for Data Analysis”\u003c/a\u003e.\u003c/p\u003e \n            \u003cp\u003eThis will be a good prerequisite for further exploration of the Lets-Plot library.\u003c/p\u003e\n        \u003c/td\u003e  \n    \u003c/tr\u003e\n\u003c/table\u003e\n\n\n\u003ca id=\"quickstart\"\u003e\u003c/a\u003e\n### Quickstart\n\nInside [Kotlin Notebook](https://plugins.jetbrains.com/plugin/16340-kotlin-notebook),\n[Datalore](https://datalore.jetbrains.com/) or\n[Jupyter with Kotlin Kernel](https://github.com/Kotlin/kotlin-jupyter#readme):\n\n```\n%use lets-plot\n```     \n\n```kotlin\nval rand = java.util.Random()\nval data = mapOf(\n    \"rating\" to List(200) { rand.nextGaussian() } + List(200) { rand.nextGaussian() * 1.5 + 1.5 },\n    \"cond\" to List(200) { \"A\" } + List(200) { \"B\" }\n)\n\nvar p = letsPlot(data)\np += geomDensity(color = \"dark_green\", alpha = .3) { x = \"rating\"; fill = \"cond\" }\np + ggsize(700, 350)\n```\n\n\u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/docs/images/quickstart_notebook.png\" alt=\"Couldn't load quickstart_notebook.png\" width=\"523\" height=\"261\"/\u003e\n\u003cbr/\u003e\n\nSee the \"Quickstart\" notebook in [Datalore](https://datalore.jetbrains.com/view/notebook/aTA9lQnPkRwdCzT6uy95GZ) or\n[Jupyter nbviewer](https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/cookbook/quickstart.ipynb).\n\n\n\u003ca name=\"toc\" id=\"toc\"\u003e\u003c/a\u003e\n## Table of Contents\n             \n- [Usage](#usage)\n  - [Notebooks](#in-notebook)\n  - [Compose Multiplatform](#in-compose-multiplatform)\n  - [JVM and Kotlin/JS](#in-jvm-js)\n- [Documentation](#documentation)\n- [What is new in 4.14.0](#new)\n- [Recent Updates in the Gallery](#recent_gallery_updates)\n- [Change Log](#change_log)\n- [Code of Conduct](#CoC)\n- [License](#license)\n                          \n\n\n\u003ca id=\"usage\"\u003e\u003c/a\u003e\n## Usage\n\n\u003ca id=\"in-notebook\"\u003e\u003c/a\u003e\n### Notebooks\n\nWith the help of Lets-Plot Kotlin API you can easily create plots in [Kotlin Notebook](https://plugins.jetbrains.com/plugin/16340-kotlin-notebook),\n[Datalore](https://datalore.jetbrains.com/), [Jupyter with Kotlin Kernel](https://github.com/Kotlin/kotlin-jupyter#readme) \\\nor any other notebook that supports `Kotlin Kernel`.\n\n\n#### \"Line Magics\"\n\n```\n%use lets-plot\n```  \nThis \"line magic\" will apply **Lets-Plot library descriptor** which adds to your notebook all the boilerplate code necessary to create plots.\n\nBy default, `library descriptor` is bundled with the Kotlin Jupyter Kernel installed in your environment. \\\nHowever, you can override the default settings using:\n```\n%useLatestDescriptors\n```\nIn this case the latest `library descriptor` will be pulled from the [Kotlin Jupyter Libraries](https://github.com/Kotlin/kotlin-jupyter-libraries) repository.\n\n#### Library Descriptor Parameters\n\n```\n%use lets-plot(v=4.13.0, isolatedFrame=false, output=\"js, ktnb, svg\")\n```                                                                 \n- `v` - version of the Lets-Plot Kotlin API.\n- `isolatedFrame` - If `false`: load JS just once per notebook (default in Jupyter).  \n  If `true`: include Lets-Plot JS in each output (default in [Datalore](https://datalore.jetbrains.com/) notebooks).\n- `output` - comma-separated list of output types to store in notebook cells (default: `\"js, ktnb, svg\"`). \\  \n  Available types:\n    - `js` - Classic Web output: HTML+JS\n    - `ktnb` - Kotlin Notebook Swing-based rendering\n    - `svg` - Static SVG output\n    - `png` - Static PNG output\n\n  **Note:** Static images (SVG/PNG) are hidden when `js` or `ktnb` outputs are present, and only displayed in environments where JavaScript is not executed (e.g., GitHub).\n\n  This option can be helpful when file size becomes a problem. For example, storing only static output (SVG or PNG) can significantly reduce file size when working with large datasets where plot interactivity is not a priority.\n\n\u003ca id=\"in-compose-multiplatform\"\u003e\u003c/a\u003e\n### Compose Multiplatform\nTo learn how to embed Lets-Plot charts in [Compose Multiplatform](https://github.com/JetBrains/compose-multiplatform) applications, please check out the [Lets-Plot Compose Frontend](https://github.com/JetBrains/lets-plot-compose) project at GitHub.\n   \n\n\u003ca id=\"in-jvm-js\"\u003e\u003c/a\u003e\n### JVM and Kotlin/JS\n\nTo learn more about creating plots in JVM or Kotlin/JS environment, please read [USAGE_JVM_JS.md](https://github.com/JetBrains/lets-plot-kotlin/blob/master/USAGE_JVM_JS.md). \n        \n#### Examples\nExamples of using the Lets-Plot Kotlin API in JVM and Kotlin/JS applications are available in the [Lets-Plot Kotlin Mini Apps (Demos)](https://github.com/alshan/lets-plot-mini-apps) GitHub repository.\n\n\u003ca id=\"documentation\"\u003e\u003c/a\u003e\n## Documentation\n\n* _Lets-Plot Kotlin API_ documentation and API reference: [**Lets-Plot for Kotlin**](https://lets-plot.org/kotlin)\n\n* A quick introduction to the _Grammar of Graphics_ and _Lets-Plot Kotlin API_: [Lets-Plot Usage Guide](https://nbviewer.jupyter.org/github/JetBrains/lets-plot-kotlin/blob/master/docs/guide/user_guide.ipynb) \n\n\n\u003ca id=\"new\"\u003e\u003c/a\u003e\n## What is new in 4.14.0\n\n- #### `ggdeck()`\n\n  The new `ggdeck()` function overlays multiple independent plots in a shared plotting area.\n  Typically, all plots share one axis — enabling dual-axis charts and multivariate comparisons.\u003cbr\u003e\u003cbr\u003e\n  - **Dual Axis:**\n\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot/master/docs/f-26b/images/ggdeck_dual_axis.png\" alt=\"f-26b/images/ggdeck_dual_axis.png\" width=\"550\" height=\"295\"\u003e\n\n    See: [example notebook](https://raw.githack.com/JetBrains/lets-plot-kotlin/master/docs/examples/jupyter-notebooks/f-4.14.0/ggdeck_dual_axis.html).\u003cbr\u003e\u003cbr\u003e\n\n  - **Multivariate Comparison:**\n\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot/master/docs/f-26b/images/ggdeck_plot_overlay.png\" alt=\"f-26b/images/ggdeck_plot_overlay.png\" width=\"600\" height=\"283\"\u003e\n\n    See [example notebook](https://raw.githack.com/JetBrains/lets-plot-kotlin/master/docs/examples/jupyter-notebooks/f-4.14.0/ggdeck_plot_overlay.html).\n\n\n\n- #### Alpha Channel in Color Strings\n\n  - Named colors accept an opacity suffix after a slash: `\"steelblue/0.35\"`.\n  - Hex colors accept an alpha channel: `#RRGGBBAA` or short form `#RGBA`.\n\n  \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot/master/docs/f-26b/images/color_alpha_componnet.png\" alt=\"f-26b/images/color_alpha_componnet.png\" width=\"400\" height=\"214\"\u003e\n\n  See: [example notebook](https://raw.githack.com/JetBrains/lets-plot-kotlin/master/docs/examples/jupyter-notebooks/f-4.14.0/color_alpha.html).\n\n\n- #### Text Angle in Facet Strip Labels\n\n  Facet strip labels can now be rotated via the `angle` parameter of `element_text()`, applied to `strip_text`, `strip_text_x`, or `strip_text_y`.\n\n  Thanks to a contribution by [tentrillion](https://github.com/tentrillion).\n\n  \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot/master/docs/f-26b/images/facet_strip_text_angle.png\" alt=\"f-26b/images/facet_strip_text_angle.png\" width=\"400\" height=\"225\"\u003e\n\n  See: [example notebook](https://raw.githack.com/JetBrains/lets-plot-kotlin/master/docs/examples/jupyter-notebooks/f-4.14.0/strip_text_angle.html).\n\n\n- #### And More\n\n  See [CHANGELOG.md](https://github.com/JetBrains/lets-plot-kotlin/blob/master/CHANGELOG.md) for a full list of changes.\n\n\n\u003ca id=\"recent_gallery_updates\"\u003e\u003c/a\u003e\n## Recent Updates in the [Gallery](https://lets-plot.org/kotlin/gallery.html)\n\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/raincloud.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-raincloud.png\" alt=\"Raincloud plot\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/europe_capitals.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-europe_capitals.png\" alt=\"Lets-Plot GeoTools with texts and labels\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/trading_chart.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-trading_chart.png\" alt=\"Bitcoin daily trend visualization\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/magnifier_inset.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-magnifier_inset.png\" alt=\"Creating magnifier inset effect with ggbunch()\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/theme_legend_scheme.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-theme_legend_scheme.png\" alt=\"Customize legend appearance\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/interact_pan_zoom.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-interact_pan_zoom.png\" alt=\"Zoom and Pan interactivity\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/lp_verse.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-lp_verse.png\" alt=\"The observable LP-verse\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://nbviewer.org/github/JetBrains/lets-plot-docs/blob/master/source/kotlin_examples/demo/sunshine_hours.ipynb\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/JetBrains/lets-plot-kotlin/master/Writerside/images/previews/square-sunshine_hours.png\" alt=\"Sunshine hours\" width=\"128\" height=\"128\"\u003e\n  \u003c/a\u003e\n\n\n\u003ca id=\"change_log\"\u003e\u003c/a\u003e\n## Change Log\n\nSee [CHANGELOG.md](https://github.com/JetBrains/lets-plot-kotlin/blob/master/CHANGELOG.md).\n\n\n\u003ca id=\"CoC\"\u003e\u003c/a\u003e\n## Code of Conduct\n\nThis project and the corresponding community are governed by the \n[JetBrains Open Source and Community Code of Conduct](https://confluence.jetbrains.com/display/ALL/JetBrains+Open+Source+and+Community+Code+of+Conduct). \nPlease make sure you read it.\n\n\u003ca id=\"license\"\u003e\u003c/a\u003e\n## License\n\nCode and documentation released under\nthe [MIT license](https://github.com/JetBrains/lets-plot-kotlin/blob/master/LICENSE).\nCopyright © 2019-2025, JetBrains s.r.o.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjetbrains%2Flets-plot-kotlin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjetbrains%2Flets-plot-kotlin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjetbrains%2Flets-plot-kotlin/lists"}