PL-300 – Section 5: Part 1 Level 4: Adding more control to your visualizations Part 3

  1. Slicer Warning

Now, I do have one word of warning regarding slices.

Let’s add a slicer. So, we add a slicer based on the date. I will use my Sync slicers and I will synchronise the matrix page to it as well. I will take this up to 2002. And we can see that the matrix is so affected. I’m now going to delete the slicer. So, you can see this slicer here, so this visualisation 1995 to 2015, 1995 to 2015 or 2016 even, go to the matrix. It starts at 2002. So the slicer which has been deleted is still affecting this matrix visualisation. And you can’t see any photos in the page level photo, the report level photo.

So, really, it is a very dangerous thing to do, to have a slicer which is synchronised and yet is, you then delete. So, if you find yourself in that sort of situation, you can always press on undo several times if you can or you can insert another slicer, which affects the matrix. So, this one should affect, there we go. We’re now hook in 1997 and reset it that way. But just a word of warning before deleting any slices make sure that they are not affecting any other pages or you might find yourself with an unexpected filter that you can’t seem to get rid of.

So how can we get rid of the effects of a slicer that we can’t see. The solution is to see it. And to do that, we go into View and Selection. So, this shows all of the objects, which are on this page. Currently, you can see two of them. However, when I click Selection, there are actually three, we have the matrix. So, that is this which you can see here, photo by days. This is the slicer that we can see. And then we have a further slicer, clicking on that doesn’t actually highlight it because it is invisible. And you can see it’s invisible because we’ve got these little eye icons which when you click on it, you can hide it.

So, what we need to do with this slicer that we can’t see is unhide it. So, click here and now we can see the slicer. We can adjust the slicer so that we now start with 1995 and then we can delete the slicer. So, if you’ve got a slicer that you’ve previously set up, synchronised to more than one page and then deleted the slicer, to be able to see it again to delete it, you need to go to a View, Selection.

  1. Sort Visuals

Now, in this video, we’re going to have a look at sorting visualisations. So we’re going to have a look, first of all, of this table visualisation.

Now, currently, you can see it is being sorted by the region name. In fact, there is a filter on this, which might be helpful if I just click on the eraser and remove. So, it’s been sorted on region name, descending. So, that means anything starting with zed, or Z, is right at the top, and A is right at the bottom. If I was to change the sort order, then I can do so simply by clicking on it. Similarly, if I want to sort by a different column, I can do that by clicking on that column.

Now, if I click on the dot-dot-dot, the more options, which is just outside the visualisation, you’ll see that there is a sort descending, sort ascending, and then a sort by a particular field. So, if you didn’t want to click on any particular column, you can say I want to sort by sales volume descending. If we go to the matrix, where we’ve got the years going down, and go to Manchester and all the regions going across. Again, we can sort. But you can just click on the individual region. That uses a spotlight. So here, you will have to use the more options to sort by the year. Or sort by the sales volume. And you can see, it’s only the overall sales volume that can be sorted. You can’t sort a particular column. There is no sort by the West Yorkshire sales, unfortunately.

Now, what if you wanted to do a bit more of a custom sort? So, for instance, let’s add a new table, and I’m going to show in there the region name, but I’m also going to show the area code name. So, it’s a bit small, so, I’ll just expand it by going to the bottom of the grid, and I’ll expand it to there. Now, you’ll see that the region name is not in an identical order of the area code, but maybe you want it to be. Maybe the area code order is important, and it should go Greater Manchester, Merseyside, South Yorkshire, West Midlands, West Yorkshire, Tyne and Wear. But there doesn’t seem to be a way to just drag, say Merseyside up, or West Yorkshire down, or something.

