title: Calculating Moving Average of Percentages in Tableau
body: <p>I have a data set below where I have a percentage of availability by item by month. I want to be able to calculate both a monthly average across items as well as a rolling average. I'm able to successfully create the monthly average but for the rolling average Tableau appears to be taking the monthly averages and just averaging those out to get the rolling average. This isn't correct. </p>
  
  <p>What I need is for Tableau to take all availability percentages for the previous months and calculate the rolling average based on that, rather than taking an average of the previous months' averages. </p>
  
  <p>Any suggestions? Packaged workbook loaded onto dropbox here- 
  <a href="https://www.dropbox.com/s/8amt6jnv9ycz6y3/RollingAvg%20-%20Copy.twbx?dl=0" rel="nofollow noreferrer">https://www.dropbox.com/s/8amt6jnv9ycz6y3/RollingAvg%20-%20Copy.twbx?dl=0</a></p>
  
  <pre><code>Item    Availability Percentage Month
  A   90% 1/1/2017
  A   95% 2/1/2017
  B   98% 1/1/2017
  B   67% 2/1/2017
  C   89% 1/1/2017
  C   92% 2/1/2017
  C   93% 3/1/2017
  </code></pre>