# Use Vega Editor to Make a Boxplot

**URL:** <https://community.omni.co/t/use-vega-editor-to-make-a-boxplot/233>\
**Category:** Visualizations\
**Created:** [February 11, 2025, 9:26pm UTC](https://community.omni.co/t/use-vega-editor-to-make-a-boxplot/233 "2025-02-11T21:26:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![aklance](https://yyz2.discourse-cdn.com/flex004/user_avatar/community.omni.co/aklance/32/132_2.png) [@aklance](https://community.omni.co/u/aklance)\
**Post date:** [February 11, 2025, 9:26pm UTC](https://community.omni.co/t/use-vega-editor-to-make-a-boxplot/233/1 "2025-02-11T21:26:05Z")

</div>

Need to edit the min-max of your boxplot? Or make other code customizations that aren’t available in the default boxplot visualization?

You can use this vega-lite starting point of a boxplot to use within Omni’s vega editor. Note you must update the `field` parameters to reference the fields in your own query and the `extent` parameter could be modified from “min-max” to other values like 1.5, which is the standard box plot whisker length (1.5 times the interquartile range).

```auto
here's a starting point for building this in the vega editor:
{ 
  "mark": {
    "type": "boxplot",
    "extent": "min-max"
  },
  "encoding": {
    "x": {"field": "main__order_items\\.status", "type": "ordinal"},
    "color": {"field": "main__order_items\\.created_at_date\\[month\\]", "type": "nominal", "legend": null},
    "y": {
      "field": "main__order_items\\.sale_price_sum",
      "type": "quantitative",
      "scale": {"zero": false}
    }
  }
}

```

Any further customization options could be found in the [vega-lite library](https://vega.github.io/vega-lite/examples/#box-plots) or your favorite AI helper could give you a few pointers 😉
