title: JFreechart tick units
body: <p>I am using the following code which i got off the web</p>
  
  <pre><code>TickUnits units = new TickUnits();
  DecimalFormat df1 = new DecimalFormat("$0");
  DecimalFormat df2 = new DecimalFormat("$0.00");
  
  // we can add the units in any order, the TickUnits collection will
  // sort them...
  units.add(new NumberTickUnit(100, df1, 0));
  units.add(new NumberTickUnit(50, df1, 0));
  units.add(new NumberTickUnit(20, df1, 0));
  units.add(new NumberTickUnit(10, df1, 0));
  units.add(new NumberTickUnit(5, df1, 0));
  units.add(new NumberTickUnit(2, df1, 0));
  units.add(new NumberTickUnit(1, df1, 0));
  </code></pre>
  
  <p>As I am very new, I don't understand what this piece of code actually does. I Thought that it sets the values on the <em>y</em> axis, but that does not seem to be the case as there are values exceeding 100 dollars on the <em>y</em> axis. What exactly does this piece of code do. (Also what exactly is tick units. Does it define the labels on the axes or am I mistaken here).</p>