In the following Google spreadsheet
| Description | No. of participants | Severity |
|---|---|---|
| Problem 1 | 2 | Minor |
| Problem 2 | 2 | Major |
| Problem 3 | 1 | Minor |
| Problem 4 | 1 | Minor |
| Problem 5 | 2 | Major |
I would like to create a chart that has the No. of participants as x-axis, the Severity as y-axis and counts the number of combinations.
The example above would look like this:
| 1 | 2 | |
|---|---|---|
| Minor | 2 | 1 |
| Major | 0 | 2 |
How can I get this chart extracted from the table in Google Sheets?
CodePudding user response:
use:
=QUERY(A2:C; "select C,count(A) where A is not null group by C pivot B order by C desc")

