# Adding legend label to contour plot

**URL:** <https://discourse.julialang.org/t/adding-legend-label-to-contour-plot/44280>\
**Category:** Visualization\
**Created:** [August 4, 2020, 6:49pm UTC](https://discourse.julialang.org/t/adding-legend-label-to-contour-plot/44280 "2020-08-04T18:49:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![gideonsimpson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gideonsimpson/32/1928_2.png) [@gideonsimpson](https://discourse.julialang.org/u/gideonsimpson)\
**Post date:** [August 4, 2020, 6:49pm UTC](https://discourse.julialang.org/t/adding-legend-label-to-contour-plot/44280/1 "2020-08-04T18:49:22Z")

</div>

I’m using `contour` to plot a level set with the command:

```julia
contour(-3:0.01:3, -3:0.01:3, (x,y) -> max(abs(x-y), abs(x), abs(y)), 
    levels=[2.0], colorbar=false, color = cgrad([:blue,:blue]),lw=2)

```

and I’d like to a legend to label the figure, but I don’t quite see how to do it.
