# Percentage numberals.js format patterns

**URL:** <https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595>\
**Category:** Kibana\
**Created:** [October 7, 2019, 9:31pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595 "2019-10-07T21:31:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jlim0930](https://avatars.discourse-cdn.com/v4/letter/j/8491ac/32.png) [@jlim0930](https://discuss.elastic.co/u/jlim0930)\
**Post date:** [October 7, 2019, 9:31pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595/1 "2019-10-07T21:31:29Z")

</div>

I have metricbeats configured with vsphere to send in datastore usage and my percentages are off by a factor of 1000.

I am looking at the edit in the index pattern for numberals.js format pattern but cant fingure out what to put in to make it smaller by a factor of 1000.. the default is 0,0[000]%

can someone please give me some ideas?

---

<div class="post-metadata">

**Author:** ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)\
**Post date:** [October 8, 2019, 7:13pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595/2 "2019-10-08T19:13:45Z")

</div>

NumeralJS seems to take any number with the `%` formatter and multiply it by 100, so maybe your input is not in the range 0-1 and is instead in the range 0-100? [http://numeraljs.com/#format](http://numeraljs.com/#format)

---

<div class="post-metadata">

**Author:** ![jlim0930](https://avatars.discourse-cdn.com/v4/letter/j/8491ac/32.png) [@jlim0930](https://discuss.elastic.co/u/jlim0930)\
**Post date:** [October 8, 2019, 7:33pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595/3 "2019-10-08T19:33:23Z")

</div>

you are correct the number coming in is the percent already without the % symbol and it is being multiplied by 100... so how do you format this so that it wouldnt get multiplied by 100?

---

<div class="post-metadata">

**Author:** ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)\
**Post date:** [October 8, 2019, 8:12pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595/4 "2019-10-08T20:12:08Z")

</div>

I'm not an expert in numeraljs, but I don't see any examples of escape codes in their documentation. A workaround would be to use the number formatter instead of the percentage formatter.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 5, 2019, 8:12pm UTC](https://discuss.elastic.co/t/percentage-numberals-js-format-patterns/202595/5 "2019-11-05T20:12:10Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
