{"id":18733478,"url":"https://github.com/queryverse/lyra.jl","last_synced_at":"2026-03-19T06:05:22.314Z","repository":{"id":61798680,"uuid":"247350760","full_name":"queryverse/Lyra.jl","owner":"queryverse","description":"Julia wrapper for the Lyra Visualization Design Environment","archived":false,"fork":false,"pushed_at":"2023-07-06T17:07:10.000Z","size":615,"stargazers_count":3,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-19T23:43:47.155Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Julia","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/queryverse.png","metadata":{"files":{"readme":"README.md","changelog":null,"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}},"created_at":"2020-03-14T20:46:30.000Z","updated_at":"2022-10-30T19:39:57.000Z","dependencies_parsed_at":"2025-05-19T23:48:28.448Z","dependency_job_id":null,"html_url":"https://github.com/queryverse/Lyra.jl","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/queryverse/Lyra.jl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/queryverse%2FLyra.jl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/queryverse%2FLyra.jl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/queryverse%2FLyra.jl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/queryverse%2FLyra.jl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/queryverse","download_url":"https://codeload.github.com/queryverse/Lyra.jl/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/queryverse%2FLyra.jl/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266135014,"owners_count":23881774,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-07T15:09:55.055Z","updated_at":"2026-02-04T08:44:31.974Z","avatar_url":"https://github.com/queryverse.png","language":"Julia","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Lyra\n\n[![Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)\n[![codecov.io](http://codecov.io/github/queryverse/Lyra.jl/coverage.svg?branch=master)](http://codecov.io/github/queryverse/Lyra.jl?branch=master)\n\n## Overview\n\nThis package provides Julia integration for the [Lyra](https://github.com/vega/lyra) Visualization Design Environment.\n\nNOTE THAT THIS PACKAGE CURRENTLY USES A VERY EXPERIMENTAL AND UNSTABLE BUILD OF LYRA AND IS NOT READY FOR REAL USE.\n\n## Getting Started\n\nLyra.jl is an interactive environment that enables custom visualization design without writing any code.\n\nYou can install the package at the Pkg REPL-mode with:\n\n````julia\npkg\u003e add https://github.com/queryverse/Lyra.jl\n````\n\n## Visualizing data\n\nYou create a new Lyra window by calling `LyraWindow`:\n\n````julia\nusing Lyra\n\nl = LyraWindow()\n````\n\nBy itself this is not very useful, the next step is to load some data into Lyra. Lets assume your data is in a `DataFrame`:\n\n````julia\nusing DataFrames, Lyra\n\ndata = DataFrame(a=rand(100), b=randn(100))\n\nl = LyraWindow(data)\n````\n\nYou can also use the pipe to load data into Lyra:\n\n````julia\nusing DataFrames, Lyra\n\ndata = DataFrame(a=rand(100), b=randn(100))\n\nl = data |\u003e LyraWindow()\n````\n\nWith a more interesting data source\n\n```julia\nusing VegaDatasets, Lyra\n\nl = dataset(\"cars\") |\u003e LyraWindow()\n```\n\nYou can load any source that implements the [TableTraits.jl](https://github.com/queryverse/TableTraits.jl) interface into Lyra, i.e. not just `DataFrame`s. For example, you can load some data from a CSV file with [CSVFiles.jl](https://github.com/queryverse/CSVFiles.jl), filter them with [Query.jl](https://github.com/queryverse/Query.jl) and then visualize the result with Lyra:\n\n```julia\nusing FileIO, CSVFiles, Query, Lyra\n\nl = load(\"data.csv\") |\u003e @filter(_.age\u003e30) |\u003e LyraWindow()\n```\n\nIn this example the data is streamed directly into Lyra and at no point is any `DataFrame` allocated.\n\nThe datasets we added so far were named with the default name `dataset`. You can also give the dataset your own name, by passing a `Pair` instead of the raw data to `LyraWindow`:\n\n```julia\nusing VegaDatasets, Lyra\n\nl = LyraWindow(:cars=\u003edataset(\"cars\"))\n```\n\nYou can also make multiple datasets available to the Lyra environment. In that case you need to give each a unique name. The following example passes both the `cars` and `movies` dataset to Lyra:\n\n```julia\nusing VegaDatasets, Lyra\n\nl = LyraWindow(:cars=\u003edataset(\"cars\"), :movies=\u003edataset(\"movies\"))\n```\n\nYou can use the `add!` function to add additional datasets to an existing Lyra window:\n\n```julia\nusing VegaDatasets, Lyra\n\nl = LyraWindow()\n\nadd!(l, :movies=\u003edataset(\"movies\"))\n```\n\n## Extracting plots\n\nYou can also access a plot that you have created in the Lyra UI from Julia, for example to save the plot to disc.\n\nYou can access the currently active plot in a given Lyra window `l` with the brackets syntax:\n\n```julia\nusing VegaDatasets, Lyra, VegaLite\n\nl = dataset(\"cars\") |\u003e LyraWindow()\n\nplot1 = l[]\n```\n\nAt this point `plot1` will hold a standard [VegaLite.jl](https://github.com/queryverse/VegaLite.jl) plot object. You can use the normal [VegaLite.jl](https://github.com/queryverse/VegaLite.jl) functions to display such a plot, or save it to disc:\n\n```julia\ndisplay(plot1)\n\nplot1 |\u003e save(\"figure1.pdf\")\n```\n\nA useful pattern here is to save the plot as a Vega JSON file to disc, without the data:\n\n```julia\nusing VegaDatasets, Lyra, VegaLite\n\nl = dataset(\"cars\") |\u003e LyraWindow()\n\n# Now create the plot in the UI\n\nl[] |\u003e save(\"figure1.vega\")\n```\n\nAt a later point you can then load this plot specification again, but pipe new data into it [TODO Make sure this works]:\n\n```julia\nusing VegaLite, VegaDatasets\n\ndataset(\"cars\") |\u003e load(\"figure1.vega\")\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqueryverse%2Flyra.jl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqueryverse%2Flyra.jl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqueryverse%2Flyra.jl/lists"}