I have a large dataset filled with multiple data points. I've included a picture which consists of the following:
column A = IDs column B = Colors column C = Data points need to average
I need the average of only the first 2 rows of data (column C) where the ID (column A) = 1 and the color (column B) = Red. Then I would need the average of the next 2 rows of data with the same criteria. Then I would do the same to find the average where ID = 1 and Color = Blue. Then I would do the same where ID = 2 and Color = Red.
Normally I would do an averageifs formula but since I only need the first X rows of data to be averaged then I'm not sure how to tackle this problem. One additional caveat is that not every ID has an equal number of data points. So ID 1 Color Red could have 4 data points while ID 2 Color Blue could have 6 data points. Any help would be appreciated.