title: d3.js format axis uniformly in millions
body: <p>I found <a href="https://stackoverflow.com/questions/19907206/format-y-axis-values-original-figures-in-millions-only-want-to-show-first-thre/39981718#39981718">this thread</a> and it got me halfway to where I need to be and I'm wondering if anyone knows how I can adjust the solution to fit my needs.</p>
  
  <p>So if I have some values in the thousands, and some values in the millions, does anyone know how I can set all of the ticks to be formatted in the millions? For instance, if I have a value for 800k it would show up as 0.8million instead. </p>
  
  <p>This is what I get when using the above solution without adjusting it. 
  <a href="https://i.stack.imgur.com/UauLJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UauLJ.png" alt="enter image description here"></a></p>