title: d3 time axis with only days for a long interval
body: <p>I need to draw axis with time scale and show only days on it. Here is my code:</p>
  
  <pre><code>            var xScale = d3.time.scale.utc()
              .domain([beginning, ending])
              .range([margin.left, availableWidth - margin.right]);
  
          var xAxis = d3.svg.axis()
              .scale(xScale)
              .orient(orient)
              .tickFormat(tickFormat)
              .ticks(d3.time.days.utc, 1)
              .tickSize(tickSize);
  </code></pre>
  
  <p>But on long intervals it is bad overlapping (because I show every tick):</p>
  
  <p><a href="https://pp.vk.me/c620728/v620728099/16ab9/HdJByiakoKA.jpg" rel="nofollow">https://pp.vk.me/c620728/v620728099/16ab9/HdJByiakoKA.jpg</a></p>
  
  <p>I make some math operations and calculate acceptable amount of ticks:</p>
  
  <pre><code>var xAxis = d3.svg.axis()
              ...
              .ticks(d3.time.days.utc, stepTick) // for example 20 for a year interval
              .tickSize(tickSize);
  </code></pre>
  
  <p>So every 20th tick on axis will be shown for a year and it looks great! Except joint of month:</p>
  
  <p><a href="https://pp.vk.me/c620728/v620728099/16aaf/PjM4KJ0ofTM.jpg" rel="nofollow">https://pp.vk.me/c620728/v620728099/16aaf/PjM4KJ0ofTM.jpg</a> (31.05/01.06)</p>
  
  <p>Labels on joint of month are still overlapping, because in docs for d3.time.days we can see that</p>
  
  <blockquote>
    <p>If step is specified, then every step'th date will be returned, based on the day of the month.</p>
  </blockquote>
  
  <p>How should I do to prevent labels overlapping ?</p>