title: Finding the median of a range of values selected using vlookup
body: <p>Column A are dates and B &amp; C are Measurements</p>
  
  <pre><code>Dates   Measurements        
  1   56  15  
  2   45  25  
  3   62  76  
  4   15  42  
  5   165 56  
  6   16  79  
  7   45  46  
  8   47  79  
  9   24  47  
  10  12  14  
  11  147 47  
  12  195 19  
  13  443 79  
  14  642 43  
  15  462 75  
  16  156 87  
  17  794 49  
  </code></pre>
  
  <p>Start Date:2<br>
  Measurement:45<br>
  Code used to solve for the measurement<br>
  =VLOOKUP(B21,A2:C18,2,FALSE)</p>
  
  <p>end date:14<br>
  Measure:642</p>
  
  <p>=VLOOKUP(B22,A2:C18,2,FALSE)</p>
  
  <p>I used vlookup to find me the values that I desire, but now I want to find the median values of that range from the start to end date in each column.</p>
  
  <p>How can I code it so that once it selects the values, it can select the whole range and find the median values?</p>