Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Tableau

You're reading from   Mastering Tableau Smart Business Intelligence techniques to get maximum insights from your data

Arrow left icon
Product type Paperback
Published in Dec 2016
Publisher Packt
ISBN-13 9781784397692
Length 476 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (2):
Arrow left icon
Jen Stirrup Jen Stirrup
Author Profile Icon Jen Stirrup
Jen Stirrup
David Baldwin David Baldwin
Author Profile Icon David Baldwin
David Baldwin
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Getting Up to Speed – a Review of the Basics FREE CHAPTER 2. All about Data – Getting Your Data Ready 3. All about Data – Joins, Blends, and Data Structures 4. All about Data – Data Densification, Cubes, and Big Data 5. Table Calculations 6. Level of Detail Calculations 7. Beyond the Basic Chart Types 8. Mapping 9. Tableau for Presentations 10. Visualization Best Practices and Dashboard Design 11. Improving Performance 12. Interacting with Tableau Server 13. R Integration

Efficient calculations

Calculations may be constructed differently and yet accomplish the same thing, for instance:

Scenario I

Scenario II

  • Create a calculated field with the following code:
    IF SUM (Profit) > 0 THEN   
    'Profitable' ELSE   
    'Unprofitable' END   
    
  • Place the calculated field on the Color shelf.

  • Create a calculated field with the following code:
    SUM (Profit) > 0   
    
  • Place the calculated field on the Color shelf.
  • Right-click on True and False in the resulting legend and rename as Profitable and Unprofitable.

Since either of the preceding scenarios will return the desired results, which should be used? The deciding factor is performance. This section will explore what to do and what to avoid when creating calculated fields in order to maximize performance.

Boolean/Numbers > Date > String

As this header suggests, calculations that use Boolean values or numbers are more performant than those that use dates. Calculations that use dates, in...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image