Set it up: when to use set vs parameter actions

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
it is my pleasure we are actually going to start just a few minutes early because Heidi is ready to go and she has a lot of information to cover with us today on setting it up when to use set versus parameter action now Heidi really found a love for data visualization and has really just taken off since 2017 she has trained over 300 people she works at the information lab deutschland and I think the only thing a little birdie has told me that oh the only thing that Heidi loves more than data visualization may be alpacas so there's your fun fact on a Friday so let's give a warm welcome to Heidi calve setting it up when to use set versus parameter action hi everybody and good morning to you in the u.s. because it's already afternoon here in Germany so I'm very happy to start a little early and happy to you to start you guys on this day so I'll just share my screen and I hope you are all seeing now they set it up starts like so Frank sitting for the introduction Emily as Emily already said I have a lot to cover so we will probably not have time for questions and I will not have time to show everything and detail but please do come up afterwards and bombard me with questions I'm happy to answer any and all that I can to the best of my abilities so this is sometimes happened to you that you see a tweet or a LinkedIn post where one of the table jealous of a community shows how to do something you never thought was possible in tableau and it completely blows your mind because it happens to me all the time in fact it has happened to me more and more frequently in the last year tableau keeps rapidly publishing new features some of the biggest recent game changes amongst them with set actions and parameter actions we've seen people accomplish amazing things with those two features and I will mention which blocks to check out later on but for my tff talk I want to get down to the basics what did we have before set and parameter actions came into play what are sets and parameters how do these actions change the way we vis what is it either if them can or cannot do and in which cases should we use one over the other and since fie Gordon absolutely smashed her tableau quiz a tff a pack a few months ago there will be a tiny little quiz at the end of my session as well so please whip out your phones or laptops go to Manta calm and use the code sixty five eighty 602 and yes there will be a tiny reward for the one who gets the highest points but let's dive right in what kind of interactivity in the form of actions did we use before to blow gifted us with set and parameter well of course there were filter actions and they were great they still are great they help us limit limit which kind of data is being shown but sometimes users have difficulty understanding what is currently being filtered an interaction between quick filters and actions action filters can be messy even if you synchronize them filtering across multiple dashboard using filter actions could bring out bugs at times users were unable to use filter actions to exclude the selected values rather than include them and depending on your use case you would need multiple actions per dashboard we also had and have highlight actions those will help us visually bring to the forefront certain selected values but those highlights would be gone the moment the users D selected the previously selected marks highlighting across dashboards again can be messy and if you're not careful and we're trying to highlight certain fields in a sheet that doesn't contain those fields everything will be grayed out so let's take a look at what we can do at the moment sets help us with these issues but what are sets I like to describe sets in my trainings as kind of an exclusive nightclub you're either in or you're out there's really only those two options that we have sub actions drive the way we see things and we can use them to visually show things that we weren't able to show before so let's use them let's see how we use them we use them for many purposes often we use them for easier filtering as you only have to drag and drop them into the filter card and tableau will automatically keep only your in values but you can also drop your set on to color size or shape in the marks card in order to change the way your marks are being displayed and of course you can create calculations around your sets one you will probably find yourself returning - time and again will be structured something like this if set then measure and since the set is technically a boolean field nothing more is needed in your condition you will use this to filter implicitly rather than explicitly when you still want to see other values in your sheet but also limit one measure to only the values contained in your set now let's take a look at an example we have here the co2 emissions of 250 countries from 1960 to 2014 and I want to highlight a few selected countries in order to see how the development over the past 50 years compares to their 2014 emissions and vice-versa so I just select a couple of bars I've already implemented my highlight action and we can see those lines being highlighted or it might be easier the other way around I select a couple of lines over here and the bars will be highlighted as well now the moment I deselect everything goes back or I just click anywhere else which might happen by accident but I also want to apply this to a second dashboard so again I've already applied this action and this is perfectly highlighted but if I want to deselect here I can't do that because this set doesn't originate a highlight action I can't try to highlight and then auto select and then again deselect but still the highlight action is saved so let's maybe try this another way I have created a set for my countries called country set I just added any kind of country in that and put it for the moment onto detail but I actually want to have my country set on color and we will see that those values that are in the set now have a different color if I want to make those lines slightly bigger I can also put the set to size and then those will again be a little figure than the rest of the lines I do the same thing for my other dashboard for my other sheet excuse me put the country search on to color and we will color the bars that are in the set and I've already implemented my dashboard action just let me remove the other tube and let's take a look at this one from every kind of sheet that I have in this dashboard I want to change the set and I don't have to select which fields to use here or where to apply the action because it always applies to one set I just have to choose the data source and then choose one of the sets that I have in here and it will change automatically for every she'd wear or use this set so I don't have to worry about the scope it will always apply to all the sheets where I have this set in my case I want to keep the set values when I deselect because that's what I don't have with highlight actions so hit OK hit OK again and if I see like Qatar here we can see that Qatar gets colored in the other sheet or if I select a couple of bars over here in the bar chart then the according lines will be colored and even if I deselect you can see it's still colored if I want to use the same thing in my other sheet then I just go to the sheets again put my country set on to color and that will change and also in my donut chart please don't ever use ten hundred and fifty values in your pie or doughnut chart so in my case I just want to put this two color again and then I don't need to use my country names anymore so I just drag them out and it all gets aggregated and you can see I have some space for a field over here and I want to use that so I have two sheets sorry two calculations want to calculate which part of the emissions comes from the countries that are in my set which is just if country said then imagine end so that just gives me an emission for my selected countries and I have another sheet to calculate what kind of percentage is that well I just take those emissions of the selected countries that I just showed you and divide that by the sum of total emissions and if I now select to show my mark labels I can see the percentage of the emissions from my set and again if I select a couple of bars over here we will see that this changes in the line chart in the bar chart and of course in my donut chart as well in my bubble chart and my band also changes so that's a big thing that we didn't have before I don't have to choose which sheets it applies to you because it's automatically in the set I can also use the set to sort my values so let's say I select some countries that are pretty far down in my bar chart then I would have to scroll all the way to find which are affected and I can simply put my set for example two rows so that those always get put to the very chocolate don't to show the header and then those values always show up at the top no matter which ones I choose so let's just choose a few other ones and you will see those automatically get sorted to the top now now that we saw a little example of what said actions can do let's take a more clear and look at that so we find that we can use set actions to filter I didn't show you that explicitly but that's an ability we have we can also use them to filter by excluding the values we select we can of course use set actions to change the color size or shape of a marks to change the scope of our calculated fields and they will react to single and to multi select there's a few things that set actions cannot do now this they will not react to measures they are currently not able to use multiple fields and of course since I said always sticks to one field we they can't spend multiple data sources but that is where parameters come into play parameters well tableau defines parameters as dynamic values that replace constant values and calculations filters and reference lines personally I like to describe parameters as values floating around in space they are completely removed from any kind of data source until you reach from your data source to the parameter and use it in some kind of way a parameter by itself isn't worth a lot unless of course you use it in text fields such as my reminder at the bottom to join the quiz but you always need to reference it in a filter calculation or reference line somewhere parameters can do a bunch of things that are difficult to accomplish with sets or even impossible for example you can filter or calculate relative to a parameter you can for example filter on a six-month span around it data set in a parameter or color everything that contains a string value in a parameter you can also use the same parameter in combination with any field in any data source so you can use them across databases since parameters by themselves are completely removed from your data you can reference them anywhere in your data and of course you can use them to set reference lines now again let's take a look at an example I have three different sheets here that come from three different data sources so we have our superstore to the left we have kickstarter and co2 emissions on the right and I want to be able to set a focus year to focus my sales in the superstore and I want to see the Kickstarter pledges in that year the co2 emissions in that year and also want to highlight the previous period and for that I created a parameter so I go to my sheet just to show you the parameter I created it's I selected here and this is simply an integer value at the moment it has some value so that you can't see anything but I allow all kinds of values because I will drive it from my data and I assume that I actually have valid data that contains yes and then as it's only floating around in space I have to use it somewhere so I have a little calculated field in here where I say I want to have my selected year and I see how many years are between the selected year and the year of my Kickstarter or when my Kickstarter project was created if the difference is zero then I want this to be my selected period if it's one and it's my previous period and I just want to bunch all the other years together in a string called other and I have the same thing for my co2 emissions so again I have my parameter action yeah which is basically the same thing but in a different data source because that's how it works you can see it's a different field here but again the rest of the calculation is pretty much the same since I want to drive the color in my superstore sales as well I have feels here as well but I wanted to do something a little special I didn't just want to color the year I wanted to have a color scale I wanted it to be grayscale if it wasn't my focus year but I wanted it to be a colored scale if it was so I created two fields in here so I have one that gives back my sales if my order date is the selected yet and one that gives back my styles if it's not be selected year and if I now put my measure values on to color you can see I already have my measure values on columns and then select to use separate legends well can't see much yet but if I select any year now this will be colored and you can see year 2013 is colored and it's also colored in the monthly Kickstarter pledges per year and we also have the previous period colored which is 2012 and that is because I have three parameter actions in here so I can click anywhere on the co2 emissions and it will drive my selected year parameter by the field year of co2 emissions and in this case I don't want to aggregate because I have single years only so if I see like 2011 now in my co2 emissions we can see that it changes in all the three sheets and if I see like say 2012 in the Kickstarter pledges again it changes for all the other sheets so that's how can simply drive my parameters but let's look at a different example let's say I have a huge number of clients and I want to see all the clients that start maybe with AC because I'm interested in Christopher and maybe I have some superstition that all Cline's starting with a see I don't know bring in the higher sales or anything so I have created again a parameter which is just a string parameter again allowing for all values and in this parameter I want to select or I want to collect the first levels so the initials of my clients for that I have a calculated field which just gives back the first letter and I want to see if that first letter comes up in my parameter and if yes then I want to have the first letter and if not I just want to group them together under the fields other and I have a second data source which is just this little helper sheet which is just a tiny little keyboard data source and again I have my selected characters in here and if my parameter contains a certain character then I want to be gifted this character and else I want everything to be under other put this selected characters to color and let's see what happens now so if I said I'm interested in all the clients starting with a C I simply press E and they are all colored everybody that starts with the C or if I want everybody who starts with a T I can do that and because I drove my parameter action this way I can even select multiple because I said if I click in the keyboard I want this parameter to be driven by the Capitals and I want to be able to concatenate so I want all the that I selected to land in my parameter so if I select asdf just give me a moment then they will all be colored we can see it gets super beautiful and I have all these values in here so that's how I can drive my parameter to take several values now let's summarize how parameter actions can make our lives a little easier they can take values from any field in any data source thus spanning any and all data sources you might use in a workbook they will aggregate the values you feed into them if you see like multiple and that's a big thing or you can use them to color your marks set labels or set reference lines on the other hand they cannot really take more than one value because they can always only be assigned one but it's kind of a moot point since we can now concatenate strings so that's kind of like taking multiple values but the main question now is how can you decide whether to use a set action or a parameter Direction how will you know when to use one of the other and I suggest you pay attention now because this is what we will talk about in the little quiz in just a minute so depending on the number of data sources that you want to use if you only have one you can use either side actions or parameter actions but as soon as you use multiple you will always have to use a parameter actions because sets stick to one data source and the same applies to the number of fields that you want to use in your set action or parameter action if you only have one field either action is fine but as soon as you have multiple you will have to use parameter actions because sets stick to only one field now how about the values if you have discrete values you'll be fine again with other sub actions or parameter actions but soon as you have continuous values parameter actions will serve you better selection now this is kind of a big thing so if you select only single values only single marks then again either action will be fine for you and both actions do react to multi selection but there's a difference in how they react to this so set actions will simply add all the attributes all the values you select they will be added to the set but parameter actions since parameters can technically only take one values they will first aggregate all the values that you select by taking this sum or the average or the minimum or the maximum or as you just saw with strings by concatenating them and then they will assign that aggregate to the Kurama term if you choose to aggregate so if you choose to have none and as you're aggregating then they will not react to multi value selection so that's also important to note in terms of styling both actions can assign colors or size or even shape if you want to color or size discreetly so only make distinct differences then set actions might be a little easier to use because you don't necessarily need a calculated field which you always need with parameter actions but as soon as you care about the deviation of something where you definitely have to calculate either one is fine and last thing filtering yes you can use both to filter but you set actions will help you filter multiple values if you want to include or exclude multiple whereas parameter actions will help you filter relative to a value now I hope everybody is happy to start the quiz and there we go and let's just start and be fast to get more points the first question which of these actions can you use across multiple data sources is its actions or parameter actions well both or neither and let's actually take a look at the church people are voting perfect so two people get this correct it's the parameter action where you can use multiple data sources next one if you have only one discreet field of origin you can use this one is that such actions or parameter actions or is it both or is it neither only one discreet field of origin and it's both perfect yes sir actions is correct but you can also do this for parameter actions so you're not technically wrong just not fully correct now you don't need a calculated field using this to shape your marks subset actions or parameter actions or both or neither let's take a look and it's set actions all right so let's take a look how the leaderboard is currently don't worry we have two more questions well let's see who's in the lead and Orion Wow Ryan gain to the forefront and Matthew and crop falling up really close so two more questions they have a slightly different structure now can you use multi selection for parameter actions yes and tableau will always aggregate or concatenate yes but only for numerical values yes but only if you choose to or know which one is it yeah there were was a little tricky so tableau will not always affricate or concatenate if you don't choose to so you have to choose again not technically wrong just not fully correct and our last question to get points with which action is best for filtering purposes is it's at actions because you can filter multiple values or parameter actions because you can filter relatively or filter actions are always best or is it either yeah and again depending on your use case it will be either so one more question that will not give you any points but I just want to know are you ready to set it up what are you itching to try at first what are you really aiming to get your hands on just type in a few answers give you a few more seconds oh rewatch this yard was a little quick parameters gotta love parameters whoa okay both yeah already using okay that's good so perfect thank you very much let's take a look at the final score and is Ryan still in the lead oh no oh magical right now coming up no it's Matthew well Matthew congratulations you won and as I promised there will be a tiny little price so those of you who follow me on Twitter or Instagram you might be aware that I do post ukelele videos from time to time so Matthew please get in touch with me after this and we'll figure out which song I will address personally to you and you will be gifted a little song on the ukulele from me so let's just go over the last slides I promised you a few more resources what did we have before that's what we talked about we talked about what our sets what our parameters how can we use those actions to change the way we vis what can and can they not do and how can we use one over the other and if you want to learn more because I know this was just a very shallow look at them please checkout betting lines Lindsay Paul to mark read Rosario gonna rhyme genzel if you want to know more about selections and for parameter actions I can definitely recommend jonathan draw me Joshua Milligan can flirt Kevin flare edge and again Lindsay Poulter so I will probably post these on Twitter later don't need to memorize them all but please do check them out because they are absolutely brilliant and if you have any more questions please get in touch with me thank you so much for participating feel free to reach out via Twitter LinkedIn or Instagram Matthew please get in touch and feel free to follow me on table public and find out if I might at some point be one of the cool kids and maybe I will do incredible stuff with stats and all parameter actions one day thank you very much
Info
Channel: Tableau Fringe Festival
Views: 415
Rating: 5 out of 5
Keywords:
Id: t3K7toNpeeM
Channel Id: undefined
Length: 29min 7sec (1747 seconds)
Published: Thu Jun 18 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.