So, let’s say this was important, and I wanted the region name to be in exactly the same order as the area codes. Well, what I can do is I can click on region name. Now, I’ve had to just click a couple of times for some reason, but eventually, in the modelling section, we have sort by column enabled. So, what this allows us to do is to sort a particular column based on a second column. So, I want region name to be sorted in the same order as area code. So now look what happens. Greater Manchester, West Midlands, West Yorkshire, Merseyside, South Yorkshire, and Tyne and Wear. That’s not the right order. It’s currently not being sorted. You can see the little arrow next to sales volume, and if I click on the dot, dot, dot, bit tricky to do, you’ll see that there are little yellow signs next to sort descending and sales volume. So, that’s telling you what is being sorted. But now, if I sort by region name ascending, you will see that Tyne and Wear is now at the bottom, exactly the same as in the area code. If I sort it by area code, Tyne and Wear will be right at the bottom.

Now, it’s at that sorting, by column, that is not a one-off. That affects all visualisations on all pages which use this particular data source. So, use that with some care. A good example of this is, suppose you had a column which had the month name, January, February, March, April. If you tried sorting that in order, you would get April first, and then August, in alphabetical order. Instead, you can say, I want sort that in association with the month number. We’ll show you how to do that much later when we get into modelling. Now, let’s all look at the sorting for this graph. So, I click on the dot-dot-dot (…) next to it, and, oh, absolutely no sorting. So, why is that? Well, I’ll just enter focus mode. And the reason for that is because this X category is being sorted continuously. It’s being shown continuously. So, it’s going from 1994, which is blank, all the way to 2016, and the consequence of that is that there really is no sensible way to override that sorting.

However, if we change this from a type continuous, to a type categorical, so taking each of these years as a separate category, in the same sense car, lorry, van would be different, and now, we can sort by a particular thing. So, we can sort by year ascending, year descending, as is here, or we can sort by something else, sort by sales volume. So, you can see 2006 is the highest sales volume, and then 2003, 2004, all the way down to 2009. So, if you want to be able to sort the X-axis of a chart to be something different, then you better change the X-axis from continuous, which is its own sort and can’t really be overwritten, to categorical. So, if I change that back to continuous, you can see we have lost the sorting. Change it to continuous, and we’ve got it back again.

So, that is sorting. Sorting allows us to present information with the most important at the top, maybe. It needn’t be by the first column. It could be by sales volume. It needn’t be in alphabetical order. It could be based on another column like area code. And you can also change the X-axis of charts to be based onto categories, and then, you can sort the charts in a non-continuous format.

Now, I’m just going to change all of that back because I think would prefer to have that as continuous. And I’m also going to change the region name so that it is sorted by region name, which is the default again. But it’s nice to know that you can change it as and when you need it.

  1. Configure Small Multiples

Now, here’s a question. How can we have six versions of this chart, one for each of these regions? Well, what I could do is I could copy this into a new page. So, I’ll just do that. Remove the legend, and add a filter just for this particular visual for region name. So, drag that in and say region name is equal to Greater Manchester. So, I can do that and then resize it a bit, and drag it up maybe. And then I’ll copy that, so I’ve got a second version. And I’ll change the filter so that it’s Merseyside, or Tyne and Wear, or something like that.

Now, I just want you to have a look at what I’ve got. So, I’ll just blow it back up. We have got one Greater Manchester here with the access going from zero all the way to 60,000. And then we’ve got Tyne and Wear with the access going from zero to 20. Now, if you didn’t look at those axis, they would look like they were very similar. So, I’ve got the high here, 61K, I’ve got a high here, it looks even taller, but it isn’t, it’s only 25,000. So, that is one way of being able to show multiple regions in different charts.

But let me show you a much simpler way. So we’re going to get rid of this filter on this visualisation. So, now it’s back to everybody and I’m going to blow it back up full screen. And the way that we can do this, and this is only for bar, column, line, and area charts, is to create something called a small multiple. It’s got a more technical name of trestling.

So, what I can do with a small multiple, if I scroll down, is say, okay, this chart is great as it is, but I want it to concentrate on one particular thing. And this thing I’m going to have it concentrating on is region name. So, notice what happens when I drag region name into small multiples. So, now we have got the same chart for Greater Manchester, Merseyside, South Yorkshire, Tyne and Wear. And then, if I scroll down, we’ve got West Midlands and West Yorkshire. Now, notice something else. They are all on the same axis, all on the same scale. So, Greater Manchester, we’ve got a scale of zero to 60,000. Tyne and Wear, we still have zero to 60,000. But now these bars look a lot smaller because it used to be, it was on a scale of zero to 20,000.

