# How do d2p/l2p and .\_offset work?

**URL:** https://community.plotly.com/t/how-do-d2p-l2p-and-offset-work/27330
**Category:** plotly.js
**Created:** [August 15, 2019, 5:27pm UTC](https://community.plotly.com/t/how-do-d2p-l2p-and-offset-work/27330 "2019-08-15T17:27:27Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![jliu](https://avatars.discourse-cdn.com/v4/letter/j/8baadc/32.png) [@jliu](https://community.plotly.com/u/jliu)
#### Post date: [August 15, 2019, 5:27pm UTC](https://community.plotly.com/t/how-do-d2p-l2p-and-offset-work/27330/1 "2019-08-15T17:27:27Z")

</div>

I’d like to make a custom tooltip for a graph in plotly using react. I’ve been using xaxis.d2p and xaxis.\_offset from the hover data returned on hovering over a point. However, the position isn’t exactly in the center of the point… how are these values obtained?
