48
Cool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using Tableau Public Version 10.2. As versions are updated, you may see potential layout options vary. When that happens, you may find it helpful to visit the Tableau Community Forums for assistance: https://community.tableau.com/welcome . Adding Data When you open Tableau Public for the first time, you’ll see that the program is divided in to 3 areas: Connect – Allows you to upload a File. These files could be Excel, Text, Access, JSON, Spatial, or Statistical files. Open – If you’ve previously worked on a document, the document will be available for you to access. Discover – You’ll be able to access How-to Videos and other Resources For this demonstration, we will utilize an Excel file of Cat vs Dog Popularity in the US. This file is available for download at: https://public.tableau.com/en-us/s/resources in the Lifestyle section of sample data set. In Tableau, under the Connect section, select “Excel” to upload that file.

Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

  • Upload
    haquynh

  • View
    217

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Cool Creative Communications: Dazzling Data Visualization

A Brief Guide to TableauThis handout was created using Tableau Public Version 10.2. As versions are updated, you may see potential layout options vary. When that happens, you may find it helpful to visit the Tableau Community Forums for assistance: https://community.tableau.com/welcome.

Adding Data

When you open Tableau Public for the first time, you’ll see that the program is divided in to 3 areas:

Connect – Allows you to upload a File. These files could be Excel, Text, Access, JSON, Spatial, or Statistical files.

Open – If you’ve previously worked on a document, the document will be available for you to access.

Discover – You’ll be able to access How-to Videos and other Resources

For this demonstration, we will utilize an Excel file of Cat vs Dog Popularity in the US. This file is available for download at: https://public.tableau.com/en-us/s/resources in the Lifestyle section of sample data set.

In Tableau, under the Connect section, select “Excel” to upload that file.

Locate the file where you saved it and select the file.

Page 2: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

From there, click on “Open”

Depending on how fast your connection is to upload, you will then be taken to your Data Source page on Tableau Public.

1. In this section, you can see how Tableau reads each of the different data categories.2. If you have multiple worksheets in your file you would find them on the bottom left

corner. 3. If you wanted to, you could combine worksheets using the above white space which

allows you to connect tabs. Unfortunately, we don’t have more than one spreadsheet to demonstrate this.

Page 3: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

One of the first things you may notice is that for the column labeled “Location” it is listed as Abc as the category. However, it may be more beneficial to change it to a Geographic Code instead. To do this, click on “ABC” Above Location.

Once you click on ABC, you should see a drop down that gives options to change how the column is recognized. For this column in particular, you will scroll down to Geographic Role and then change it to State/Province.

Page 4: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

You should take a moment to look at the other categories and see what they describe as well.

Creating a MapAfter you’ve made changes to the spreadsheet, on the bottom left, you should see a symbol to go to the Worksheet. Select “Sheet 1.”

Your screen should have a number of different options available and it could be quite intimidating at first!

Page 5: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Let’s create a basic map to start. On the left hand side, under Dimensions, you should see “Location”. You can select that dimension and drag it over to the middle of the Drop Field area.

Drag Location into the middle of your sheet.

Page 6: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

What you should see is a map of the continental U.S.

A map of dots looks kind of bland. So, what would be good since we are comparing data of popularity between cat and dog ownership is to create a calculated field.

A Calculated FieldUnder Measures, right click in a blank area and select Create a Calculated Field

Page 7: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Calculated Fields are rather tricky and may require some practice. To learn more, I recommend visiting the Tableau website page on Creating a Calculated Field: http://onlinehelp.tableau.com/current/pro/desktop/en-us/calculations_calculatedfields_create.html.

You can rename your calculation. For this project, we’re going to do a simple calculation.

To do a Calculation, you can either type the Measures in the empty box OR drag the Measures over into the box. We’ll do a simple calculation and subtract percentage of cat owners from percentage of dog owners.

Page 8: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

This is a rather simple calculated field. As you work on a calculation, Tableau will automatically determine if it is a valid or invalid calculation. Since we’re doing a simple calculation, it is recorded as a valid calculation. You can click on OK from here.

The calculated field has been added to your Measures.

Using a Calculated Field/MeasureWhat you can do now is take that measure and drop it into the Marks section in the box labeled Colors

When you do that, the map changes colors

Page 9: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

If you scroll over the states, you’ll see that the blueish colors show that there are more cat owners in the NE and NW corners of the U.S. and the rest of the states have more dog ownership.

Scrolling over the State of Texas, indicates a higher ownership of dogs than cats in this instance.

If you don’t like the Brownish color representing dog ownership, you can change it.

Editing ColorsUnder Marks, select color and “Edit Color”

Page 10: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Edit Colors Options look somewhat straight forward. You can see here that they are using Red and Blue as the two end points. However, the gradient is a bit extreme. In this instance, it may look better to check “Stepped Color” and have the colors change with 4 Steps.

When you make the changes, you can select “Apply” or “Okay” for it to be Reflected on the Map

