title: Custom x-axis values in Power BI
body: <p>I want to plot a graph over a year+weeknumber on the x axis.</p>
  
  <p>Each data-point contains this specific value; for example week 7 of 2016 is expressed as 201607 etc. and called YearWeek</p>
  
  <p>I created a date table in which I calculate all possible YearWeek value in a certain date-range. Then I created a YearWeek table extracting all distinct YearWeeks.</p>
  
  <p>This I connected to the Fact-Table. What I want to chart is exactly according to this matrix:
  <a href="https://i.stack.imgur.com/z8vG4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/z8vG4.png" alt="Using a measure to express values over 2 columns, with Yearweek values from the YearWeek Dim table as row context"></a></p>
  
  <p>Note that I explicitly selected to show items with no data to obtain the full time line. It continues down to 201852 but you get the picture.</p>
  
  <p>When I attempt to plot this, it results in this:
  <a href="https://i.stack.imgur.com/Unalz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Unalz.png" alt="enter image description here"></a></p>
  
  <p>It's hopefully clear that the straight lines running from 201652 to 201700 and 201752 to 201800 are the problem. </p>
  
  <p>There's three things to note:</p>
  
  <ul>
  <li>I explicitly need to keep the x-axis continuous, no gaps in the plots or x-axis values skipping several weeks for lack of data.</li>
  <li>PowerBI somehow does not want to accept that these values count to 52 and then continue in the next year and decides to make the values strictly numerical despite these values not existing in the YearWeek dimension table.</li>
  <li>If I change the values to text, PowerBI recognises that these are distinct categories, but it won't provide a continuous axis, just the values for which there is data.</li>
  </ul>
  
  <p><a href="https://i.stack.imgur.com/zZ9k3.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zZ9k3.png" alt="enter image description here"></a></p>
  
  <p>I've tried to connect the YearWeek Dim table to an actual Date Dim table hoping that time intelligence would kick in; the problem is that both for the Fact Table and the Date Dimension table the YearWeek Dim is the unique value which won't work given the filter-direction. If I start messing with many to many relationships or bi-directional filtering I'm out of my depth.</p>
  
  <p>How to fix this?</p>