When Sets Rock, When Parameters Roll

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone good morning and thank you for coming to our session today I know you're all pretty excited and there was a lot of choice of really good sessions to to attend right now so we are really really happy to see so many bright faces wanting to spend some time an hour with us talking about Seth and parameter actions there's gonna be fun we're gonna have a really really good time but so you actually know who we are I'll give you a quick presentation so I'm here with selcuk one of my favorite co speakers that's hello actually we've been doing this a long time together and subject is one of the solutions consultant at tableau based on our London office he actually is a specific type of consultant he works with our global systems integrators so a lot of his job is actually making tableau part of a more global solution not just tableau by itself but tableau is part of a more wholesome holistic conversation but Celtic is a lot more than that as well and I'm I'm warning you because you might actually see him do this sounds like is a very keen photographer he'll do anything to get the most candid picture he can including dressing himself up as camouflage and try to pass for a Christmas tree so if you see a Christmas tree at date a night out that's probably what's happening well thank you one for basically reviewing my secret now everybody will know how I look and I can't take funny pictures of people but that's fine well I need to return the favor probably and well he's also one of my favorite co speakers probably the most favorite cause Baker worked with and he's also based in London in our London office so we work together very closely we are in the same team and even is looking after the Spanish and Portuguese market because he speaks both languages so a lingual person you can go and ask him anything about food bread and basically anything good in life like good life any any question that you want good places to go good food to have good restaurants he's really good expert in that but besides that he is also a good like lab one of the favorite things it does is listening to music it was one of the persons who was leading one of the marketing campaigns at last year in in Europe called party with your data he's so much in love with out that he has today so you can see and he's also the one who brings really positive mood in the office when we have gloomy rainy days in London he basically does impromptu dance moves all the time and makes sure that everybody has fun so this is us and we are really happy to meet you as well today we want to talk about setting parameter actions and actually we saw certain parameter actions for the first time two years ago at that point certain parameter actions were not even considered to be features in public they were just a hack by some developer in tableau that thought that it's a cool feature and we had a hackathon in London and tried for the first time setting parameter actions and many of us solved a customer issue that we couldn't solve before using these features and everybody was so much in love with them that they we wanted the features to be released basically yesterday so that's why we are we want to show you the power of certain parameter actions to you as well and what you can do with them if you take them a little bit further and combine them with some toggle features and we will do that with some examples that we built for you and we'll build some of the the dashboards together with you so that you can see how they can be used easily and by the end of this session we are confident that you will understand when to use certain parameter actions and which one to choose in which situation so the main purpose of this session is first to explain what they do and how they work but second and most importantly to tell you why both of them exist and when to choose which then we also want you to be able to combine these features with what we already have in tableau so that you can get the most out of them and finally certain parameter actions are really really good for solving complex business questions that you may have day to day so we want to show you how you can do that easily just by using these two new features but before understanding how you can use them and when to use them we need to understand first what sets and parameters are because certain parameter actions will work based on the properties of these two features perfect so exactly like self-check said what makes sets and parameter actions super powerful is actually based on the inherent properties of sets and parameters so I know this is a Jedi session and a lot of you will be familiar with these concepts but this is extremely important if you're if you dominate the concepts that I'll explain now you will immediately understand why sets and parameter actions are such a game-changer that's why I'm gonna review them together so what are sets conceptually speaking sets are just a way to dynamically group dimensions it worked as a boolean and this is really important so the result of a set is also you always an in or out but you can sort of think as a true or false it has the same properties it also has a fixed level of detail and again later on we're gonna see why this is so important when you create a set you always created at a dimensional level a set is fixed to that dimension and every calculation or anything that affects that set will be calculated at that level independent of what's on your view independent of what level of detail you working on in your in your dashboard and then finally they're fixed to the data source so one set one data source they don't it doesn't work across data source and you will see later that that's not the case for parameters okay so this was very conceptual so let's look at it in action let's start with a random dimension with five members called country we have five countries France Spain Germany UK and Portugal these are the members of the dimension and as you can see we work in Europe so we sort of always default to European countries when we create a set of that country we we only have two members of that set the ends and the Alps and every single member of the dimension country will be either in or well some countries are just really keen on being out but that's I know I know but that is the key point everything will be either in or out there's no there's no third option this is really important so what about parameters so perimeters are a little bit more of a is an easier feature to understand because we've all been using it for a very long time perimeters Indian really they are just inputs that the end user can add that can then be used in calculations there can be any data type so different to sense they're not necessarily bound to a dimensional level to a string they can literally be any data type and they can be defined manually that has been possible for years but now they can be defined through an action and also and this is quite important parameters work is their own data source so parameter you can use one parameter to affect two three five data sources it really doesn't matter also this also means that two input into the parameter it doesn't care whilst the set will be will require the same dimension to be inputted into the parameter into the set sorry the parameter really doesn't care all he wants is a data type so looking at it more in a practical example this is just a slider parameter that we're using to estimate different changes in our data or we can just we can allow the end user to just input certain values and define a change in salary so this is an approximation of earnings over time all of this is obviously fake fake data but the idea is that that's exactly what parameters have always been there for to allow end user interaction so we've understood conceptually what they are so let's talk about why what these actions are so important why do they change the game so much well to understand how certain parameter actions are so fundamentally different we first need to look at what our so-called legacy actions worked like so if you think of filter highlight or your election that existed in tableau for a while you may have an example where you want to the user to select a specific mark let's say on a map we select Brazil and an action would apply based on that selection and depending on what action you have created a filter or a highlight the corresponding the respective action will apply to the targeted sheet on the dashboard so this is how legacy actions work when we talk about setting parameter actions it's a little bit different the user again selects a specific mark on the map again Brazil in as an example but what happens now is instead of triggering an action immediately what we do is we store the value or the values of what the user has selected but that's really really important and also very powerful so what do you do with the stored values now well it actually depends on you because you are the person who will design the action so the action itself doesn't come out of the box like filter or highlight but actually you can design your own action the way that you want and that's what makes certain parameter actions so fundamentally powerful and different than our legacy actions they're a game changer they are like giving a painter a new color palette so that he or she can do new types of paintings that were not possible before and with certain parameter actions you will see that the interactivity and the expressiveness of your dashboards will increase tremendously and you will be able to engage more end users to use the dashboards and to get more value of the analyses that have done for them so you have created a set or parameter action but what are the things that you can actually do with them what are the types of interactivity you can create well the best way to understand it is to actually see it and I'm gonna show you a dashboard and I'm not gonna tell you exactly which action I'm gonna be using I'm just gonna tell me what's happening this dashboard is looking at property transactions in London and what what you can see first visually on our map is actually the difference within their borough from the average transaction price so you can see in red boroughs were tendentially as property sales are above average price and in blue the exact opposite and actually we have that average price across all of London here a little map that will show us our selections and a monthly trend showing us out the aggregate changes over time but lo I will just interact with this dashboard once and I'm gonna select a few boroughs I'll select a few of the expensive ones and you'll see things are changing and a few things have changed you with one single click I've changed the color of the map it's now no longer representing the average of the total is representing the average just from my selections so I can compare amongst all other boroughs in London how they compare to my selection I'm not filtering I'm not highlighting I'm creating a dynamic a dynamic way of analyzing this data I have the value now the average for the bar is that I'm talking about here I have here's the map showing me my selection and then finally I have a desire Gatien of the of the trend so I'm no longer looking at the aggregate level because I selected things it now decided to go to to go up one level of detail allowing me to much easier see what's happening with my data so I didn't show you what hax actions were here so what good actions do you think I use to create this dashboard so if you think about the what Yvonne did whether we use settle parameter action or actually he used both and he used them twice in different parts of the dashboard for the different actions that happen and that's the point of this session to understand when to use set actions and when to use parameter actions and as we mentioned at the beginning the reason why they they behave differently is because of the inherent properties of sets and parameters themselves that's why we have a few fundamental differences between set and parameter actions the first one is that set actions generally work on dimension levels so you you use dimensions to create sex whereas parameter actions can get as values anything in the data so they work both with dimensions but also with measures the data second set actions can store single results or multiple results whereas parameter actions can store only a single result and it can be aggregated but at the end of the day it will be just one value finally set actions work only in the data source that they have been created because sets work in the data source that they are created whereas parameter actions can work across multiple data sources so that makes them powerful in some use cases you will notice once you learn how to use them that setting parameter actions can actually be used interchangeably in many use cases so because they store values at the end of the day you can use either set or parameter action in many many use cases and that's why there is like a big overlap between the two but one of them will always be easier to use so we want to show you how you can get to the point to decide which one would be better the better one to use exactly that its inherent on their properties because sets and parameter actions store that value they will allow you to then construct calculations that achieve the end the same end result but because of their inherent properties one of them as its house extent will be easier or more performant that's that's exactly the goal of this session and so this is by far the most important question there will help you understand whether to use one or the other do you want to store individual values is the individuality of a member of a dimension important to your use case because if it is then you need to you probably better off using a set well on the other hand if the end result is something like a measure and aggregation you just want to store that value to then reuse it in a benchmarking or in the comparison then you're probably better off with a parameter action but I want to show you a couple of use cases there there use cases designed to take the complexity off the use case and focus on these concepts because when you take out of the one you understand these concepts you'll then be able to build exactly what you need okay so I want to start with a Pareto example so in this in this example I've just created Pareto charts showing me the percentage of customers or the percentage of sales so I can see different as I go right I see the percent of customers as I go up I see the percent of sales and this is divided as small multiples for all my individual product categories this this allows me to easily see shapes and overall patterns in the data but if you want to actually go down to the level of detail and compare one to the other up until today you would have to actually input the value that you want to see but with parameter actions I actually can just go ahead and select in one of my in one of my categories I can select the value and that value will be propagated to all the other visits actually so now I've selected 29% of all my customers that has been propagated across all the other charts but it also made a comparison with the percent of sales so it actually allow me to see that 29% of customers correspond to 56 percent of sales in telephone communication but only 38 percent in rubber bands so in this case it actually really doesn't matter which category were talking about the key point is that number that value that percent of customers so how can i how can I do this well the first thing I need to actually create a parameter action is an actual parameter but I actually can build it from the action itself so I'm going to go up here to worksheet and I'm gonna add a new action I'm gonna add this new parameter action to change a parameter and I want this to take out the per the percent of customers so that's first it's the field that's gonna go into my parameter then I'm gonna select a new target parameter you see I already have a lot of parameters in here but I can just create a new one from here and I call that right to build and I'll call that percent of customers I'll input that is zero and when you're using parameter actions in general I would recommend just keeping it on allowable values because you will be inputting it somewhere else so it really doesn't care if using a list or a range perfect so I can now press ok and now if I make that visible and I show my parameter control you'll see it here on the right the second one if I select a value it will update automatically that parameter that's what's happening on the background nothing extremely exciting right now but it means that I can now add a reference line for example or the percent of customers and base their reference line based on my new Pareto billed percent of customers label it as just a value and now exactly as we've seen in the VIS before I can just select one and immediately their reference line is propagated automatically to all the others well with just reference lines that's not particularly exciting it's a visual representation but that is just meant to show you how you can start so now I can go ahead and use the same parameter in a calculation and I call I'll call this my spiritual reference of percent sales and all I'm gonna do here is I'm gonna compare my Rachael percent of sales and I want this to be bigger than the actual parameter so retro billed percent of customers make this a little bit smaller and then I'll I'm just gonna ask this calculation to give me in case this is true - then give me the percent of customer Oh actually I want to hear the customer story right Oh customers then give me the Pareto percent of sales so this is giving me from from one comparison that's interactive is giving me the other one I'm gonna create that but your lies bring that into my view and then what I can do now is actually reference that calculation and now we're talking another level we're not just talking about actually having sales I'll change that to a minimum so we have the actual where it compares and then just so simple is that what I've been able to build is that analytical that interactive comparison where one built when one selection not only propagates the value but it propagates as well the the comparison because I use it in the calculation so this is the case where I didn't want to keep the level of detail I just wanted to keep the measure what about if i jus want to keep so this is another this is a sort of a very different use case where I it's a new financial year and I need to select regions for my sales territories and I want to do that in a data-driven way I want to allow end users to play with the groupings so they can select different different regions in this case different boroughs in London and see how that affects the grouping so this is actually a perfect use case for set actions on the other hand because in here what I can actually do is I can select different boroughs in London they'll be shown visually against all the others are yet and grouped and I can select the other group as well this just kept being populated and not only can I see them visually but I can come I can use that to actually build the metric itself I can aggregate this metric based on are my different groups so I can see here that normalize the average normalized prices of transactions from Group A versus Group B or even the number of our sales it's a sort of dynamic completely dynamic benchmarking where you're just selecting and grouping on the spot so how can you build something like that well as I said sad actions are a perfect use case for this because you want to keep that that information about the identity so you can just go ahead and use a set action but set actions you need to actually create the set before you build them so let's do that here to create our set I'm just gonna select a few burrows right click create my set doesn't matter what's in the burrows now because we're gonna we are gonna change them with the action I'm gonna call this group a I need to create another set for Group B so again I'm just gonna right click create set and call them be so we have our sets let's populate them with an action I'm gonna go here to dashboard action and in this case I'm gonna have to create two actions based on the last option of change set values I'm gonna select my first sheet for Group A which just lists all the boroughs in London and populate Group A with it and I'm gonna keep the set values and then okay and let's do exactly the same thing for the second one and in this case we want to add group B as you see here it actually doesn't ask me what the information I want to pass whilst the parameter if you remember did ask me this is because of what I was saying before a set already knows what it expects so it you can't give it anything else when you want to perform the action so now if I do a few selections here a few selections there myself should actually have changed but I can't see it visually as as you remember we have just store that information we haven't done anything with it so to do that we just have to create our new calculation for it I'm gonna go into my map create a calculated field which I'm gonna call that my market groupings and use the set in a calculation so this part is particularly important which is how you use the setna calculation so sets if you remember work as boolean so you don't need to make a comparison with anything all you need to do is put the name of the set and if the borrow is in the set it will be true if it's not it's false so all you need to do is just write if through a then a else--if else--if group B then B and then else ungroup this will give us our three groups again remember this is this is how you use a Santa calculation for a lot of us is not really intuitive because we're used to using parameters and making this sort of comparisons and now if I put it in color you'll see it goes the in group goes to red which is a bit too aggressive let's just change that with gray and now as easy as that without any sort of complex calculations or complex actions we can easily change the members of one and the members of the other there is one important thing though to take into consideration now is that because of the way you will built this we now could potentially have the same arrow in the two steps so what we really want to do as well is use the Narron properties of sets to actually filter them out so I'm gonna I'm now on the list for the group a and I'm actually gonna select Group B and add it to filters select in out and just select what's not in the group B same thing or the second one and you'll see in a minute why this is important I'm gonna go to group B bring up Group A so the other set select in out and feel to do just what's inside what this means is that now the end user if they select something from the first set it will disappear on the second one if you see if you notice some of my selections are actually disappearing so I'm it is now impossible for me as an end user to actually have Boris on two different sets so in the end you've seen I haven't done anything extremely complex but I was able to add this extra level of interactivity that the end user wouldn't have before and it doesn't stop there you can have as many groups as you want you can just go ahead make three territories look at sales in those three different territories and dynamically allow the end user to play around with what's inside a set and outside the set okay so that's as we said that's the main question in every use case but there are other there are others that are very very important as well okay so we saw that with these two examples when you use a parameter action and when to use a set action and the main question was do we want to aggregate the results into a single value or do we want to keep the individual values separate separately but there are a few other use cases where things get a little bit interesting one of them is when you work across data sources so a use case for that would be say if you have transactional database and then you have an excel file where you have the targets for individuals or regions and you now won't come to use like an interactivity that passes values from one data which is the excel file to the sequel to the sequel transactional data for example and in that case because set actions don't work across databases or data sources you need to use a parameter action therefore even before answering the question whether you want to keep the individual values or the aggregate values the first question to ask is do I work across data sources because if that's the case then a parameter action is the way to go let me show you an example so in this case we are using the data that even was showing about properties within London but instead of looking only at the price I want to be able to look at how different boroughs or different cost codes compare based on age maybe distance to subway like what is the average distance to a subway station or number of restaurants in that area so that you can have a multiple like app like a 360 view of understanding of the area and decide whether you want to invest there or buy a house so in this case what we want is also to provide a nice interactive use case to the end-user and instead of having you know drop-down menus or things like that we want them to use actually buttons to drive to drive the parameters and to see the results or if they want to see the results on a different level then the one that has been selected for them let's say instead of looking at the borough level maybe the entries er wants to go a little bit detailed and want to see the individual neighborhoods they can just click on these icons or pictures and then drive the parameter or the values directly from there so how do we do that we don't have these options within the data set the data set has just to translate the data about transactions about restaurants etc well basically what you can do in this case is create a different table which contains the values of what the buttons should pass as parameters so in this case we have four values about metrics and three values for for the level of detail of the map let me show you how this can be done for the metrics because it's exactly the same for the for the map values so I will just create it in a excel file but in your case it can be a database or view within your database that you can you want to store indefinitely and not on your PC so let's call this metric and it will contain four values one of them will be the price the other one will be the age then you will have restaurants and then finally distance to station so I can save this table and use it as a connection but because it's a simple table and we are just doing a network example I'll just copy these values and open a new sheet and paste them end table will create a clipboard for me with the values that I have just created it will be like a zip saving the excel and connecting to it so now the next step is to create a parameter which can populate which we can populate with these four values so I'll just create a parameter and pull it select a metric and then we because these are texts I will just keep it empty and selected string and that's it our parameter has been created let me show you it's empty at the moment now what I want is to pass the values in the metric directly to the parameter so I'll just create an action which will be our parameter action and let's see because it works across data sources I can say work everywhere in this workbook doesn't matter where I select it from work from everywhere or you can specify a given dashboard so it depending on where you want this action to happen you can basically select it from here so I'll just select this one and what we want is to create you pass this sheet 48 to the parameter and work it from there let me just omit it here and what we want the parameter to do is to populate the metric parameter that we just created with the selection that we do so I'll just pass the parameter and the metric from here as you can see and let's see how it works so when I select a specific metric as you can see the parameter is automatically filled in with what I selected so now I will add this sheet to the app the decision-making app that we have created here and will actually include the buttons in sort of just the text so if I just drag and drop the metric and create buttons from shapes that we have in in our repository then we can basically make this an interactive experience for the people so I'll just assign them as correctly so we have our sheet our buttons and the next thing to do is basically to apply this in a calculation because as you remember parameters are just idle if you don't use them in accounting so I will use the map because what we want to do is drive what has been selected on the map itself so this will be let's call it the selected metric calculation build and let's write the calculation as a case statement so this will be as a multiple if statement but it's easier syntax to use and we will call the method the parameter that we have just created it's selected select the metric so when the metric that we have selected is age then we want we want to show the average age basically and when it is price we basically want to show the average price and you can continue with the other two metrics as well just by writing the same things like when Station show me the station when restaurants show me the respect but let's keep it simple for now and I'll just leave it as the tips but let's pick okay so I will drag and drop this new field that I created in color and will make sure that my parameter works on this view as well so the the one that will figure the parameter is street 48 which we just created but we can give a good name later on and we want to pass the values that have been selected directly to this calculation so when we select a specific parameter it will immediately pass the values to that and as you can see that parameter or the values for the parameter was created were created in a different data set but I can still pass them through to my actual data so that I can see the results directly there so it's it's a good use case when you when you have different data sources and you want still to pass values in an interactive manner so that's the second question that needs to be answered like are you working across data sources but what is the next important thing so another key point to consider is that even if you want to store individual selections if the VIS level of detail is variable then you'll be hard-pressed to not use sad actions and this boils down to what I was saying before selection is by default bound to a lower set is bound to a specific dimension so you can easily navigate that if you're using a cell action so in this case our recommendation is to actually use a parameter action whenever the VIS level of detail might be variable and a moment once that is very likely to happen and that's actually where we we ran into the use case particularly often is when using dates because dates by default are something that you're always going to aggregate at a certain level so you can either and that's what I'm doing to you you can either make it visual and allow the end user to select date aggregations again we're looking at property transactions a number of houses sold and accumulated prices but the aggregation but which we're seeing these measures can be easily changed by the end user but even if the end user doesn't have this power you can see you can still have that even on your exploration stages if you want to use a set action on a date you have to by default define that in advance and you have to materialize that specific aggregation to a lot of stat action to work so in this cases it actually will be easier to use a parameter action okay so let's leave it at the Year level for now well some when I'm looking at the at the number of houses sold and I want to compare a period against the previous period I can easily just select that date and it would populate because of the parameter you populate that year but also the year before again this will this will work as well if we're looking at the quarter level if I select a quarter it will not look at the year before but it will actually look at the previous year quarter as well let me just put this in automatic so it looks a little bit better yeah that's better so the period actually updates based on what we're talking about in the parameter okay let's look at how we can build something like this as I said this is to give you an idea because when we were talking about dynamic date comparison parameter actions will really help allow the end user to select what they were going to look like that so in the first thing as we've established before the first step of creating a parameter action is to actually have a parameter so let's go ahead go to dashboard actions here and let's just build our parameter straight from here this change parameter will come from our date selector and we want to have our dynamic date aggregation and we want it to affect a whole new parameter called build select the date in this case I'm just gonna change the data type because I do want to save that date and I'm gonna leave it in all as well again I don't really matter what what I put here I just want every valley to be acceptable so I'll click OK have you seen I haven't added an aggregation I just wanted to to store that one unique value so this parameter will actually now change as I select different values but obviously again that doesn't really do anything that I can see as we know only after I use I create that behavior will I be able to see it so let's start by just adding a reference line to our dynamic data aggregation let's give it a white line and that space is that like quiet and let's base that on our build parameter so as you can see we've done something now we've stored that value of that date let's use that now in the calculation to find the periods before and after and that's very easy I'm gonna create a calculated field I'm gonna call that the select date minus one period and again all the calculations you're gonna see today are very very simple it's just it's the the parameter in the side action that makes it interesting also so I'm I'm gonna add to that to be my selected date one period and the period so the data aggregation who is actually the initial parameter that's going to define that so if it's a quarter you'll it will remove one quarter if it's here it will remove one year and then here I'm just gonna add my build select the date that's it that just gives me the period the period before my selection and let's go ahead and duplicate this and actually do the opposite edit this and add one period again same exact same calculation but I want to add one period to find the end of my selection oh oh sorry about that let me put that bus here there will be enough for me now I need to make sure I add these two calculations we're no longer talking about parameters so they're not global we need to go and add them to the level of detail on my view and I'm gonna create a select both and just look at the exact date so this rule as I said drink one period in one per year down let's look at it visually and actually now we could put a reference band here and start just by the - to the plus and create this little band and let's just take the labels as well well that's gonna look a bit funny oh so now if I go back to my dashboard no matter what I select that band will update and not only will little date visually but remember I have actually stored these values I can keep on using them in calculation I could change the bands as well to reflect the different periods as on the example before but actually what I would like to do now is just see them visually here and to do that again super simple calculation I'm just going to call that my periods to compare and again just a very very simple statement which is if my actual date in my data is above my selected period it's like the date minus one period and the date is actually less than the parameter so that's the field then it's part of the period one so very simply I'm just comparing that with the result of my copy that then the result of my parameter and also I want to do exactly the opposite where I want it to be bigger than my billed and less than my current period so like date plus one current period else just filter and I'll show you why I'll I use the third one so the first thing I'm gonna do is bring this new calculation into filter to exclude everything that's not within our selection that's part number one so now we've sort of materialized that filter action into the parameter action we still get the same behavior with added behaviors now the last thing is I want to add the periods to compare and add them to color so now I can see my prior period and my current period I could do a lot of calculations on top of this as well but I really wanted to show you how this allow you to do above and beyond what the traditional action will allow you to do because those are materialized and are purely dynamic so as you work through it you're actually creating several behaviors we have three different behaviors based on one unique play and again this is this is particularly exciting because it's all up to your imagination and your capability of building it so we've looked at already three different questions is there anything else we should consider when using these features well similar to what we did with the data sources example with the multiple data sources example you can actually pass values using parameter actions outside of tableau as well and it's again a use case of maybe an eight use case but very very important for parameter actions I work with consultancy companies who help a lot of enterprise customers doing planning and what-if analysis and they want to make it visual and interactive for the end users or the management for presentation purposes and one of the things that basically was very very interesting use case was a financial planning dashboard so obviously this is a simplified version of that dashboard but imagine the case where you have the values for your gross sales the expenses that you have etc and calculations of your gross profit for the last two years let's say and you want to do scenario analysis for what would happen if my sales increases as sales increase or my expenses decrease or increase in a certain way so that could be done previously with parameters as well but now using parameter actions you can make it much much more interactive and also you can actually create new scenarios that didn't exist before so let me show you how it works at the moment what we see here is just the gross sales and gross profit the most important two metrics compared with our expenses and we have only four types of expenses salary rent of supplies and other so everything besides the sparkline and the labels that you see is historical data that actually happened but the sparklines and the labels that show you the values are what we assume will happen in November 2009 t because we still haven't had that month so in this case what we are looking at is the best-case scenario we assume that our cells will grow compared to previous period and our expenses will not grow so much as before because if you look at the expenses they have been exploding it's a growing business so expenses grow as well that reflects that our gross profit hasn't been changing a lot although our cells have been growing in the past so I want to be able to compare this best-case scenario to other scenarios that we have created before I have these scenarios hidden in a show and hide container and as you can see best case has been selected and I can see what are the values that we are passing to table from this best-case scenario now I also have a realistic scenario and I can quickly check what happens if I pass the values from growth sales office supplies etcetera that you see on the screen as you can see our profit dropped a little bit and I will the change in the profit is now only 3 percent instead of 9 and then we have a worst case scenario where our cells actually flatten and then our expenses go up and I can check what will happen in that case and our profit gross profit will dramatically decrease with 16 percent so this is how you would use like a single selection to pass multiple parameters to tableau but what if you want to create your own scenario that were not one of the pre-built ones well for that we have another application as well so what you can do now is come up with your own scenario you you may say I want to assume that my cells will grow dramatically and maybe the office supplies or all these expenses will stay more or less constant maybe other expenses will drop because we don't have so much going on in November and I will just assume that everything else is the same finally we want to give a scenario name to this new scenario so that we can differentiate it and I'll just call it TC scenario and how do we pass this through the data so this is how we pass these parameters not within tableau but outside tableau to a database as a right-back functionality I'll just click on this new this button which basically tells me to save TC scenario so when I click that that scenario will be saved to a database in this case we're using Google sheet it's just because it's accessible entry and if I because we are using tableau desktop I basically need to go and refresh the data but if you're on tableau server you just need to click a refresh button and you will immediately see the results so let me show you how we can refresh this data No so this is my form the Google sheet form where I wrote back the data that we talked about and if I come back here and now look at my scenarios again you will see that TC scenario now appears here in the list and you can see exactly what values will be passed I probably didn't click enter for the gross sale that's why it's empty but now I can pass these values and calculate what will be my gross profit in that kicks so how did we do that well basically we used a Google Form to populate all these parameters into by passing the values with a URL action so if you look at this button here it's actually having a URL action in the backend which passes all these values to a Google Form so the URL action looks like this it's just a URL that we got from Internet but if you're using a database that would be a different process but the idea would be the same just passing the values back to the database and if we test the link it will take us to this your election and and you can see that we have operated these values directly to a Google for this Google form itself if you have used Google Forms has its own sheet in the backend where you can see the how the data is being populated so we have this financial planning scenarios sheet and I can see all the scenarios that I have passed using this Google form with their name corresponding names so this is how I created this right-back functionality and finally we use basically a parameter action to pass these values to the corresponding calculations Wednes once a selection is being done in the act of sorry the actions are very similar to what we did before you just need to create the action and then say how to trigger it just by selecting the corresponding corresponding scenario from this list so I think we have a little bit of time just to show one trick which we think is very important okay so what are the things we haven't talked about is actually how you can output of best ways to use to approach these problems so I want to show you a little trick that will make it actually significantly more powerful to use sad actions so I'm actually going to go to one of the one of the one to one of the fields we've done today and one of the things that you will notice is that when you are approaching when you're using a set action to populate the set you will actually bump into tableaus highlighting you trying to be helpful and actually well being helpful and demonstrating what what you have selected but actually set actions are a wonderful way to create your own type of highlighting and sort of bypassing tableaus default I'll show you what I mean the first thing I'm gonna do I'm gonna go to group a and I'll show you this in group a but it will be the same process will pretty much any sad action that you build and the first thing I'm gonna do is I'm gonna create a simple calculation just with an empty string so I'll call this highlight it really doesn't matter all it has to do is something that's exactly the same as a dimension that's exactly the same across all of the data oh I already have a field ballpen levels give you a little bit a star perfect so I'll bring my highlight into detail here and one of the things I'm also gonna do is I'm gonna bring my group a set and I'm gonna bring it into two places so set a little bit differently then parameters you can literally use them anywhere into this so you can actually use them to sort the members so I'm actually I just added it two rows and now I have a sorting of what's in my selection and what's not I'll just hide that and I'm also gonna get the group age follow this you're just gonna change shape a little bit and as you see I've now created a different highlighting where I'm highlighting actually the the selection using color not tableaus default highlighting if I now go into my group my action dashboard and I create a new action in this case a highlight action a simple highlight action from select group a to select a focusing on the field that I've created so this field is just allowing me to make sure that I highlight everything what this now means is that I can when I when I select something two things happening the set of the set make sure that it's sorted by my selection but also the color will change to indicate my selection again various behaviors from one thing and then the highlight action make sure that tableau is default highlighting whilst being helpful doesn't get in the way so there's a little bit of a top trick that you can that you surely should use when you're trying to create your own ways of highlighting what the end user has selected boom so this is what was what we wanted to show you I will just add something about our last question before we move on is that passing values out of tableau can be using right back but that is just one example as well this could be quite useful for things like custom SQL where you actually define parameters of your query based on the selection of the end user so think about what germ or even if you're passing them out to things like Python or R for advanced analytics all these things parameter actions will allow you to do in a very very easy way so finally what did we learn today if there's anything that I would like you to take from this session is this idea that seven parameter actions in the end of the day they allow you to store end user selections in a way that's super visual it's super interactive intuitive for the end user but what you do with it is up to your imagination which is extremely powerful or which means that the now the responsibility on you to build exactly what you want Phil there's a really really large intersection of use cases because of this a nature of you you build the behavior there's a big intercession of use cases but usually one of them will be easier to build or being more performative this as well as quite important when we started working with large volumes of data this workflow is also designed to think about what is more performant to calculate and more performant to render so that's that's what we wanted to show you today there's there will be if you are interested in this topic there will be a few more sessions on this that we recommend by some of our colleagues so you do recommend you attend a secure interested in delving deeper on these use cases and please don't forget to rate this session and give us feedback what you liked what you didn't like what you would like us to improve because this feedback is really important for us to make sure that we improve this session for the next time this session has been delivered for the first time ever and we want to make it even better for the next time and if you have any questions I will be here around for the next 5-10 minutes so we can have a chat just anything that you would like to know more about certain parameter injections thank you very much
Info
Channel: Tableau Software
Views: 4,017
Rating: 5 out of 5
Keywords: Visual data, Visual analytics, Business analysis, Business analytics, Business analysis tool, Data analytics tool, Data Analytics, Analytics, Analytics platform, Cloud application, Business analytics platform, data analysis, data visualization, business dashboards, business intelligence, tableau, tableau software
Id: 8bm2T1oenU0
Channel Id: undefined
Length: 56min 42sec (3402 seconds)
Published: Fri Nov 15 2019
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.