Page 11: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Your map should look something like this now.

Creating Tool TipsWhat you’ll need to do now is change what happens when someone scrolls over a particular state. No one would really know what it means when they scroll over Texas and sees a negative number necessarily.

Page 12: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

For that view to change, you’ll want to change the Tool Tip. In the Marks Section, where you made changes to Colors, you should also see Tooltip.

What you will do here is select Measures and drag them to the Tooltip button. The three I’ll select are: % of Households with Pets, % of Cat Owners, and % of Dog Owners.

Page 13: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

At the moment your Tool Tip looks like this:

Let’s use some of the other data so that users can understand the information further. You should leave the Location information, but you can probably remove the calculation simply be using your curser and deleting it.

Here we will enter the % of Households with Pets, % of Cat Owners, and % of Dog Owners.

Page 14: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

After you’ve entered those three pieces of information. You can then to each row that you want to have the detailed information show, and click on the drop down button labeled “Insert” next to the red X.

You should be able to see each of the SUM percentages listed now.

Select the ones appropriate for each row.

Page 15: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Now when you scroll over a state, you’ll get the following information:

Create a FilterTo a user, they may want to look at a particular state, but could be horrible with geography. Let’s add a filter so that they can select the state they are interested in. To do so, we’ll drag the Geography Dimension to the box above Marks Labeled “Filters.”

A pop up window will appear which will let you select from the items associated in the list. If you were primarily interested in the Southeastern United States for your graph, you could deselect the States you don’t want to use for example. However, in this instance, we’re going to use all of the States. You can hit Okay or Apply.

Page 16: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

“Location” is now set up as a filter, but isn’t yet visible on the map. To make it visible, you’ll want to click on the drop down arrow next to Location and select Show Filter.

On the far right, you should see a list of all of the States. This isn’t exactly the most user friendly option. It may be more helpful to have it become a drop down so that a user can go to a specific state. To do that, you’ll want to go to the far right of this section and click on the drop down arrow. You’ll see a list of options. Select Single Value (Drop Down).

Page 17: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

You’ll see that the list is now converted to a drop down menu.

If you select a state from the drop down menu, you’ll see that the map of the entire U.S. changes to the specific state with neighboring states grayed out.

Page 18: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Edit a TitleYou can see that the title of the Data Visualization is listed now as “Sheet 1.” You can change that to another title simply by double click or right clicking over the title.

In this Box, you can change the title of your graph.

After you make any changes to the title, you can select OK or Apply

Page 19: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

When you’ve made all of your changes to the title, your final map should now look like this:

This concludes the creation of a map.

Create a Chart/Bar GraphLet’s now create a simple bar graph comparing the % of Cat Owners versus the % of Dog Owners. To do that, we’ll need to go to another sheet. Click on the icon next to Sheet 1.

When you do that, you open a brand new worksheet becomes available for you to use. For this comparison table, I want to put the “Geographic Location” in the “Rows” and the Percentage of Cats and Percentage of Dogs in the “Columns.”

Page 20: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

It should look like this:

Showing the Labels in a ChartThe bars don’t necessarily mean much and would require the user to scroll over a particular state to see the information. To show the measures directly, you can click on the label button and select “Show Marks”

Page 21: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Editing a Calculation NameAfter you’ve selected that, you should see numbers next to each bar. At this time, we have Percentage of Cat Owners and Percentage of Dog owners as the same color. However, the color scheme doesn’t match the color scheme of the map we just created. If you look at the map, it appears that the shade associated with Red is attributed to a higher percentage of dog ownership versus cat ownership. Blue is associated with a higher percentage of cat ownership. However, it looks like it doesn’t necessarily appear that way with the grid. It might appear to the user that red is indicative of higher cat owners. Let’s make an adjustment to the calculation so that it shows.

Back in the first worksheet with the Map, click on the Measure Cat – Dog. You should see a drop down arrow. Click on Edit.

Page 22: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Let’s change the title of the Measure to Dog vs Cat Ownership in the Title.

The grid now appears to align with the title.

Adjusting Colors in a ChartGo back to Sheet 2. We should leave Percentage of Cat Owners as a Blue Color, but we should change the color of Percentage of Dog Owners to Red to match the map. To do this, under the Marks Section, click on the Drop-Down Arrow for Dog Owners.

The changes you make here will reflect the Measures for Dog Owners specifically. If you didn’t do this, all of the changes would reflect the entire worksheet.

Page 23: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Select Colors.

Converting an AxisCurrently the bar graph for dogs is Blue. Click on Red so the bar graph could match and look similar to the map. You’ll now see that the column for cat owners is blue and column for dog owners is red.

It may be really neat to have the column of cat ownership inverted so that the base line is right next to dog owners. To do that, let’s edit the Axis. On the bottom of the column that mentions Percentage of Cat Owners, right click near the title and select Edit Axis.

Click on Reversed and Click on OK or Apply.

