ProgressiveMonkey
ProgressiveMonkey

Reputation: 315

Presenting multiple choice question results in Google Data Studio

I want to use Google Data Studio to present the results of a form, in which I have a multiple choice question. Let's say we have option1, option2, and option3, and the respondents can choose any number of these: the result column will contain the responses separated by commas, e.g. "option1, option3".

I would like to present that as a bar chart in Google Data Studio, but can't find how.

If I set the field as "dimension", the chart has the correct labels for the bars, i.e. "option1", "option2" and "option3", but I can't find what to put as metrics to present in each one, how many times that has been responded.

I've tried breaking them out as separate boolean columns, in which case I can compute the count of each answer, but don't know how to put them in the same bar chart...

I expect to see a bar chart with labels "option1", "option2", "option3", and the count of each one as the height of each bar.

Upvotes: 1

Views: 3565

Answers (1)

Bobbylank
Bobbylank

Reputation: 1946

You will need to do separate calculated metrics for each option

Metric for option 1 example would be

SUM(CASE 
    WHEN REGEXP_MATCH(YourDimension, "(?i).*Option 1.*")THEN 1 ELSE 0
    END)

Repeat for each option and then add to your graph individually

Upvotes: 0

Related Questions