Now, suppose, you want to say okay, that’s great, let’s put these in alphabetical order, Greater Manchester, Merseyside, South Yorkshire. What I want to see are the biggest things at the top. So Greater Manchester, followed by either West Yorkshire or West Midlands. Well, in the previous video, we had a look at how to sort. And all I do was click on the dot-dot-dot (…), and it says sort by. However, if you’ve got a small multiple, it doesn’t say sort by, it says sort small multiples. So, I’m not actually sorting the graph itself. In other words, it’s still going to go from 1995 to 2015. What I’m sorting is their presentation, the way that they are arranged. So, I want to sort the small multiples, not by region name, which is what we’ve currently got, but by sales volume. So, this will be the sum of the sales volume

And I can say I want it sorting ascending. So, here we’ve got Tyne and Wear at the top, then South Yorkshire. Or I can say sort descending. So, we’ve got Greater Manchester at the top, then West Midlands.

Now, I want you to note the axis. So, we only have one set of axis on the left and one set of axis going across. The fact that it starts from zero to 60,000 twice, means that they’re currently each graph or each chart, but there’s not one in the middle. Similarly, the years, 1995 to 2015, goes to 2016 but we don’t see that. Happens twice. And if I scroll down, you can see that they stay in place. So they don’t get attached to how it looks like the bottom visual I can see, it just gets attached to the bottom of the visualisation.

So, that is small multiples. It’s having multiple versions of the same chart, same visualisation. As I say, bar chart, column chart, line charts, and area charts. But each one of these small charts focuses on a different, in this case, region name.

Now let’s have a look at the formatting. So, if I go into format, we have got two items up here. First of all, small multiples. So, we can change the font family, the text size, all of this is to do with the headers. So, I can have the header in red, centre aligned. And, this is quite important, the position. Because, for me, West Yorkshire looks like it might be this one. Generally, I would have them at the bottom. So, West Yorkshire is no contest, really has to be this particular chart. So we’ve got small multiples, that refers to the header, and then we’ve got grid layout. So, at the moment I have got a grid of two rows by two columns. So, because I’ve got six items, it’s very easy to have six on the screen without any scrolling. So, I can either have three rows and two columns, or two rows and three columns. So, I’m going to stick, at the moment, with the three rows. We can also change the background colour, change the transparency, we can add grid lines. So, either vertical, horizontal grid lines, or all grid lines, or borders and grid lines. That’s a bit too in your face, I think.

o, what I’m going to do is I’m going to change it so it’s a light colour, maybe a bit thicker, so you can have really thick ones if you want. But I’m going to change the line style so that it is, well, dashed? Or dotted? I think dotted might look better. The grid padding, that is how much white space you want, so you might not want any white space between the grid lines, or you might want a lot. And if it needs tweaking, if it needs adjusting, the left from the top, or the right from the bottom, then you can use the advanced padding options. And so you can see you have got inner and outer column, and inner and outer row padding, if you need to refine it that much.

Now, just one more thing. How did these interact with other visualisations? And the answer is quite well. So let’s create another visualisation. I’ve just copied and pasted that. So, I’ll just move that to one side. And so, this isn’t going to have any small multiples. Instead, it’s going to be a stacked column chart with the date running across and with region name as the legend. So, if I click on any one of these items, you can see that the appropriate bar gets selected here as well. And vice versa. So, if I clicked on one particular one, here you can see West Midlands, 50,000. I can also click on a title. So, Greater Manchester would highlight all of the Greater Manchester’s.

Similarly, I could click on a region name up here in the legend, and if this access was not continuous, but categorical, then I could click on any one particular year and I can see that year being highlighted here as well.

So, this is small multiples. So, they allow you to have smaller versions of one particular visualisation, but each of them is going to be filtered or partitioned, or have the focus on a particular different aspect of, in this case, region name. And then you can have a look at the small multiples and the grid layout formatting. So, that is small multiples.

img