# Plotly Shape Questions

**URL:** <https://community.plotly.com/t/plotly-shape-questions/7164>\
**Category:** 📊 Plotly Python\
**Created:** [December 5, 2017, 3:51pm UTC](https://community.plotly.com/t/plotly-shape-questions/7164 "2017-12-05T15:51:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![eekk](https://avatars.discourse-cdn.com/v4/letter/e/9d8465/32.png) [@eekk](https://community.plotly.com/u/eekk)\
**Post date:** [December 5, 2017, 3:51pm UTC](https://community.plotly.com/t/plotly-shape-questions/7164/1 "2017-12-05T15:51:11Z")

</div>

I’m sorry if this has been asked before. I have no experience at all with javascript and just started using plotly because with dash I can easily use it in Python. That said, I have some questions regarding shapes.

- Is there a way to plot circles using radius instead of size like in Bokeh?
- Is there a way to plot scatter points ON TOP OF circles/other shapes, so their visibility doesn’t get reduced?
- Is there a way to include shapes in the legend so they can be shown/hidden?

I couldn’t find this in the documentation, but if anyone could link me that’d be great. Thanks! 🙂

---

<div class="post-metadata">

**Author:** ![empet](https://avatars.discourse-cdn.com/v4/letter/e/977dab/32.png) [@empet](https://community.plotly.com/u/empet)\
**Post date:** [December 5, 2017, 8:53pm UTC](https://community.plotly.com/t/plotly-shape-questions/7164/2 "2017-12-05T20:53:53Z")

</div>

@eekk  
Please change plotly.js with Python. It’s a Python question.

1. If you want to define a circular shape giving the center and the radius, you should define  
a function to evaluate points on the circle . Then define a SVG path through the circle points, and fill it:

![circle](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/4/443591337ce5645d4929342f00c12c8b12db7b09.png)

1. `layer='below'` inserts the shape below the scatter points.
2. shapes are not traces, hence they cannot be included in legend.

---

<div class="post-metadata">

**Author:** ![eekk](https://avatars.discourse-cdn.com/v4/letter/e/9d8465/32.png) [@eekk](https://community.plotly.com/u/eekk)\
**Post date:** [December 6, 2017, 12:11pm UTC](https://community.plotly.com/t/plotly-shape-questions/7164/3 "2017-12-06T12:11:32Z")

</div>

Amazing, thank you so much! I think I will have to read into SVG a bit more 🙂