Page 24: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Your graph now shows a comparison between Cat and Dog Ownership

Adding a Filter in a ChartLet’s add a filter so a person can drill down to their own state if they would like. Drag the Dimensions over the Filter like we did in the map demonstration.

Select Okay with the Pop Up Box since we want all measures.

Page 25: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Click on the Drop Down Menu for Location and select Show Filter

On the far right of your graph, the location filter is visible. You’ll want to click on the drop down next to Location and select Single Value (dropdown)

Page 26: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Edit a TitleYou can edit the Title to Sheet 2. Right click next to the title and select Edit Title

Change the Title to something that you would like to name it

After you edit the title, you can select Ok. You now have a completed Bar Chart.

Page 27: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Creating a DashboardLet’s Combine the Map with the Bar Chart now. To do that, we’ll create a Dashboard. It can be found in the bottom row where you can alternate between Sheet 1 (Map) and Sheet 2 (Bar Chart). Next to adding a New Worksheet, we’ll select the next item which is “New Dashboard”

Size DimensionsThe first thing I want to do is change the size dimensions to be automatic. This will give an opportunity for the shape of the dashboard to hopefully alter if viewed on a mobile device.

First Click on the drop down next to the dimensions listed. You should see a drop down next to Range. Select Automatic.

Your dashboard will automatically adjust.

Page 28: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Adding a MapLet’s move Sheet 1 to the Blank section.

Adding an Additional WorksheetThe Worksheet you created is now fills the entire Dashboard. You’ll then want to move the Bar Chart (Sheet 2) to the Dashboard. You can have it side by side or on top of or below the Map. I’ll have the Chart below the Map for this demonstration.

Page 29: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Your Dashboard should look like this now.

Editing the DashboardHide TitleLet’s hide the title of the Bar Graph since we already have the title of the Map. Right click next to the title and select Hide Title.

The Dashboard should adjust with the additional space made removing the title.

Editing FiltersNow we notice that there are two filters for location added. This happened because we have two filters created for both worksheets. If we change the state of the top filter, it only changes just the worksheet of the map. If we change the bottom filter, it only changes the table. This could cause unnecessary work to the user. Let’s adjust one of them so that when we do a drop down to a particular state, it changes both Worksheets at the same time.

Page 30: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

With the top filter, You will click on the drop down next to the X. Select “Apply to Worksheets.” You’ll see an additional window open that says, “All Using This Data Source.” Select that.

When you select that, the top filter should adjust for both the Map and Table.

Removing a FilterYou do not need 2 filters for Location. On the bottom filter, click on the X to remove it from the Dashboard.

Page 31: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Floating FiltersIf you want, you may want the Location Filter to be on the left instead of its own column. Along with the Chart Indicating Colors. To do so, let’s make both filters and indicators floating.

With the Filter, Click on the Drop Down Button and select Floating.

You can now move the Filter to another spot on your Dashboard. You’ll want to be on the lookout for the middle section with several dots which gives you the ability to move the filter.

Page 32: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Do the same for the Color Indicator. You may decide to have the color scheme line above the location drop down.

Editing Worksheets to Help Tell Your StoryIf you make changes to the worksheets, they will be reflected in the Dashboard too. Since we have Dogs as the color Red in the Filter on the Left and Blue for Cats on the right, we can change that in the Worksheet. Go back to Sheet 2 and switch the column measure order so Dogs is before Cats.

This changes how the axis looks.

You’ll want to set it up so that they are against each other again.

Page 33: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

On the bottom, right click and select Edit Axis. Click on Reversed for Dogs. Do the same for the column of cats, but uncheck Reversed

Reversed for Dogs - Checked

Page 34: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Reversed for Cats – Uncheck

The Chart is updated in the Worksheet.

Page 35: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

It is also reflected now in the Dashboard you created.

Congratulations! You’ve finished the graph comparing percentage of dog and cat ownership.

Publishing and Sharing Your VisualizationWe can now publish and share it with others.

Click on the Save icon.

You will need to sign in to your Tableau Public Account.

Page 36: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using
Page 37: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

Go ahead and name your Workbook.

It will go ahead and save your document AND take you to the website where your visual is saved.

Page 38: Adding Data - NNLM | National Network of Libraries … · Web viewCool Creative Communications: Dazzling Data Visualization A Brief Guide to Tableau This handout was created using

From the saved file, you will want to share the document so that your peers can have a chance to review it. At the bottom of the graph, you’ll see two options, Share and Download. Click on Share

Copy the Link provided so that you can paste it in the Discussions of the Moodle LMS for the class. You’ll follow the discussion prompt with your assignment. Additionally your peers will have an opportunity to review your graph.

Later, as you become more acclimated with Tableau Public, you may decide that your creation should be embedded in a website. The Embed Code listed above gives you that change to do so.

I hope this demonstration was helpful. While there’s only so much you can learn from an introductory class, I have provided links to where you can learn more about Tableau in the Moodle LMS.