In Tableau, how can I create sub-category fields out of an overarching dimension?

I have a data set where it's more or less a star schema-like format, but in an Excel file. Don't worry about primary keys setup or any of that unless it significantly matters for answering this question. Here's a sample of the kind of issue I'm facing.

How, from a table like this, would I use Tableau to search by Cat and Dog as their own fields? In the default Tableau view, they all just show up as pet, and I can't find any way to seperate the two. I want to set up a chart with quantity of Cat on the X-Axis, quantity of Dog on the Y-Axis, and then each person graphed as a point relative to how many cats and dogs they have.

No matter what I search, all I find is information about grouping sub-categories, and I can't find anything about how to create the sub-categories in the first place if they aren't given to you. Could anyone give me a hand?

Name Pet Quantity
Sam Cat 1
Sam Dog 2
Pat Bird 3
Bert Dog 1

Topic tableau

Category Data Science


You could try the Tableau Logical Functions in a calculated field.

For example, to calculate the quantity of Cat, you could use:

IF [Pet] = 'Cat' THEN SUM([Quantity]) END

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.