Using the following data set, I want to find the average rate, while counting how many times the values in Condition and Intervention are in the same row together.
This is an example of the table I'm using:
Condition | Intervention | Rate of Subjects Affected
-----------------------------------------------------
Anxiety | Drug | 0.02
Anxiety | Behavioral | 0.05
Anxiety | Drug | 0.001
Depression| Other | 0.7
Depression| Other | 0.8
And I want to create a query where it will only count for the Anxiety/Drug pair once and find the average of the two rates it collected (.02 and .001)
This is the result I'm hoping for:
Condition | Intervention | Rate of Subjects Affected
-----------------------------------------------------
Anxiety | Drug | 0.0105
Anxiety | Behavioral | 0.05
Depression| Other | 0.75
Please let me know if you have any ideas for this!