Spreadsheet: 292970d1390850094-comparing-most-recent-data-data-example
Sheet: Sheet1

Date |  |  | Most recent data will be entered on the bottom, although if there is a way to continually add the data at the top, I would do that, I just don't know how.
2014-01-01 00:00:00 | 2 | yes
2014-01-02 00:00:00 | 3 | no |  | 5 most recent entries |  |  | 10 most recent entries |  |  | 20 most recent entries
2014-01-03 00:00:00 | 2 | yes |  | # | # of yeses |  | # | # of yeses |  | # | # of yeses
2014-01-04 00:00:00 | 3 | no |  | 2 |  |  | 2 |  |  | 2
2014-01-05 00:00:00 | 4 | yes |  | 3 |  |  | 3 |  |  | 3
2014-01-06 00:00:00 | 5 | no |  | 4 |  |  | 4 |  |  | 4
2014-01-06 00:00:00 | 2 | yes |  | 5 |  |  | 5 |  |  | 5
2014-01-06 00:00:00 | 3 | no |  | 6 |  |  | 6 |  |  | 6
2014-01-07 00:00:00 | 6 | yes |  | 7 |  |  | 7 |  |  | 7
2014-01-08 00:00:00 | 5 | no |  | 8 |  |  | 8 |  |  | 8
2014-01-09 00:00:00 | 4 | yes |  | 9 |  |  | 9 |  |  | 9
2014-01-10 00:00:00 | 2 | no
2014-01-11 00:00:00 | 8 | yes
2014-01-12 00:00:00 | 6 | no |  | I have yearly averages and medians for the questions, I am trying to identify trends that are deviating from the mean in the last 5, 10, 20 entries
2014-01-13 00:00:00 | 2 | yes
2014-01-14 00:00:00 | 3 | no |  | I need a formula that will constantly update and only grab the most recent 5, 10, 20 for each number. Most of the formulas I tried only looked at a fixed number of
2014-01-15 00:00:00 | 2 | yes |  | cells.
2014-01-16 00:00:00 | 5 | yes
2014-01-17 00:00:00 | 4 | no
2014-01-18 00:00:00 | 2 | yes |  | Although, I will be entering several on some days, I don't think it matters. I just set up the dates to give you an idea of how I enter the data.
2014-01-19 00:00:00 | 3 | no
2014-01-20 00:00:00 | 6 | yes
2014-01-21 00:00:00 | 5 | no
2014-01-22 00:00:00 | 4 | yes
2014-01-23 00:00:00 | 2 | no
2014-01-24 00:00:00 | 3 | yes
2014-01-25 00:00:00 | 2 | no
2014-01-26 00:00:00 | 4 | yes
2014-01-27 00:00:00 | 2 | no
2014-01-28 00:00:00 | 3 | yes
2014-01-29 00:00:00 | 5 | no
2014-01-30 00:00:00 | 4 | yes
2014-01-31 00:00:00 | 2 | no
2014-02-01 00:00:00 | 3 | yes
2014-02-02 00:00:00 | 6 | yes
2014-02-03 00:00:00 | 2 | no
2014-02-04 00:00:00 | 3 | yes
2014-02-05 00:00:00 | 5 | no
2014-02-06 00:00:00 | 8 | yes
2014-02-07 00:00:00 | 7 | no
2014-02-08 00:00:00 | 2 | yes
2014-02-09 00:00:00 | 3 | no
2014-02-10 00:00:00 | 9 | yes
2014-02-11 00:00:00 | 3 | no
2014-02-12 00:00:00 | 4 | yes
2014-02-13 00:00:00 | 2 | no
2014-02-14 00:00:00 | 5 | yes
2014-02-15 00:00:00 | 4 | no
2014-02-16 00:00:00 | 2 | yes
2014-02-17 00:00:00 | 3 | no
2014-02-18 00:00:00 | 5 | yes
2014-02-19 00:00:00 | 7 | yes
2014-02-20 00:00:00 | 6 | no
2014-02-21 00:00:00 | 2 | yes
2014-02-22 00:00:00 | 3 | no
2014-02-23 00:00:00 | 4 | yes
2014-02-24 00:00:00 | 2 | no
2014-02-25 00:00:00 | 5 | yes
2014-02-26 00:00:00 | 4 | no
2014-02-27 00:00:00 | 5 | yes
2014-02-28 00:00:00 | 6 | no
2014-03-01 00:00:00 | 9 | yes
2014-03-02 00:00:00 | 5 | no
2014-03-03 00:00:00 | 4 | yes
2014-03-04 00:00:00 | 2 | no
2014-03-05 00:00:00 | 3 | yes
2014-03-06 00:00:00 | 2 | no
2014-03-07 00:00:00 | 3 | yes
2014-03-08 00:00:00 | 5 | yes
2014-03-09 00:00:00 | 4 | no
2014-03-10 00:00:00 | 2 | yes
2014-03-11 00:00:00 | 3 | no
2014-03-12 00:00:00 | 5 | yes
2014-03-13 00:00:00 | 4 | no
2014-03-14 00:00:00 | 2 | yes
2014-03-15 00:00:00 | 3 | no
2014-03-16 00:00:00 | 5 | yes
2014-03-17 00:00:00 | 4 | no
2014-03-18 00:00:00 | 2 | yes
2014-03-19 00:00:00 | 3 | no