Vega Visualizations

by Justin Kim
5
4
3
2
1
Score: 46/100

Description

Category: Data Visualization

The Vega Visualizations plugin allows users to create customizable data visualizations within Obsidian using Vega or Vega-Lite specifications written in JSON format. The plugin supports a variety of charts and plots, such as bar charts and line charts, which are rendered directly within Obsidian notes. With this plugin, you can easily embed complex visualizations into your notes by simply adding a code block with the appropriate specification. It's ideal for users who need to visualize data in a flexible, interactive manner without leaving the note-taking environment.

Reviews

No reviews yet.

Stats

39
stars
5,903
downloads
3
forks
1,262
days
709
days
1,072
days
3
total PRs
0
open PRs
0
closed PRs
3
merged PRs
2
total issues
1
open issues
1
closed issues
2
commits

Latest Version

3 years ago

Changelog

  • Fixed theming issue with dark mode
  • Fixed denial of service vulnerability

README file from

Github

Vega Visualizations Plugin

Create highly customizable data visualizations using Vega or Vega-Lite specifications written in JSON format inside of the Obsidian note-taking app. Additional documentation can be found at the Vega website for formatting Vega specifications and Vega-Lite specifications.

To add a chart or plot, create a code block with vega or vega-lite as the language and add the JSON specification.

Examples

Bar Chart using Vega-Lite

```vega-lite
{
  "width": 300,
  "data": {
    "values": [
      {"a": "A", "b": 39}, {"a": "B", "b": 98},
      {"a": "C", "b": 76}, {"a": "D", "b": 23}
    ]
  },
  "mark": "bar",
  "encoding": {
    "x": { "field": "a", "type": "nominal", "axis": { "labelAngle": 0 } },
    "y": { "field": "b", "type": "quantitative" }
  }
}
```

Example Bar Chart

Line Chart Using Vega

```vega
{
  "width": 400,
  "height": 200,
  "data": [
    {
      "name": "table",
      "values": [
        { "x": 0, "y": 50 }, { "x": 1, "y": 0 },
        { "x": 2, "y": 30 }, { "x": 3, "y": 40 },
        { "x": 4, "y": 60 }, { "x": 5, "y": 25 }
      ]
    }
  ],
  "scales": [
    {
      "name": "x",
      "type": "point",
      "range": "width",
      "domain": { "data": "table", "field": "x" }
    },
    {
      "name": "y",
      "type": "linear",
      "range": "height",
      "domain": { "data": "table", "field": "y" }
    }
  ],
  "axes": [
    { "orient": "bottom", "scale": "x" },
    { "orient": "left", "scale": "y" }
  ],
  "marks": [
    {
      "type": "line",
      "from": { "data": "table" },
      "encode": {
        "enter": {
          "x": { "scale": "x", "field": "x" },
          "y": { "scale": "y", "field": "y" },
          "interpolate": { "value": "monotone" }
        }
      }
    }
  ]
}
```

Example Line Chart

Acknowledgements

Vega, Vega-Lite

BSD 3-Clause "New" or "Revised" License
Copyright (c) 2015-2021, University of Washington Interactive Data Lab

Similar Plugins

info
• Similar plugins are suggested based on the common tags between the plugins.