navigate site menu

Start learning with our library of video tutorials taught by experts. Get started

Managing and Analyzing Data in Excel
John Hersey

Managing and Analyzing Data in Excel

with Dennis Taylor

 


In this course, Dennis Taylor shares easy-to-use database commands and methods for maintaining an Excel database. The course covers sorting, adding subtotals, auto-filtering, and using the Excel Advanced Filter feature and specialized database functions.
Topics include:
  • Multiple key sorting
  • Single and multiple column numeric filters
  • Creating a top-ten list with values or percentages
  • Setting up subtotals
  • Creating multiple-field criteria filters
  • Creating unique lists from repeating field data
  • Using the Remove Duplicates command
  • Finding duplicate data with specialized arrays
  • Counting the number of unique items in a list
  • Using SUMIF and COUNTIF functions
  • Working with the database functions such as DSUM and DMAX

show more

author
Dennis Taylor
subject
Business, Data Analysis
software
Excel 2007, 2010
level
Appropriate for all
duration
1h 32m
released
Oct 27, 2011

Share this course

Ready to join? get started


Keep up with news, tips, and latest courses.

submit Course details submit clicked more info

Please wait...

Search the closed captioning text for this course by entering the keyword you’d like to search, or browse the closed captioning text by selecting the chapter name below and choosing the video title you’d like to review.



Introduction
Welcome
00:04Hi! I'm Dennis Taylor and I'm pleased to present Managing and Analyzing Data in Excel.
00:09When you work with large lists and database-like structures, you need tools to
00:13manage your data and get the most information out of it.
00:16Excel has a variety of features specifically designed for these purposes and we
00:21will cover them in detail in this course.
00:23We'll start by showing you a variety of ways to use the most important data
00:27management tool, sorting, and then show you how to automatically insert
00:31subtotals into sorted lists.
00:33We will also show you how you can see just the data you need using filtering,
00:39how to identify and delete duplicate data, and how to gather valuable
00:42statistical information via the SUMIF family of functions and the database
00:47statistical functions.
00:49So let's get started with Managing and Analyzing Data in Excel.
Collapse this transcript
Using the exercise files
00:00If you're a Premium member of the lynda.com Online Training Library, or if
00:06you're watching this tutorial on a DVD -ROM, you have access to the exercise
00:10files used throughout this course.
00:13As you open a file, as I am now, you will see that there are a number of sheet tabs.
00:20Many of these will be referred to in the training.
00:23Here and there you will see a tab that is not used at all.
00:26If you're a monthly subscriber or annual subscriber to lynda.com, you don't have
00:31access to the exercise files.
00:33But you can follow along from scratch with your own files.
00:36Let's get started!
Collapse this transcript
1. Sorting Data
Sorting from the Sort menu
00:01Whenever you work with large amounts of data, whether it's an HR list like we see
00:05here on the sheet or on the next sheet, scientific type data, the need to sort
00:10the data, rearrange the order of the rows, is a common need.
00:14And let's say that sorting is something that is probably the key action that we
00:19take to manage our data.
00:21We need to see at them this particular order.
00:23Often we'll print this.
00:25Before actually working with data, a couple of quick tips here.
00:29Let's imagine you have never seen this worksheet or maybe you've only seen it once or twice.
00:34You forget how big it is.
00:35It's something you'd want to know.
00:37Get in a habit of pressing Ctrl+End.
00:39This is not a perfect keystroke shortcut, but many times it gives you that quick read.
00:44Notice that the active cell has moved to cell O742.
00:48What can we say about that?
00:50In this particular worksheet, remember we just pressed Ctrl+End, we can be sure
00:54there is no data anywhere below row 742 nor is there any data to the right of
01:00column O. Press Ctrl+Home to go back to the upper left-hand corner.
01:04Before doing sorting or filtering or using some of the other database management tools,
01:09it's a good idea also to make sure that your data is in one solid
01:14cluster, meaning that we don't have any empty rows in the data.
01:18Do we want to go scrolling through this?
01:20What if it's 7,000 rows?
01:22What if it's 700,000 rows?
01:24So another quick tip here is with the active cell anywhere in your data,
01:29press Ctrl+A. Now if this were small amount, we'd probably see the edges of all of this data.
01:35We might even be able to zoom backward with the Ctrl key and the mouse wheel.
01:39But we've got over 700 rows here.
01:41You saw that earlier.
01:42So how do we know if there are any empty rows in here?
01:46Take the unlikely step of pressing Ctrl+Period a few times.
01:50As I'm doing here. The active cell is now an O1.
01:54Ctrl+Period simply moves the active cell around my corners.
01:57So whether you believe that or not, it does prove that there are no empty
02:00rows within the data.
02:02And that's the key idea, because any time we want to do sorting and
02:06filtering and use other database management tools, instead of having to
02:10constantly highlight all of our data, we need to only click within our data on a single cell.
02:16And if we only do sorting occasionally, it's always best to go to the Data tab
02:22and use the actual Data > Sort command.
02:25And even if you do sorting a lot, this is the place to go to for some of the
02:29many options that are now available in sorting.
02:32We will talk in later movies about the AZ and the ZA buttons and some other
02:36issues, but this is, you might say, ground zero for sorting.
02:41So we'll click the Sort button.
02:43Again, it's on the Data tab, and although we can sort in a variety of different
02:47ways, first time around let's just simply look at what we have here.
02:51Sorting for about 95% of the people most of the time means rearrange the order of the rows.
02:59And the first step in here is to choose the field that we want to sort on.
03:02Let's imagine in this particular example that we would like to rearrange all this
03:06data in alphabetical order by department.
03:09Here is a list of the fields. They match up with what we see in row 1. There's
03:16department, let's click it.
03:17Notice that Sort On says Values, that's its default setting, but you will see,
03:23you can sort by Cell Color, Font Color, Cell Icon.
03:27The order often will automatically be A to Z. Now possibly it wasn't here
03:32because the last sorting that was done might've been in reverse order.
03:36But with text fields, A to Z is by far the most common choice.
03:40In other words, alphabetically.
03:41And even though there are other options, we will ignore those right now.
03:45Let's just click OK and almost instantly we see that the list has been
03:50rearranged by department.
03:53Now there are certainly other ways to sort that are faster and we talked as
03:57we did this too, but that's where we want to go, this actual Sort command that's on the Data tab.
04:02If you use this feature a lot, you might consider right-clicking and add this to
04:07the Quick Access Toolbar.
04:09And so the next time you sort, perhaps you have been using or had been using the
04:14Home tab, you want to start the sorting again,
04:17there is the button right there. You don't have to go over to the Data tab.
04:20And of course, that's a tip you can use with other features as well in Excel.
04:24So using the Sort command, generally straightforward and fast. I'm using it
04:29from the menu, the actual Sort command. The best way, the most reliable way to
04:34use sorting in Excel.
Collapse this transcript
Sorting from the toolbar
00:01As you become more comfortable with sorting, there are many times when you want
00:04to sort your data quickly and easily.
00:07And if your data is all together here, no empty rows within this data, if
00:11you'd like to rearrange the entire list by Employee Name, click on a single
00:15cell in column A. It can be cell A1 or any of the others. Do not click the
00:20column letter itself.
00:22Unfortunately, it's pretty difficult to rearrange only the data in column A.
00:26That was a major shortcoming of some older versions of Excel.
00:30So, click on a single cell. Imagine that we would like to rearrange this entire
00:35list, some 740 names, alphabetically by name.
00:39Go to the Data tab. We probably want this alphabetical.
00:42There's an AZ button.
00:44Click it, the deed is done.
00:46And furthermore what if after printing this or reviewing it or sending it onto
00:51others, we now change our minds because we want to see the list in alphabetical
00:55order by department?
00:56We'll click in column C, click the AZ button, and recognize that the order
01:02is now by department.
01:03But almost as important as that recognition is that if you're looking at
01:07records within a single department, for example, this ADC department, recognize
01:12that the order of those records there is based on the sort that we had just done previously.
01:18In other words, they're in order by employee name and you can see that even more
01:22clearly perhaps in the Admin Training group right here.
01:25So those names are in alphabetical order because that was the sort that we had
01:28done just previously to sorting by department.
01:33And let's try this a third time.
01:34I'm going to sort based on the data in column F, the Status.
01:39Click in column F, I'll click AZ again, ascending order, and now we have all the
01:44Contract people together.
01:46And how are those Contract people grouped? And they're quite a few of them, close
01:50to 200 or so. They are in alphabetical order by department.
01:54And for any given department, say Logistics right here, here are all
01:58the Contract people.
02:00What order are they in, the order of the sort that preceded the department's sort.
02:05So you can think of using these buttons in kind of a cumulative way.
02:10The last order or the last column you chose to sort on overrides the others.
02:16Now if someone says I'd like to see a list of everybody by department based
02:20on their salaries descending, if Department is the major grouping here and
02:26Salary is secondary, we'll go to the Salary column, column K. This time click
02:31ZA, descending order. There we go!
02:34And for the moment, that's our list of all salaries in the entire organization
02:39here, descending order by salary.
02:42Let's now click somewhere in column C, we'll click AZ, and within any given
02:48department, once again, here are the Admin Training people.
02:51You see the order that those records are in.
02:53It's in descending order by the salaries in column K. And if you haven't done
02:58sorting by date, you'll quickly learn and see how that works.
03:02If we click in column G and do an AZ sort, the dates are in ascending order from
03:08the oldest to the newest.
03:10The first person hired in this organization, July 17th, 1990.
03:13I'm going to reverse the order.
03:16descending order puts the latest dates at the top.
03:19Remember that all rows are being sorted here, so the information in one row is
03:24going to be shuffled around. As we now see, our most recent hire is listed on top.
03:28So you quickly get the hang of how that works.
03:32So as you become more comfortable with sorting, using the ZA and AZ buttons, they are
03:37fast and easy, remember that they are cumulative in nature.
03:41And here too, if you start to use sorting a lot, why not right-click on each one
03:46of these, add it to your Quick Access Toolbar?
03:49Over time you may decide to take it off in the same way.
03:51Simply right-click on it, if you don't use it that often.
03:54So you can easily make those adjustments as well.
03:57So, sorting, fast and easy with the Sort buttons in the Data tab.
Collapse this transcript
Multi-key sorting
00:01Using the Sort command, you can sort on multiple columns at the same time and
00:05Excel has expanded this capability substantially in versions 2007 and in 2010.
00:11As we look at this data, it may be important to you to see the data in
00:15order possibly by department, but in some of these departments, we have over 100 people.
00:20And so we'd like to be able to look at that portion of the list and see it in
00:24order perhaps by Status, maybe by Employee Name, maybe by Salary, or maybe a
00:29combination of those.
00:31If your needs are to sort on more than one column and if you have not used the
00:35Sort buttons, which have their limitations and yet could work if you are only
00:40thinking about two columns or possibly three, go to the Sort command.
00:44Now, once again, click on a single cell within the data. Go to the Sort command
00:49button on the Data tab.
00:52Let's imagine that our major grouping that we're looking for here, in other
00:56words the very first column, the dominant sorting arrangement here, is to be by department.
01:02As we suggested because in some departments there are many, many people, and we
01:06would want that to be alphabetical, make it be A to Z. Let's add another level
01:11and this, we want to put in by Status.
01:13Half Time, Full Time, etcetera. Add another level.
01:17We want those people perhaps to be in order by their salaries, and maybe we want
01:23to see the highest salaries first.
01:25So we'll choose Largest to Smallest.
01:27Now, it's possible that we still might have within certain organizations here
01:31because there are a lot of people, a lot of people with the same salary.
01:35So let's add a fourth level.
01:37Now it's important to note here too that in all versions prior to Excel 2007,
01:42you could only sort on three fields at once. We're about to use a fourth right
01:47here and it will be the Employee Name.
01:49And it's unlike that they will have people with the same name within the organization.
01:53It's certainly possible but we don't need another level here, although certainly
01:56with other kinds of data here and there you will, and the response to a lot of
02:00complaints about being only able to sort on three fields at once, this limit has
02:06now been raised to believe it or not 64 levels.
02:09Here we're using four levels:
02:11Department, Status, Salary, Employee Name.
02:15Click OK, there we are!
02:16And there are all the people in the same department and here are all the people
02:21who are full-time within this department. And how are they ordered?
02:24They are in descending order by the salaries.
02:26It looks like no two salaries there are alike, so the fourth order, by Name,
02:32really doesn't have a role to play here, although it certainly could in some situations.
02:37So being able to sort on multiple fields is probably best handled by way of the Sort command.
02:42If you're pretty adept with the AZ and ZA buttons, you could have achieve the
02:46same objective, although it probably would have taken longer. In those cases,
02:49you probably refer to the previous movie to see how that's done.
02:52So multiple key sorting, big expansion in terms of capability in Excel 2007 and in Excel 2010.
03:00Best way to do that is to use the Sort command as we just saw.
Collapse this transcript
Sorting based on the order of data in custom lists
00:01Sometimes you need to sort data based not on alphabetical or numerical order,
00:06but on the order of data as it appears in a list.
00:09And it could be one of Excel's built-in lists or it could be a list that you've created.
00:14As we look at this particular worksheet, we might want to sort the data based on
00:18the information in column H. Column H contains formulas.
00:22Take a look at cell H2.
00:24So I double-click it.
00:26It looks like it's a rather complex formula but that's actually pretty easy.
00:29It simply pulls out the month of each of these Hire Dates.
00:33And perhaps what we're aiming for here is a list that's sorted alphabetically by
00:37month so we can just know when someone is having an anniversary month we want
00:40to print that data out.
00:42So we'd like to sort based on the data in column H, and if we're in a hurry we
00:47can certainly use the AZ button as we see it on the Data tab here.
00:51It's going to sort the data based on the data in column H. And there we are
00:55and April comes first.
00:56But wait a minute here!
00:57Aren't we thinking, shouldn't January be first?
01:00Well, no, this is an alphabetic sort.
01:03We see April, then we see August, then December. We didn't do anything special
01:08to indicate to Excel that there is anything unusual here, but we do have at our
01:12fingertips a way to sort this data chronologically.
01:16We must use the Sort command.
01:17It's on the Data tab just to the right of the AZ, ZA buttons.
01:21Let's click this again.
01:22We do want to sort by Month, we want to sort on Values, but not that A to Z
01:27order, because built into Excel is a custom list and we do see the months
01:35abbreviated and full spellings.
01:36We have full spellings here.
01:38This is the one we'll use.
01:39We want to sort chronologically, not alphabetically, and by making this choice
01:44and clicking OK, that's exactly what happens. Easy and fast.
01:49So anytime you need to sort on a column that's got monthly names, either
01:53abbreviations or full spellings or possibly day of the week, you probably want
01:57to chronological sort in both cases.
01:59That's what we've done here with these custom lists.
02:02Now, there are other situations too where you might need to sort in a particular order.
02:07I'm going to sort this data based on what we see in column F. A quick AZ sort
02:12again from the Ribbon on the Data tab and the Contract people come first.
02:17Remember, there are also, as you see this here on the screen, Full
02:21Time, Half-Time, Hourly.
02:24Well, I think a lot of us will want to say, well, let's put the full time people first.
02:28They run the company and I want to see them first here.
02:31If we did a reverse sort, ZA, that's not going to help either.
02:35We'd like to sort in a particular order.
02:38On another sheet, and you don't necessarily have to have the data be displayed here,
02:42I've got the actual statuses listed here in the order that I would like
02:46to have them appear.
02:47I'm thinking ahead too that I might need this in the future.
02:50So what I'm about to do is to take this data and make it be an entry in a
02:55custom list along with the days of the week and the months of the year that
02:59we've already seen.
03:00So with this data highlighted and you don't really have to do it this way and
03:03you might be prepared to type this yourself. And if you're using Excel 2010,
03:08click the File tab in the ribbon and then choose Options.
03:12If you're using Excel 2007, click the Office button, and then click Excel
03:16Options, and in 2007 you'll see a choice right about here on the screen that
03:21indicates Custom Lists.
03:232010, we need to go to the Advanced tab and scroll way down to the bottom of
03:28this and you'll see this box, Edit Custom Lists.
03:32Let's click it and here are those built-in lists that we saw earlier.
03:37Let's now add by importing the data that we've highlighted.
03:42If you didn't have those items on a worksheet like we have here, you would type
03:47them right here where it says List Entries.
03:49In other words, type Full Time, press Enter, Half-Time, and Enter and so on.
03:53Now we can just import them.
03:55Now, this list will stay here indefinitely.
03:58I'm going to click OK.
04:00If the next exit that I do from Excel is a normal one, we won't worry about it.
04:04That list is around forever.
04:06What it means is when we want to sort data in a particular way, like here, we
04:11will use the Sort command.
04:13We do want to sort by Status, we want to sort by Values, but not that A to Z order.
04:19Click the drop-arrow, go to Custom List, and that latest entry in our Custom
04:23Lists, the one we put in, Full- Time, Half-Time, Hourly, Contract.
04:28That's the order I want.
04:30Click OK, click OK, and the full-time people come first.
04:35So whenever necessary, you can override standard sorting order by creating a
04:39custom list or referring to one of the built-in custom lists in Excel.
Collapse this transcript
Sorting by color font, color background, or icon
00:00A new feature in Excel 2007 is the ability to sort data on the basis of cell
00:06color or font color or even cell icon.
00:10In this particular worksheet, as I start to scroll down, we would recognize
00:14there is a pink row in Row 16.
00:15There is 21 and 26 have green, green color, so does Row 37.
00:20Perhaps there are some colors there too.
00:22And the colors might have been put in there for a variety of reasons, but we do
00:26want to rearrange our data.
00:27We want to sort the rows here by putting the colors together.
00:31Maybe we want all the greens to be at the top of the list.
00:33You also notice in this worksheet as I scroll to the right that in Column J
00:39there are icons placed here based on the salary.
00:42Now if we wanted all the green arrows together, we could easily sort by the
00:46values themselves, but also what we could do here is not be
00:52showing the actual salary number. In other words, just the icon.
00:55So at different times, you might want to sort by icon as well.
00:59So let's tackle first the issue of sorting by color, color background here.
01:04The active cell can be anywhere in our list and we need to go to the Data tab
01:08and use the Sort command and we could pick practically any field here because
01:14the color extends across all the cells in columns A through K. Let me just use
01:18Department, there we go.
01:20Sort on Cell Color.
01:22Now that does mean cell background, and the first color we want, let's say the green.
01:28Put all the green rows first.
01:30We need to Add Level, two more at least.
01:35We do these all at once or one by one.
01:37Use Department there, Department there.
01:39Cell Color and for the second cell color, even though we didn't see, let's
01:46put the yellows next, and third cell color, the pinks. All the others will fall behind that.
01:51So we're going to greens, yellows and pinks at the top of our list as we
01:55sort, and there they are.
01:58Now at a different time whether we had sorted or not is not the issue.
02:02Let's take a look at the data in Column J and I did hold out the possibility that
02:06sometimes you might not want to show the salaries. Maybe someone needs to
02:10display a list like this or a portion of it, and only give a rough estimate of
02:15where the salary falls into place.
02:17Is it in one of four quartiles?
02:19So the green arrows are in the top quartile.
02:22So let's change the display here using conditional formatting, clicking Column
02:26J, going to the Home tab in the Ribbon, and then under Conditional Formatting,
02:31under Icon Sets here, I guess we could've divided this into thirds or into fifths,
02:36but let's Manage the Rules as it's called and make a change to this rule.
02:41Edit the rule and show the Icon Only, and now the idea of sorting by icon make sense.
02:49We want all the greens to be on top.
02:51So we want to sort this list by Salary.
02:55Once again, back to the Data tab, the Sort command and Salary and we've
03:01four arrows, but we need only sort on three. The leftovers will fall into
03:05place automatically.
03:06So three Salary sorts. The dominant one is the first one and we're sorting by
03:11Cell Icon in each of these cases here.
03:16But we want the greens to appear first. Those are the highest salaries.
03:20We noticed two kinds of yellows, those that point upward. We want that one first.
03:24Then this one, these are in the third quartile, and the red arrow is the fourth quartile.
03:28They will fall automatically at the bottom.
03:30So as we click OK, we've sorted the list this way.
03:33So without necessarily knowing what these salaries are, we only know that the
03:37green salaries are in the top quartile.
03:40So as we view this list now and we haven't sorted it by name too, we could have
03:44possibly included that, but all the people in the top quartile are first.
03:49We sorted by Cell Icon and prior to that in this movie we sorted by color.
03:53New features available starting in Excel 2007.
Collapse this transcript
Sorting columns
00:01Although not frequently needed, you can sort by rearranging the left or right
00:05order of columns, instead of the much more common rearranging of rows from top to bottom.
00:11As we look at this worksheet here, I think you could begin to see what we're headed for.
00:16We might want to rearrange this data in such a way that our cities are
00:20alphabetized from left to right.
00:22Now, unlike the shortcuts we have seen with prior examples of sorting, we must
00:27highlight all of the data in question here.
00:29What we're about to do as I zoom back here is to select this data specifically.
00:36This is what we want to rearrange.
00:38We do not want to touch the data in column A at all.
00:41We simply want to rearrange the column data as we see it.
00:45We want Albuquerque to be on the left- hand side, then Atlanta and so on.
00:48We want these alphabetized.
00:50So we must specifically highlight all the data and we must use the Sort
00:55command on the Data tab.
00:58What's different here?
01:00The Options allow us to sort in the unusual sort left to right, not top to bottom.
01:07What do we want to sort on, based on what, what are we seeing?
01:11It's the data in Row 3.
01:12Now, notice there are options now since we made the choice to sort left to right.
01:18in the Sort by options we're not going to be seeing field names; we're going to
01:21be seeing row numbers.
01:23We want to sort based on what we see in Row 3.
01:26Of course the big concern right away is thinking of how this might look.
01:30Are the numbers below this going to travel with it?
01:32Well, yes, they will.
01:34Keep an eye on Albuquerque then. Number right below that is all 2, so
01:38that's easy to remember.
01:39So as I click OK here, we will be rearranging the data as we see the data in
01:44columns B through M. We expect to see Albuquerque over there in column B and
01:48all of its data with it, and then Atlanta and probably Boston, and so on. Click OK, there we go!
01:55And that rearranged the order of the columns left to right.
01:58So as we've seen here the rearranging of the columns here is pretty fast
02:02and straightforward.
02:03You do have to highlight all of the data, but when the need arises, sorting by
02:07rearranging the columns is an easy task.
Collapse this transcript
Sorting data in random order
00:01You may have the occasional need to rearrange data randomly.
00:04That is, sort this list in a random order.
00:07Now, why might you want to do something like that?
00:09Maybe you want to review the accuracy of your record keeping and you'd like to
00:13extract from here, copy from here, 8 or 10 records, paste them somewhere else,
00:18and review the data at hand.
00:20And rather than just doing it in a freeform way, let's actually rearrange this
00:24data in a random order.
00:26I think you could also imagine this on a sales environment. You're trying to
00:29analyze orders, inventory, processing, shipments, those kinds of things.
00:34Maybe you don't have a formal Quality Control department, but you just want to
00:38pick random records at times.
00:40Let's randomize this list.
00:42Now, we can either add a new column over to left of column A, or possibly off
00:46to the right here. Maybe we haven't put in the new salaries.
00:49If we did, we'd create a new set of data in column N, but we'll just use this right here.
00:53What we're about to do is to simply use a function that perhaps a lot of you have not used.
00:58It's a mathematical function, =rand, and its sole purpose-- and you need to only
01:03type =rand( and then Enter.
01:05Its sole purpose is to put in a random number between 0 and 1. And to fill in
01:12this particular function throughout the depth of the data here, simply
01:16double-click the lower right-hand corner.
01:18So here are a series of random numbers and this function has an unusual
01:22characteristic about it too, is if we manipulate data elsewhere or make a change
01:27in other parts of the worksheet, all of these numbers get regenerated.
01:31But our purpose to put it in here is simply to use this data as a basis for sorting.
01:37So we'll simply click on one of the cells in Column M and click AZ.
01:41Now, although we won't see what's actually about to happen here, we will
01:46rearrange the data based on these numbers, but in the process the numbers were all changed.
01:51So it's like destroying our paper trail. I am going to click AZ and scrolling
01:56left towards here, I think you can see this data is in no discernible order
02:00whatsoever, certainly not in order by Employee Name or Department or Building
02:04and or any other field that you look at.
02:06This has been randomized.
02:08It's in no particular order.
02:09And meanwhile, those random numbers got regenerated, and changed.
02:13We don't need them anymore.
02:15We can either delete the whole column or if we want to leave the label there.
02:18Just click here. We could double- click to copy down the column again and
02:21simply press Delete.
02:23But the main idea is we've randomized the list and now perhaps we'll copy the
02:28first 10 or 15 elsewhere.
02:30Review the accuracy of our data.
02:31That was the whole purpose.
02:33So using the rand function temporarily in a list for sorting purposes is
02:38something you'll need occasionally and it's easy to set up as you just saw.
Collapse this transcript
2. Filtering Data
Using single- and multiple-column text filtering
00:01When you have a list of data, large or small, there certainly are going to be
00:04times when you say to yourself, "I don't want to see all of this data; I just
00:09want to see certain portions of it."
00:11For example, in this list here, maybe you just want to view the people that
00:13are in the Quality Control department or maybe you want to focus on the
00:17manufacturing people, or maybe there are two or three departments whose names you'd like to see.
00:22Along with simple filtering, we also can include different columns in play.
00:28We maybe only want to focus on the full-time people.
00:31Now possibly, you might have converted data into a table.
00:34I have taken a copy of this data and displayed it as a table.
00:38It's in the worksheet to the right called Employees-Table.
00:41If you have used this feature, and more and more people are starting to use
00:45this because they like the easy color applications you can use and other
00:49features, it automatically applies or gives you filter arrows as we see here.
00:53I'm going to be using filtering on another table, the one we first saw, to start
00:58the process from the beginning.
00:59But everything we do with a filter there, certainly can be done in a table
01:03like this as we'll see as we go back to Employees Sheet.
01:07The data doesn't have to be in any particular order.
01:10We do want to make sure or let's say that we have made sure in this case, there
01:13are no empty rows within the data and as I scroll to the right here, no empty
01:17columns within columns A through L. So we want some control over this to see
01:22just the data we want.
01:24The active cell can be anywhere.
01:26Go to the Data tab, click the Filter button, and immediately we see
01:31drop rrows for every field.
01:33Let's focus on department.
01:34Click the drop arrow here.
01:36If it's only one department we need to see here or want to see at any given
01:40time, first step unselect all of these.
01:43Now if you have worked with this feature in the past, you'll notice this is a
01:47huge improvement introduced in Excel 2007.
01:50In prior versions trying to see more than two departments was not
01:55easily handled. Now it is.
01:57We might want to focus on just those people in training type departments.
02:01here's Admin Training, here's Executive Education. We have another one down
02:05here, Professional Training Group. Maybe there are some more, but there's three
02:09of them. Let's click OK and we are only seeing people in these departments.
02:14Now, notice two big visual changes on the screen.
02:17The row numbers are blue, and of course they're not all there because not
02:22everybody is in one of these three departments.
02:24Also, in the lower left-hand corner it tells us that there were 52 of the 741
02:30records that meet these criteria.
02:33It's either Admin Training, Executive Education, or Professional Training Group.
02:37Notice also, the filter arrows that we see on the other columns are still there,
02:42but the filter arrow for this particular column now actually has a filter icon
02:47right there to remind us that this particular column is at play in filtering.
02:53And we can certainly apply filters to other columns at the same time.
02:57Let's suppose that now we also want to narrow the list by choosing just the
03:02full-time people in these departments.
03:04So the arrow for Status, let's unselect them all and choose Full Time. Click OK.
03:10And instead of 52 records, we're now seeing, as we look in the lower left-hand
03:14corner, 29 records and we might want to narrow it even further by just focusing
03:20on the top performers, those whose Job Rating-- and let's click the arrow for that.
03:25Unselect them all. Job Ratings 4 and 5, the two top in our categories here.
03:30Click OK and instead of 29 records, we're now seeing 16.
03:35We might want to print this data. Before doing so,
03:38maybe it would make sense to sort.
03:40You can use regular sorting tools, if you're familiar with the AZ and the ZA
03:44buttons. You can certainly do that.
03:46But if we click the drop-arrow for department, notice here's Sorting here too.
03:50Perhaps it's a little more pertinent.
03:52What we're about to do here is sort this perhaps for printing or just visual reasons.
03:56Only the data in the visible rows is going to be sorted as we click this option.
04:02You saw how we used different fields here.
04:04If we change our minds again, we might go in two different directions.
04:07One might be that we want to hold on to some of our filtering criteria and get rid of others.
04:12So if that's the case, we possibly would go back for example to Status and
04:16select them all, so that's no longer a criterion.
04:20But if we want to get rid of all the filters, we've two other options as well.
04:24If we'd like to keep the filter arrows here, we can simply click the Clear
04:29button and that will bring back all of the data while keeping the filter arrows in place.
04:35You can see how that looks.
04:36I am going to press Ctrl+Z to undo, to go back.
04:40Suppose we like to get rid of all filtering for the moment, including the filter
04:44arrows, then we'll just click the Filter button. All the data will be returned
04:49and the filter arrows are gone.
04:51So it's a very easy for the most part feature to use, and in its simplest
04:55form as we saw it here on a single column or even expanding it into multiple columns,
05:00it's a great tool for paring down the data so you can focus on just what's
05:05important to you at the moment.
Collapse this transcript
Taking a look at special numeric filters
00:01When you work with Excel's filtering capability, you should be aware of the fact
00:04that Excel does recognize the kind of field data you are working with.
00:09Let's suppose that in this particular worksheet we want to Fflter and maybe we
00:13want to filter by Date or Status. Sometimes we're not even sure.
00:16Let's apply the Filter.
00:18If we click the arrow for Status, we do see that Excel recognizes that as a text
00:23field and gives us somefilter possibilities.
00:27If we were interested in looking at Column G and applying a filter, that's a Date
00:32column, we see Date filters, a totally different kind of list there.
00:38But let's suppose we're interested in the Salary column, Number filters, and we
00:43see some choices here and this is an expansion on prior capability in Excel.
00:48We simply want to find, for example, those records where people's salaries are
00:52within a certain range.
00:54So we'll choose Between.
00:56We don't have to worry about setting up the logic here.
00:58It's all done for us.
01:00We're interested, for example, in seeing all those records where the salaries
01:04are between 60,000 and 70,000. Click OK.
01:09And there they are.
01:10We could sort those Descending, Ascending, as necessary.
01:14If on the other hand we say let's find all of those salaries above average.
01:19Once again, something new, easy to get to. We don't have to worry about setting
01:23up a formula. We don't have to refer to some cell that has that average in it.
01:27Above Average, and of course this is a moving target too.
01:31What are we seeing now?
01:32All the salaries that are above average.
01:34Lower left-hand corner reminds us that's roughly half the records.
01:38So the ability to get to numeric filtering is simpler and has been expanded.
01:44It's a lot easier to use than prior versions.
01:46And once again, because Excel recognizes the kind of data that you have in a
01:50field, it makes filtering much more efficient.
Collapse this transcript
Harnessing special date filters
00:01In this worksheet called ApplianceSales, there are about 900 records and it
00:06covers data over a two-year period.
00:08And let's imagine that our filtering needs revolve around Column E, what's
00:13happening in the Date column.
00:14Let's apply the filter by going to the Data tab, clicking Filter.
00:18If you have worked with date filtering in the past, it's been one of the more
00:22cumbersome capabilities of Excel in the filter arena and very often in prior
00:27versions you needed to go into the so- called Advanced Filter to get these done.
00:31I am going to click the drop arrow here and you will of course see date
00:36filters, just as we might have seen numeric filters or text filters, but huge expansions here.
00:42And imagine, perhaps thinking of your data, how you might use some of these
00:46filters to narrow down the data from certain months or weeks or quarters, and
00:51don't overlook the second to last choice here.
00:54All Dates in the Period.
00:55Now, I remember distinctly how in prior versions if you wanted to get data just
00:59from July and the data might have covered multiple years, this was not easy. Now it is.
01:06I'm going to click July and we're seeing July data.
01:09There it is for 2011, there it is for 2010.
01:12It isn't necessarily sorted,. Maybe that has to do with how the data appeared
01:16ahead of time, but it's so easy to get to.
01:18And let's not overlook, also as we click this drop arrow, choose Date Filters,
01:23maybe we want to see the data from a certain quarter, and possibly next quarter,
01:28this quarter, or last quarter, but once again, going down to the second last
01:32choice here, how about just the data for Quarter 3 over the two-year period?
01:37And here too we might or might not want to sort the data, but we're seeing the
01:40data there for September and then August and July and so on and so on.
01:44Maybe we want to sort on opposite order, but you get the idea here.
01:47Out of all our records here, 229 out of the 909 are from the third quarter, and
01:53it's so easy to get to with this new enhanced datefilter.
01:58Anybody who works with date type data will really appreciate the huge advances
02:02here with this capability.
Collapse this transcript
Creating a top-ten list by value or percent
00:01When you want to show just the highest or the lowest values in different fields
00:05of a list, you can use a feature called Top 10.
00:09Now immediately, we want to suggest that that's just you might say a marketing term.
00:13Top 10 could mean Top 5, Top 8, Top 40, whatever.
00:17It could just as easily mean Bottom 10, Bottom 40, whatever. And the number 10
00:23could be an actual number or it could be a percent.
00:26So it's a lot more flexible than the actual name itself.
00:30Let's click anywhere in this data and apply a filter. And maybe we want to see
00:34the top ten salaries within the company.
00:37The records associated with those salaries.
00:39Click the drop arrow for Salary > Number Filter s> Top 10, and here's where we see
00:45the variation coming in if we wish to choose it.
00:48Top could be Bottom.
00:50Let's leave it at Top for now.
00:51It could be 10 or any number we want.
00:54Maybe it's the Top 15. Change it.
00:57And we simply want to see the Top 15 records, keep it at Items if we want to see
01:01the top 15%, we'll choose that.
01:04So you can quickly figure out how to make this work for you.
01:07We want to see the top 15 items, the five 15 salaries, and the records associated
01:12with them, there they are. Here too.
01:14If we want to sort these, that's fine.
01:16Click the drop arrow, descending order, there we go.
01:19Top 15% would probably be a lot more in this example.
01:22We've got about 700 records.
01:23So we'd be seeing about a hundred of these.
01:26So we did Top 15%. Top 10%, about 75 or so.
01:30So you can easily make these work for you.
01:33I do want to show you an idea that's going to be a little bit confusing though.
01:37Let's remove this filter, just this filter for here, and remember if it's only a
01:41single column, you might remove the filter here by clearing it.
01:45We could just as easily have cleared the filter from the Ribbon, because we
01:49don't want filtering anywhere for the moment.
01:51So either way it works.
01:52Now let's imagine that we were focusing on just the people in one department.
01:56So I am going to use the filter here on the Department field, unselect them all,
02:00and just focus on Manufacturing people.
02:03It is the biggest department here, click OK, we've got 151 records.
02:08So you might be saying "Well, I want to see the top 10 salaries in Manufacturing."
02:13Click the drop arrow here, Number Filters > Top 10 items. OK.
02:17But we are only seeing 3.
02:18So what is that telling us?
02:20Out of all the top 10 salaries in the entire list, only three of them are
02:25coming from Manufacturing.
02:27And so, if you really do want to see the top 10 within Manufacturing, let's
02:31remove this last filter, the top 10 based on Salary, let's clear the filter from
02:38there only and then here's our list of all the Manufacturing people.
02:42Let's simply sort that list in descending order.
02:46Largest to smallest.
02:47Here are the top 10 salaries here as we look at the list and you just have
02:52to see it that way.
02:54But don't confuse as we can see how easily that could happen if you choose Top
02:5810 after already having a filter in place.
03:01It could be misleading.
03:02But there are some real advantages to the capability, and again, as long as
03:05you remember that the 10 can be any number you want, you can really make it
03:09work to your benefit.
Collapse this transcript
Creating custom filters
00:01In this worksheet consisting of scientific data, in Column B we see codes.
00:06If you work with coding structures you know how strange they can be sometimes.
00:09It just so happens that based on the codes that we're seeing here, we need to
00:13find those that have B in the second position, like this one, and then later the letter Q.
00:19Now, here is a Q right behind it.
00:21There might be some others.
00:22Here is a Q that's a few characters removed.
00:24We want to find all situations where B is the second letter and then later there's a Q.
00:29So let's apply a filter to this data. And click the drop arrow for Code, Text
00:35Filters > Custom Filter.
00:39Not equals, but begins with, anything, we don't care what it begins with, and
00:46like in our previous example, question mark, then B is the second character.
00:51The asterisk symbol means 0, 1, or many characters.
00:56So after the B, either immediately or one or two or three or four characters
01:01later, a Q is going to cover all those situations.
01:04I'll click OK and in our results we see B in the second position in all of these.
01:12Here the Q occurs immediately after the B. Here it's about four characters away.
01:17Here it's immediately after.
01:18Here it's two characters away. So in all cases.
01:22So just seeing one example of how you might use question mark and asterisk and
01:27sometimes together like we saw here, you see some very unusual constructions.
01:32So you can imagine the occasional need, particularly with code numbers, to pull
01:36out some very unusual data by way of a filter.
Collapse this transcript
Copying and sorting filtered lists
00:01It's not uncommon when viewing a filtered list to want to copy the data elsewhere.
00:05There are special rules that allow us this to proceed pretty quickly.
00:09You don't have to worry about the hidden data.
00:11You also have the option of pasting the data as values or actually pasting it to
00:16include formulas where present.
00:18Let's imagine in this particular list here, we want to apply a filter and maybe
00:23we just wanted to see people from certain departments.
00:25So clicking the arrow for Department will unselect all of these and choose just
00:30the people in the ADC group and in the Audit Services group. Click OK.
00:35And we may or may not want to sort these, but if we do, we could do that pretty
00:39quickly here, sort A to Z. We've isolated the two.
00:42Let's simply highlight the data.
00:44We might want to include the titles as well.
00:46There is a concern though as we consider highlighting the data.
00:50What about formulas that might be in here?
00:53Here is a formula here, rather long, that easy formula that extracts the month.
00:59There is another formula right there that calculates the number of years a
01:03person has been here.
01:05There is some concern about what's going to happen if we copy/paste data like
01:09this and the other concern is if we highlight all of this data, what about the
01:13data in the hidden rows?
01:15Well, if we manually select this data, just drag across and copy it, you might
01:19right-click and Copy and possibly Ctrl+C. Go to a different worksheet.
01:23Now if you don't have a blank one handy, nice shortcut.
01:26Shift+F11 will create a brand-new sheet just to left.
01:29Let's jump out here, right- click and paste. There we go!
01:34Re-adjust the column widths, double-clicking any column boundary.
01:38We've got all of our data and just the visible data.
01:40We didn't have to worry about that.
01:41How about the formulas in the Monthly column here?
01:45Well, those are no longer formulas.
01:46Well, based upon what you want to do with this data, maybe this is just fine.
01:50Years of service, it's accurate right now, but it won't be within a day or so.
01:55Even tomorrow that may or may not be all right.
01:58So let's reconsider how we might want to do this.
02:01Many times what we just did is just fine.
02:03Key idea, of course, was we didn't worry about the hidden data. None of that got picked up.
02:08Go back to the list where the filter was.
02:11Data is still highlighted. Let's copy this again, maybe a Ctrl+C. Those
02:15so-called marquee lights are a reminder that you're just picking up the visible data.
02:21So once again, we will go to that other sheet.
02:22It's called Sheet1.
02:24This time, put the data below here. Right-click, how about a Paste Special, and
02:30this time formulas or possibly formulas and number formats maybe.
02:36We do want to keep those formulas, click OK ,and we want the formulas to relate
02:41to the data that we see here.
02:43So here's one of them right here and there's that big long formula and over
02:48here's the one for Years. We see that as well too.
02:50So based on what it is you're trying to do at different times, you may want to
02:55as you copy and paste consider pasting them as values, which is what happens
03:00when you do a simple paste, or paste them as actual formulas using Paste Special.
Collapse this transcript
Recognizing the limitations of standard filtering
00:01Despite the power and capability of the Filtering tool, there are some
00:04situations that you just cannot handle.
00:07Now, there have been huge improvements in filtering and in prior versions, by
00:11the way, filter was often referred to as auto filter, but we have another
00:15category called Advanced Filters.
00:17Not to be covered in this particular movie.
00:19Let's talk about those situations that filter does not cover.
00:22Let's apply the filter to this list here and imagine that the following request came up.
00:28We'd like to create a list here consisting of those people whose salaries are
00:32above 80,000 or whose years of service are 20 or more.
00:38Now if we start with salary here and choose a number filter for all those that
00:43are Greater Than Or Equal to 80,000, there we go.
00:46If we now click the Year Filter and choose Number Filters and here we are
00:51interested in those who have been here 20 or more years.
00:54I think if you haven't tried this, you're already thinking what's going to happen here.
00:57We are going to get results here for people who meet both criteria at the same time,
01:04and the original statement was if the salary is greater than 80,000 or
01:09the years are 20. There's no way that we can handle this with a standard filter.
01:15We must use an advanced dilter.
01:17Thinking along similar lines, imagine if you wanted to-- and I'll pull back all
01:21of the data by Clearing-- you wanted to come up with a list consisting of those
01:26manufacturing people who are full- time and at the same time, those quality
01:30control people who are contract, admittedly an unusual combination, but trying
01:35to pull together disparate fields using the Or as a joining word, that's one way
01:40to describe it, is not going to work with regular filter.
01:43I think for most people, filter is going to handle 95% to 100% of what you need
01:47most of the time, but there is an advanced filter to handle these kind of
01:50unusual situations typically involving the word Or in different columns.
Collapse this transcript
3. Creating Automatic Subtotals in Sorted Lists
Setting up subtotals
00:01After sorting a list of data, perhaps like the current list which is sorted by
00:04department, you might want to insert automatic subtotals at appropriate
00:08breakpoints in the list.
00:11Once you do this too there will be some automatic expansion and collapsing tools
00:16called Outlining Symbols, which you can create using other features in Excel.
00:20So this particular list here is ready to have some subtotals inserted and
00:24rather than that manually--
00:25and it would take a lot time, there are about 23 departments here, but imagine
00:29manually putting a new row in front of each one of these--
00:31a prerequisite also is that your data has not been converted into a table.
00:36The next sheet to the right here is a table.
00:38I'll click on this and if we were about to use the Subtotals feature it's on the Data tab.
00:44Recognize that Subtotal out here is grayed out.
00:47You cannot use this on the data we first saw.
00:50I am going to back to that first sheet. We are ready to insert Subtotals here
00:54and on the Data tab the Subtotal command is available.
00:57The active cell is anywhere in data. We don't any have any empty rows or
01:01columns within our data.
01:02Let's click the Subtotal button and using this feature over the years this is
01:06this thing that I often forget.
01:08Every time you come into this command do check that first entry.
01:11If you haven't been using it sometimes it's got a different field there.
01:14Make sure it's the field that you're interested in that's going to be break
01:17point, in this case Department.
01:19The function you're going to use most of the time is likely to be Sum.
01:23There are some other variations there.
01:25In this particular list we can add Years, we could add Salary. Would we really
01:32want to add Job Rating?
01:33That probably wouldn't make a lot of sense.
01:35Most of the other fields are text fields.
01:37Now possibly we could've done Account, but counting only one of these made
01:41sense. Probably not all of them.
01:42So you might debate that or explore that a little bit.
01:45You could only use one of these at the same time on a given row here for--
01:49These are going to appear in the Subtotal rows.
01:51Let's click OK and we see what's happened here.
01:54At the end of the ADC department let me zoom back a little bit so we can
01:57see some more of these.
01:59We see Totals there for Years and Salary, and we also see this for Admin
02:05Training and of course for every department.
02:07Now imagine what would have happened here if we didn't have the data sorted and we
02:11said introduce these subtotals every time the department changes.
02:15So that's, if not a formal prerequisite, a pretty obvious prerequisite in terms
02:19of an effective use of this.
02:20Now just as important perhaps is seeing all this is to recognize those unusual
02:26characters that we see down the left-hand side of the screen.
02:29You'll see the numbers 1, 2, and 3.
02:313 is you could say the current one that's set.
02:34It shows us all the detail as well as subtotals and grand total.
02:38So I am going to click the number 2 and watch this list collapse.
02:43Now if you were about to print this, because we see the word Total in column B
02:47it might be a good idea to make column B a bit wider.
02:49We will just double-click up there, possibly that idea.
02:52Here and there check out your other columns to make sure they're wide enough.
02:55So conceivably you might want to print this, you might want to hide these
02:58columns in the meantime, but we are seeing the detail.
03:01Clicking the one over here is if not worthless pretty close to it.
03:04It simply shows the Grand Total only.
03:072 shows again just the Subtotals and 3 shows the detail as well as the Subtotals.
03:14Now if you were making a presentation on this data and talking about the various totals,
03:19if for example temporarily if someone said, "Well, give me some more detail on
03:22the compliance group here," notice to left there's plus.
03:25So I click the plus; that group expands.
03:29So we are seeing the detail for just that group.
03:32And you do see of course there is a minus over here.
03:34We might want to collapse this.
03:36So here and there possibly for display reasons, possibly even for printing, you
03:41might want to display the detail for some of these, but not others.
03:45So we have this quick ability to expand and collapse the data. And possibly you
03:52could leave your data in this form. It all depends upon how frequently do
03:56you do sorting, do you do filtering in subtotals, because these totals here are in the way.
04:02If you need to get rid of these, it's simply go back to the Subtotal command and
04:08then Remove All, and we are back to our normal view.
04:12So using the Subtotal feature is a quick way to insert automatic subtotals at
04:17various points in your list.
Collapse this transcript
Creating multiple levels and copying subtotals
00:01You can introduce additional layers of subtotals. In other words in the lists
00:05we are looking at here we might have major subtotals by department and have
00:09minor totals by status.
00:11If you look at the data for example for Admin Training here, recognize that this
00:15has been sorted secondarily by status.
00:18So let's introduce subtotals again, using the Subtotal command. Every time
00:23there's a change in Department Years and Salary Totals. Click OK.
00:28Our major levels are totally in place.
00:30Let's now introduce another layer.
00:33Back to the Subtotal command and now we would like to say every time there's a
00:37change in the status. So we are going to have a lot more subtotal lines and let's
00:43continue to add Years and Salaries.
00:45We do not want to replace current subtotals, so uncheck that box. Click OK.
00:52And now not only are we seeing multiple levels, for example here's the ADC
00:57department. Now because it's so small those totals don't quite stand out maybe
01:01as smoothly as we like, but it is accurate. We had a Contract total, a Full Time
01:06total of two people, half time for one, hourly for one.
01:10A little more obvious here perhaps or little better looking maybe, as we look
01:13at the Admin Training group.
01:15There is the entire group there and we see initial subtotal in row 14 for
01:21contract people, another subtotal in row 25 for full-time, and so on.
01:26And notice also the outlining symbols on the left-hand side.
01:29We now have four of them.
01:31If I click for three, we now see both layers of Subtotals and the Grand Total at the bottom.
01:39We are not seeing any detail. Clicking the two will show us the major level of
01:45subtotals and if we had only one that's the way it would have looked anyway, one
01:48layer of subtotals.
01:49And clicking the one again which show just the Grand Totals.
01:52So have got this ability again to expand and collapse at will.
01:56And a common issue here is sometimes people want to copy these totals.
02:02Now I am going to insert a new worksheet by pressing Shift+F11 just to the left here.
02:07It's a quick way to insert a new worksheet. Back to our data.
02:10What happens if we say let's copy this data? I'm going to highlight this data
02:15here. Possibly I could have hidden some rows ahead of time.
02:18I would like to copy this data just this.
02:20So let's select it. I will right click and copy or Ctrl+C, either way.
02:25Go over to this empty sheet, right- click and paste, and what happens?
02:30All the hidden data, different rows. I am not going to worry about the column.
02:34Unless we have got way too much data here. That's not what you want probably.
02:37So there is a workaround on this.
02:39It does involve first of all possibly a keystroke shortcut, if you know it, or
02:43otherwise a rather obscure command.
02:46And let's imagine we are back here again. Let's say we are about to highlight
02:50the data and we do that.
02:53Now what we'd like to do here is to copy just the data we are seeing and as I
02:59suggested bury it in the Excel command system on the Home tab and then the
03:05extreme right button, Find & Select. Nothing pops up out there, but there's a
03:11feature called Go To Special and in here's a choice called Visible cells only.
03:18Could you found that one? Click OK.
03:21And a slight screen difference on the display here. We are only highlighting
03:26right now the visible cells. If we use Copy now, right-click, Copy, Ctrl+C or
03:31Copy command, any of those,
03:35then perhaps the picture is a little clearer.
03:37Typically when you copy a range you see these so-called marquee lights, some
03:41people call them marching ants, around the perimeter of a range, but in effect we
03:46have got a whole bunch of different ranges here that we are about the copy.
03:50We are not copying the hidden cells.
03:52So go over to the Sheet2 from before. I want to paste just to the right of the
03:58existing data and no paste special here. Just a regular paste, there we go.
04:02And we do not see the hidden rows here. We see just we wanted to see,
04:06the visible data only.
04:08Now the keystroke shortcut and you might get used to it if you use this feature
04:11a lot, once again come back here and let's imagine we have just highlighted the
04:15data here, we are ready to copy it, but we want to make sure we are choosing the
04:18Visible cells only, keystroke shortcut Alt+Semicolon.
04:22Selects the visible cells only, instead of going to the Find & Select button and
04:28Go To Special and Visible Cells and all of that.
04:30Then we can do Ctrl+C for copy and go to the other location and paste.
04:34So its going to be handy at times. You don't need to worry about this in a
04:37filtered list, but in many-many other situations in Excel, anytime you're
04:41copying data and you've got hidden rows or hidden columns and you don't want to
04:46select that data, after first highlighting everything that you want to copy, press Alt+Semicolon
04:53before doing the copy.
04:54So that situation will arise.
04:56There is another issue here. Let's go back to the top of the list and you might
05:01as you look at the data here. I want to go back and show the detail by clicking
05:05the 4 here. You might want to include a different account of information or how
05:10many people in each department.
05:12And this probably would show up a little bit better if we had only one level,
05:15but it should work here as well too and maybe we'd like to show a total here of employees.
05:20It's going to be more meaningful for example in a list like this.
05:23Now, there is no direct way to do this other than what I'm doing right now.
05:27Go back to the Data tab, go to Subtotal. Every time there is a change in status.
05:32This time let's add another line called Count and we don't want to count the
05:37years of the salary. We want to count the employee name. We do not want to
05:42replace current subtotals, so we click OK.
05:47And there is Count setting out there sort of all by itself and here's the
05:50term Contract Count.
05:51I think for most people this is not a very appealing picture, but nevertheless
05:56we do have a total out there.
05:59Now a rather complex workaround that you could use. I think that's the stuff
06:03perhaps of another course, but when you are trying to get different kinds of
06:07totals like a Count and a Sum, that's what total means here, trying to put
06:11together at the same time probably doesn't look real great.
06:13But nevertheless at least we were able to do that here, just by inserting a new row.
06:18In other words a new level of subtotals.
06:21So multiple level subtotals are definitely a need. I think what we just did here
06:25in the last example here may be not so commonly used, but a great feature when
06:30you no longer need the subtotals. Simply remove them, back to Subtotals, and Remove All.
06:36Once you get familiar with working with subtotals the process of creating
06:40becomes pretty fast and pretty routine and so the idea of "well every time I
06:45use my data, do I have to create subtotals," well of course you don't, but it's an easy process.
06:49It doesn't take very long, it can be very fast and you can certainly do it with
06:53multiple layers pretty fast as well.
Collapse this transcript
4. Using Advanced Filters
Using the Advanced Filter for complex OR criteria
00:01Excel's filtering feature covers lots of ground and it works in most
00:05situations for most filtering.
00:07But there is another tool called an Advanced Filter.
00:10Let's take a look at why we might need this kind of a filter.
00:13This is a little involved, a little more cumbersome setting up, and it does
00:18involve something called a criteria range.
00:20What I am about to do is not at all obvious, so now I'll have to explain a
00:24little bit ahead of time and a little bit later.
00:26When you see a criteria range, it is usually in most examples that you might
00:31see in an Excel book on Advanced Filtering above the data.
00:34So what I am about to do here with this data is to highlight the first six rows
00:39and then right-click and Insert, and I am going to be copying the title row
00:43here, simply by dragging across these titles and I am going to drag this upward
00:48with the Ctrl key held down, put these into row 1.
00:51You might see in some examples a criteria range located to the right of the data.
00:56It could be there.
00:56It could be under the data, but there are convenient reasons for putting it here.
01:01Again, not all of this should fall into place immediately. Here's an idea.
01:05Suppose looking at this list below here we need to pull out a list
01:09consisting of those records where either the years of service is 20 or more
01:15or the salary is 80 or more.
01:18You cannot do that with the regular standard filter in Excel.
01:22We can do this with an Advanced Filter.
01:24What I am about to do now isn't exactly obvious, but in cell I2 here, I am going
01:30to put-in the formula >=20 and then and certainly not obvious, in column K but
01:38in one row below this, I'm going to put in >=80000.
01:45When we start to use the Advanced Filter, it will prompt us for a criteria
01:49range and this will be the criteria range.
01:53If you know Access, you maybe familiar with what's called a Query Grid and you
01:58would have some understanding of this layout.
02:01In no way is it intuitive but what it does mean is years of service >=20 or salary >=80000.
02:10So the active cell will be within the data, and we're going to click on the
02:15Advanced Filter located on the Data tab.
02:19And in this dialog box, nearly every time the list range Excel figures out just perfectly.
02:24That's the entire list of data here.
02:27You do have the option of copying the results elsewhere.
02:29We don't need to do that here.
02:31Here is the indicator for criteria range, and rather than collapsing the dialog
02:36box here, let's simply scroll over to the cells in question and highlight these cells here.
02:42This is going to be the criteria range.
02:44There is a Unique records option only, which we won't use yet and we won't
02:49need it in this example.
02:50But as we click OK, watch the list below row 7 change. And the indicator in the
02:56lower left-hand corner says 125 of the records meet our criteria.
03:01So what are we seeing here?
03:02Here is a situation where the years are 20 or more.
03:06Next record, high salary, next record, high years, and so on.
03:10In some cases potentially both criteria will be met, but based on the criteria range,
03:16if either one of these is true, we will see it appear in the list.
03:23And there it is, there is the entire list.
03:24We might make more sense out of this a little more readily if we sort on one of
03:28the two fields. We could easily do that with the active cell in either location.
03:33Maybe we'll do a ZA sort of the toolbar this way. We see the data here.
03:37Here are all the people who make more than 80,000.
03:40Some of them do have 20 years, most of them don't, and so on.
03:45There is the entire list.
03:47an unusual construction, an unusual way to set this up.
03:50Now, could this criteria range have been to the right of the data?
03:54Yes, it could have been, but in performing the filter, because rows are
03:58hidden, we can see that row 8 is hidden and row 10 is hidden, then we
04:03couldn't quickly review and look at the criteria range to make sure it was working properly.
04:08That's why more often than not when you see a depiction of an advanced filter in
04:13an Excel book, it's likely to have been setup above the data like this.
04:18So there are other situations as well, and it is unusual. The Advanced Filter
04:23usually covers situations where you just cannot get to these using the
04:27standard filter.
Collapse this transcript
Using the Advanced Filter for complex multiple-field criteria
00:01When you're trying to use filtering on multiple columns involving multiple
00:04criteria, the standard filter just doesn't work some of the time.
00:09We need to use an advanced filter.
00:11Suppose in the data here comprised of about 700 rows, we need to see people
00:16from a certain department who are full time and we also want to see people from
00:20another department who are half- time. And you can imagine some other
00:24combinations like that.
00:25What we need to do is set up a criteria range, so let's highlight the first six rows,
00:31put this above the data, insert, and simply copy the top row here, holding
00:37down the Control key drag this upward.
00:39Let's just pick some departments here, for example ADC. Rather than typing this,
00:44I am just going to copy this up here.
00:46We would like to see out of the ADC department, the full time people. There are
00:50two of them. Once again to save myself some typing here, something with the Ctrl
00:54key I am going to drag this here.
00:56We are also interested in getting and seeing people from the
01:00Engineering/ Maintenance group.
01:01So once again saving ourselves some typing, holding down the Ctrl key. This.
01:07And here we are interested in seeing from that group the half-time people, so
01:11I will just copy this.
01:13As a criteria range, this list here first of all does ignore columns D and E.
01:20If we use the Advanced Filter on the data, starting at row 7, what we are saying in
01:24English is let's see all records where the department is ADC and Full Time, in
01:31other words that combination together, or if we have got a combination of
01:36Engineering/Maintenance and Half-Time. That's what this criteria range means.
01:42So clicking anywhere in the data, using the Advanced Filter, here is our list
01:47range, totally accurate, criteria range, click here, scroll upward, select
01:54just these cells here.
01:56So the ADC Full-Time people, Engineering/ Maintenance Half-Time people. Click OK.
02:03Any record we see here meets the two criteria, either this combination or this combination.
02:11So another way to read this is as we read left to right we are using the word
02:16And, those who were in the Department ADC and whose status is Full-Time, or those
02:23people in Engineering/ Maintenance who are Half-Time.
02:27And you can imagine different combinations here.
02:30And you can come up with almost any kind of combination imaginable, the more
02:33you work with these.
02:34Now, if were to put Engineering/ Maintenance here and this were the criteria
02:39range, that would be very unusual and highly unlikely what it would mean is
02:44let's see all records where we either have a combination of these two criteria
02:50or anybody who's Half-Time or anybody who's Engineering/Maintenance.
02:55So even it wouldn't do that probably, it's doable and if you're familiar with
02:59the Access query grid,
03:00this would help because you understand in a same kind of way that's done.
03:04But there's another use for an advanced filter to not quite so obvious.
03:09And that's, for example, if we wanted to use a function on one of our fields.
03:14For example suppose we wanted to find all the people hired on Monday.
03:18I think if I that were a sale day perhaps it would be more pertinent. How would we
03:21come up with this kind of construction?
03:24And there's no standard way to do this otherwise.
03:27The following formula is our starting point. Equal and I'm going to type in here g8.
03:32What does that mean?
03:35That's the first cell in the list that has a higher date in it. We are not
03:40seeing it currently because the other filter is in place unless we use it here. =g8.
03:46Now we want to find out if these people were hired on Monday. You would need to
03:50know that here's a function called weekday and if the weekday of g8, meaning the
03:57first cell that has a date, =2. If you are familiar with the weekday function, 1
04:04is Sunday, 2 is Monday etc.
04:07Now, to make this a little more readable let's go into our data and clear the
04:11filter, bring back all the data. So here is the data.
04:14And the reason this says false right here is the literally that very first entry
04:18there is not a Monday.
04:20I don't care what it is really, but it's not a Monday.
04:23Now here is what we are about to do.
04:24We are going to use the Advanced Filter and use these two cells as the criteria range.
04:31Now without any knowledge of why this doesn't work, I'm going to remove this
04:36word here and we must do this, this phrase, Hire Date.
04:39This will be the criteria range and we will see just the people hired on Mondays.
04:47So with the active cell within our data, we use the Advanced Filter.
04:52The criteria range is not what it had been. It is now going to be just these two
04:56cells and this will not work if you leave data in cell G1, so that has to go.
05:02And here is the criterion that we put in earlier and click OK.
05:07And there are 112 of these records.
05:09These are all Mondays. You could do a quick test on one of these simply by
05:13typing equal weekday, left parenthesis.
05:17Click on one of these dates.
05:18The answer will be 2, because its a Monday and that's a Monday also and so on.
05:24So pretty far away from being intuitive. I have never even come close to calling
05:28at that, but another use of the Advanced Filter for unusual situations which you
05:34cannot get to with the regular filter.
Collapse this transcript
Using the Advanced Filter to create unique lists from repeating field data
00:01A not so obvious capability of using the Advanced Filter is the idea of
00:05creating a unique list.
00:07Now sometimes you might do this even for a single column. There are about 700 or
00:11so here. We might want a unique list of the departments.
00:15Obviously we see recurring entries here. We might have that need.
00:20More expansive is the idea that maybe you got duplicate records in here.
00:24There are a couple right here. Do we have others?
00:28No we don't know necessarily and if so, where are they? Let's get rid of them.
00:31We are not going to be using the new feature called Remove Duplicates, although
00:35that's certainly an option.
00:37But let's talk about the idea that we can use the Advanced Filter to create a
00:41new list that does not have duplicates.
00:44How many records are here?
00:45I am going to double-click the bottom edge of this cell.
00:48We see that it goes down the row 762.
00:51Let's create a new list using the Advanced Filter.
00:54We are going to put that list off to the right here.
00:57We want to compare its results with what we now have.
01:01So the active cell is within our data. Let's go to the Advanced Filter on the
01:05data tab and we want to copy the results to another location.
01:11The list range is right here. No criteria range is required.
01:16We want unique records only.
01:19What's the upper left-hand corner cell? Well we are going to copy these two,
01:22let's just scroll over to the right there, and for example M1. That's going to be
01:29the upper left hand corner of the receiving area.
01:31So we are not in any way altering the existing list; we're about to create a new
01:36list consisting of unique records only.
01:39Let's click OK and that list is their presumably. Let's go find it. Let's go to
01:44the bottom of it too. Double-click the bottom edge.
01:48And this goes down to row 742.
01:51So there were some other duplicates in there as well.
01:53And you might have seen at the top of the list, there is one Juan Bishop, but
01:57Juan Bishop below or above that record.
02:00There we see what's happened.
02:02So that capability works on the entire list.
02:05Now also suggested was this idea.
02:09We have got a list of departments here. We just don't happen to have a list of
02:12all of our department in one nice place.
02:15Let's collect it real fast.
02:17This time we are going to use column C only and use the Advanced Filter for
02:22just column C. Advanced Filter, adjust this list range to be just column C,
02:30copy to another location, no criteria range, Copy to, let's scroll to the
02:36right into an empty column.
02:38Simply use Y1 here.
02:40Unique records only. Click OK and over in cell Y1 there is that list even with the title.
02:49That's a unique list of our departments.
02:51No repeats in there.
02:52It's like we have got 23 different departments and there they are. You probably
02:56want to sort that, but nevertheless there it is, quickly and easily.
02:59So the Advanced Filter can be used to create a unique list. In a latter
03:04example, simply a unique list based on column entries. Prior to that we saw how
03:08it could be used to create a new cleaned up list of this existing data, with no
03:13duplicate records.
Collapse this transcript
5. Eliminating Duplicate Data
Using the Remove Duplicates command
00:00Getting rid of duplicate records in a database, or a large list, addresses a
00:04problem that occurs frequently in large lists of data.
00:08Finally, as of Excel 2007, a new command called Remove Duplicates is now
00:14available on the Data tab.
00:16In large lists sometimes you don't see duplicates that easily.
00:20I happen to see one here in Row 5. That's Juan Bishop.
00:23Here is another Juan Bishop here in Row 10.
00:25Now, the names being the same
00:28alone isn't enough to indicate that the record is duplicated, but a quick
00:31look here, I think you can see pretty clearly with Social Security number's and
00:34phone number's duplicated. That's a duplicate record.
00:38Now, in prior versions of Excel, you needed to use something called the Advanced Filter.
00:43But with this new capability-- and by the way, the data does not have to be in
00:47any particular order.
00:48It doesn't have to be sorted here. We can remove duplicates relatively quickly.
00:54In this list here, I am going to double- click the bottom edge of a cell first of
00:57all just to see how far down it goes.
01:00It goes to Row 762. Double- click the top edge down here.
01:04Let's proceed with Remove Duplicates.
01:07As with other commands in the Data tab, as always before proceeding with
01:12commands, if you know that your data is altogether with no empty rows or no
01:16empty columns, we can simply click on a single cell on our data and start the process.
01:22Remove Duplicates.
01:24Now we possibly don't need to check every single column.
01:28In fact, you could say here well, as long as the Social Security number and the
01:33phone numbers are the same, we know we've got a duplicate.
01:36But on the other hand, these are all checked and it's not going to hurt anything
01:39here. If one of those is different though, will not have a duplicate record.
01:43It will not be deleted.
01:45So we had 762 rows.
01:47Let's proceed here using all these columns. Click OK.
01:5020 duplicate values.
01:53Now, I would quibble a little bit with the wording there, but we're talking
01:56about rows or portions of rows, records perhaps, found and removed. We're down to 741.
02:03So we get down to Row 742 because of the titles.
02:06You could see only there is a Juan Bishop here. There had been one in Row
02:0910. Not there anymore.
02:13Down at the bottom, used to go to Row 762. Now it goes to row 742.
02:17So we did eliminate 20 rows here.
02:20Excel's new feature called Remove Duplicates is fast and easy. It works ideally
02:25with large or small lists to quickly eliminate duplicate information.
Collapse this transcript
Using a specialized array formula to identify data that's been duplicated
00:00As fast and easy as the Remove Duplicates command is to get rid of duplicate
00:05data, what it does not do for you is indicate what has been duplicated.
00:10So for example, in this list here which does have duplicates in it, there is a
00:15Juan Bishop in Row 5, also one in Row 10.
00:18If we want to identify which records have been duplicated before getting rid of
00:23them, what we need to do is sort the data.
00:26So I do have another list here, an exact list, but it has been sorted,
00:30clicking over here.
00:31And in this list we will see two Juan Bishops together.
00:36If you do want to identify duplicate records here, what we need to do is after
00:41doing the sorting, insert a new column to the left of Column A. And what we are
00:47going to do here is to put in a formula.
00:49I want to show you or start off at least with the long way and then show you
00:52a nice quick way using an array formula to identify which records have been duplicated.
00:59So, here's the formula I am going to put in here.
01:00I can start probably in Row 2.
01:02It's good to see everything in place. =if.
01:05Now you may or may not be familiar with the If function but this I think
01:09almost explains itself.
01:10Here is what we'd like to say.
01:12And we want to include the word And.
01:14And for the moment we are only thinking of rows 2 and 3 and we know they are not
01:18duplicated but they could be.
01:20So we'd like to indicate if this cell B2=B3, comma, and if C2=C3, comma, and if D2=D3, comma, and on and on and on.
01:36Now this is going to get really long, but if they are all equal, and why don't I
01:41just cut it short here for the moment and then show you a better way to do this?
01:44But we're on the path here for this to make sense. If these pairs are all equal
01:50to one another, I'll just go this for right parenthesis, comma. In other words,
01:55if all those pairings are true, that they are all matched, then what do we want
02:00to see here over in cell A2? "Dup".
02:04But if that's not the case, if any ne of those is not the same then we want to
02:08put in a word Unique. Right parenthesis and Enter.
02:14And those are unique and we can copy this down the column relatively quickly
02:18simply by double-clicking the lower right-hand corner.
02:21So all these are unique and sure enough down here in Row 50 there we go, 53,
02:27that's a duplicate, and we'll find others eventually.
02:29Now we've got several hundred names. No reason to scroll through all of this.
02:33We could have 70,000 or 700,000.
02:36This at least identifies the records that have been duplicated.
02:40Possibly you can use a filter and just show the duplicated ones. We could do that.
02:44You will need a dummy heading up here. Put in anything for the moment.
02:48If we introduced filtering right now we could then on this column right here
02:53simply show those that are dup and then see the list of the records that
02:59have been duplicated.
03:00Sometimes that's important, sometimes not.
03:03But this is the way to get there.
03:04Let me remove the filter and to complete this formula and actually do it all the
03:11way across, in other words not just to Column F but all the way across, seems
03:15like it would take a lot of work.
03:16In other words, to really do the check here fully we'd want to check all the way
03:20over into in this example into Column L.
03:23But here is a better way to do this and there is a special kind of formula in
03:26Excel called an array dormula.
03:29So what we'd like to do here is actually change this to read B2:L2=B3:L3.
03:42In other words, as I delete all this, all the cells B2 all the way over to L2 we
03:48are going to check all of those and we are going to compare them with the
03:51corresponding cells in the row below.
03:53And this is a lot shorter than what we just saw.
03:56Now, this is what we call an array formula.
03:59In order for this to work properly I need to press Ctrl+Shift+Enter, not simply
04:04Enter. Ctrl+Shift+Enter, there we go, and I'll double-click to recopy all this.
04:11We'll still find our duplicates down there in the same location, but it's a
04:14much shorter formula.
04:16Let me once again display this a little larger so we can see it, make it a
04:19little bit wider, and so what we are seeing again in English-- let me make this
04:24even wider so we can see it.
04:28We're going to compare B2 with B3 and C2 with C3 and on and on and on all the
04:33way over in Column L. If all those are the same, we've got a duplicate.
04:39If any one of them is different it's going to be unique.
04:41So this is how to identify the records that are duplicates.
04:44It's an unusual kind of formula.
04:46You may or may not have seen array formulas, but I think you'll see pretty clearly.
04:50Any time there is the need to identify the duplicate records, a formula like this
04:55will get the job done.
04:56If you'd like more information on array formulas and how they work, you might
05:00want to check out another course in this series, Advanced Formulas and
05:04Functions for Excel 2010.
05:05There is an entire chapter on array formulas there.
Collapse this transcript
Using an array formula to count the number of unique items in a list
00:00When you need to count how many unique entries there are in a column or a row,
00:05a special array formula will give you a quick answer.
00:07Now this is an unusual formula that meets the need for the fact that there
00:11really is not a function in Excel called Unique.
00:14As we look at this data on this worksheet, the question might come up, how many
00:18different entries do we actually have in Column C?
00:21How many different buildings do we have?
00:23Those are things you would want to know. Perhaps you know some of them.
00:26How many statuses we have?
00:28We know there are four, for example here.
00:30But way to do this and you don't necessarily need to do this above your data,
00:35but I think we might want to put it here at least temporarily.
00:38By inserting a new row above Row 1 here and here is the formula.
00:43Now it's an unusual formula and it is an array formula and in effect what we
00:47like to be doing here is counting or comparing every single name here with every
00:52other name to see if there are any duplicates.
00:54What we really are trying to do though is count the number of different entries.
00:59We recognize that possibly we might have two people with the same name.
01:02But why not do this for every column?
01:04So here is the function.
01:06Let me zoom in on this too, because it is unusual.
01:10And in this column, let me do a quick check at the bottom here.
01:13There are 763 rows right now, since we inserted a new one.
01:18So we want to keep that number in mind.
01:19=sum(1/countif( and I don't want to highlight all these cells but I do want
01:32to start dragging here at least down to here and I'll just complete the
01:36typing by putting in the 63.
01:38So we want to take everyone of these cells here.
01:41I am going to copy so I don't want to have to retype it.
01:45And compare with everyone of those cells to count how many times it appears there. )).
01:53Again, it's a hard function to explain and it would take at least five minutes.
01:56There is more information in another course on Excel Advanced Formulas and
02:00Functions, both through 2010 and 2007 you might want to take a look at.
02:05But I am going to be pressing Ctrl+Shift +Enter here to get a count of how many
02:09unique entries there are from cells A3 to cells A763 and there is the answer.
02:16741, so all the names are unique.
02:18Let's do a quick test here. I am going to duplicate Troy Sanders name just by
02:22copying it downward here. Now of course we now have 740.
02:25Let me undo that by pressing Ctrl+Z. How many different buildings do we have?
02:31We'll just copy this to the right here. Six different buildings. How many
02:35different departments do we have? 23 different departments and so on.
02:39Possibly you'd want to copy this all the way across. Or once you had done this,
02:43if this is vital information and you want to keep it handy, maybeyou put it to
02:47the right side of your list or possibly below it, wherever you wish.
02:51One-by-one each of these formulas has a similar look to it, and they are very
02:54unusual, but it gets the job done.
02:57It allows us to quickly make a count of how many unique entries there are in a range.
Collapse this transcript
6. Using Database Analysis Tools
Using SUMIF, COUNTIF, and related functions for quick data analysis
00:00The SUMIF/COUNTIF family of functions, introduced in Excel 97, now include four
00:06new functions in Excel 2007 and they give you lots of tools for tabulating a
00:11variety of statistical totals when you have database type lists.
00:16The functions and questions are listed in Column J here. Normally you wouldn't
00:21see these listed just like this, and I've separated them because they're more or
00:25less in groupings here.
00:26SUMIF, COUNTIF and AVERAGEIF. AVERAGEIF is new in Excel 2007.
00:32And these functions you can almost figure out what they do by their names.
00:36This list here is substantial.
00:38It might grow, it might shrink.
00:40And we might want to know, for example, simple question, how many half-time
00:45people do we have, how many full-time people do we have?
00:47So start off actually with COUNTIF and use this function right here, =COUNTIF.
00:55Two arguments. Where are we looking?
00:58Now you certainly can and I certainly could here highlight all of the cells in
01:01Column D, but it's a lot simpler to simply click Column D instead.
01:06So instead of doing all that let's just click.
01:09And what's great about this capability too, or this approach to the function is
01:14that if we add names to the list or if we take them out we don't need to change
01:18the way this formula is being set up.
01:20So using an entire column here makes sense.
01:23Where are we looking?
01:24Column D. What are we looking for? Full Time.
01:27Now if I don't have that phrase nearby in a cell, although I do to the
01:32right here, I'll simply put in double- quote and type in "Full Time".
01:36And we are all done, Enter.
01:40How many full-time people do we have here?
01:42393. Obviously we're going to keep that, adjust the display of the format.
01:47If we do have the data nearby, possibly instead you would just click on that cell.
01:53So how many full-time people do we have?
01:56And if we somehow found that to be valuable and we have the other kinds of
02:00statuses listed next to this we could clean up the display a little bit by
02:04decreasing the decimals and simply drag this down a few more cells, there we go.
02:10And so we've got a Half Time count and an Hourly count and a Contract.
02:14So COUNTIF is pretty straightforward and easy to use, and it does provide us
02:19with good information about our data.
02:21And if you want something like this to be setup along with your data it's not a
02:25bad idea to put off to the right.
02:27But with one slight exception it might not be so good. If you do a lot of
02:31filtering, which of course does hide rows, some of this data may be hidden
02:35at different times.
02:36Now the other option possible is to put this above your data, but then it makes
02:41these kinds of formulas not quite as easy to write, because you couldn't be able
02:45to use entire columns there.
02:47All right, without going through all the variations here but just a few more,
02:51the SUMIF function does go a step further and it allows us to tabulate some
02:58data from another range.
03:00And when we are using different ranges here they must be parallel.
03:04So let's say that instead of counting how many people that we have that are full-time,
03:08we want to know their total salaries.
03:11So SUMIF has a third argument, comma, and in this example it's Column G so
03:16we'll just G, all done.
03:19Total salaries of our full-time people. There too we could copy that down if
03:23wanted the information for the others.
03:25And initially these two functions were around for quite a while, a lot of
03:29clamoring for this function, new in Excel 2007, and you can imagine what it does.
03:33Real simply quickly here we'll just simply put in-- we want to know the average
03:38salary of for example, the people that are full time, and there it is, and we
03:45could do the same for the others as well too, so AVERAGEIF.
03:49In prior versions before Excel 2007, if you wanted to use multiple criteria you
03:55had to use array formulas but these three new functions here are just that they
03:59are exactly nearer the others except they end in S. I'll start with this one.
04:05And I am going to point out here that actually SUMIFs and AVERAGEIFs are little
04:09different than COUNTIFs and start with this idea.
04:15We need to add up the salaries, not only the people who are full time, but the
04:21people who are full time and have a certain job rating.
04:25And we can have multiple sets of criteria.
04:28So the SUMIFs function begins with what it is we are trying to add up.
04:35So the order of things here might get a little confusing if you just remember
04:38what we've done in the previous ones. In the other functions that we just saw
04:42the data to be tabulated came last, not comes first.
04:46So we want to be tabulating salaries, comma, and now in pairs various criteria.
04:53And we can have one pair, two pair, three pair, quite a few in fact.
04:57The first pair might be Status, comma, Full Time.
05:03That's in cell L2 so I'll just refer to that.
05:06We could hit Enter right here and simply get total salary of our full time
05:10people. We already did that with SUMIF, but to expand on the idea here, SUMIFs
05:15allows us multiple criteria, so what else are we looking for here?
05:19People who also have a job rating, comma and because this is a number we don't
05:26have to put it in quotes, those who have a job rating of 5.
05:30We could have another pair.
05:31So the first pair indicates we want to be looking at those who are full-time
05:37and, even though we don't see the word and, second pairing here is job rating of 5. We press Enter.
05:43The total salaries of our full yime people who have a job rating of 5.
05:48It might be more interesting and more valuable to be able to do this as an actual average.
05:53So why not just pull this down here and readjust it, put it next to
05:56average, make a change?
05:58We want to know the average salary of all those people in our list here who are full time.
06:05So we've got a pairing here who are full time and who have a job rating of 5.
06:12There is the average salary for that group.
06:14Now again, there could be following the five, a comma, a pair of criteria, two
06:20more of these, another pair, another pair, on and on and on and on, without long
06:24cumbersome formulas.
06:26So these are great tools for tabulating data, particularly adept at handling
06:31information across lists.
06:33SUMIFs, COUNTIFs, and AVERAGEIFs.
06:36If you want more examples you might also want to check out the course on
06:39Advanced Formulas and Functions either for Excel 2007 or Excel 2010. They are
06:45identical in the two different versions.
Collapse this transcript
Using database functions like DSUM, DAVERAGE, and DMAX
00:01In Excel there is a category of functions called database functions, and
00:05although less frequently used in the past because of the SUMIF family of
00:09functions has been expanded greatly,
00:11these database functions rely on the kinds of criteria ranges used with
00:15the Advanced Filter.
00:17If you haven't used the Advanced Filter these might seem a little strange to you.
00:21But there are some advantages here and there.
00:23And these functions do mesh well with those Advanced Filter applications,
00:28particularly when you've got unusual calculations SUMIF and COUNTIF can't handle.
00:33Now for reference in Column J I've simply listed here the various
00:38database functions.
00:40If you remove the letter D from each of these of course you probably recognize
00:43most of those anyway.
00:44Now here is a strange thing. In Excel 2007 and in Excel 2010 if you're a little
00:50bit curious about these database functions, you heard a little bit about them, if
00:54you go to the Formulas tab you say, "Well, I don't see them here, they must be
00:58here under More Functions."
01:01But we're not seeing them; they're not shown here.
01:04Maybe that's some indication as to what Microsoft plans to do with these
01:07functions in the future. But we don't see them.
01:10However, if you click the fx button on the left side of the Formula Bar and look
01:15at the categories that are available here you will see Database functions, and
01:20here are those 12 functions.
01:22And what they all have in common is that they refer to a criteria range as
01:26the third argument.
01:27And if you have worked with the Advanced Filter you probably recognize on the
01:31screen here that potentially this is a criteria range. This is or maybe the two
01:36of them together are.
01:38So, let's talk about how we might use one of these, for example
01:41DAVERAGE, =daverage.
01:44We'd like to find the average salary of our full time people.
01:48Now I think a lot of you know possibly you could be using one of the SUMIF,
01:51COUNTIF, AVERAGEIF functions here.
01:53Let's choose this function as an example of how we might use the others.
01:57We're looking at a database.
01:59I'm simply going to drag across columns A through F. In other situations you
02:03might be highlighting all the cells. Make sure you do include the title row
02:07there. Comma. Which field are we trying to tabulate data from?
02:12From left to right it's the seventh column, Column G. So we put in the number 7
02:18here, comma, and how about this criteria range?
02:22And here your knowledge of using Advanced Filter would come into play.
02:27We simply want to highlight the cells J1 and J2.
02:30What's the average salary of our or full time people, that's what we are
02:34calculating right now, and there it is.
02:37If we wanted to know the total salary of those salaries that are greater than
02:4380,000 or maybe more interestingly a count of how many salaries are over 80,000,
02:48perhaps we'd use DCOUNT, =dcount.
02:53So once again like in the previous example we're looking at this database here. Comma.
02:58We're tabulating a data from Column G so that's the seventh column, comma, and
03:06our criteria range this time around is these cells here.
03:10Tell me how many cells have salaries greater than 80,000, and there are 71 of them.
03:17So perhaps you can begin to see how this has some merit. Again they seem to be
03:22on the wane in terms of being widely used in Excel worksheets, but there's some
03:27real power and capability.
03:29And if you do work with the Advanced Filter concept you're aware of how these
03:33have some real potential here and there are quite a few variations on how you
03:37use the Advanced Filter.
03:39And these functions do mesh nicely with that capability.
Collapse this transcript
Conclusion
Next steps
00:00Upon completion of this course you may want to check out additional courses
00:04available at lynda.com.
00:06For related courses there is Setting Up a Database in Excel and also Cleaning
00:11Up your Excel data.
00:13For a review of basic Excel functions, take a look at Excel 2010 Essentials.
00:19And if you want to become a more proficient user of this powerful software,
00:23check out the Excel 2010 Power Shortcuts course.
00:27And check back from time-to-time for additional courses add to this series.
00:31Thank you for watching.
Collapse this transcript


Suggested courses to watch next:

Setting Up a Database in Excel (43m 27s)
Dennis Taylor


Excel 2010: Data Validation in Depth (59m 45s)
Dennis Taylor

Excel 2010: Charts in Depth (3h 38m)
Dennis Taylor


Are you sure you want to delete this bookmark?

cancel

Bookmark this Tutorial

Name

Description

{0} characters left

Tags

Separate tags with a space. Use quotes around multi-word tags. Suggested Tags:
loading
cancel

bookmark this course

{0} characters left Separate tags with a space. Use quotes around multi-word tags. Suggested Tags:
loading

Error:

go to playlists »

Create new playlist

name:
description:
save cancel

You must be a lynda.com member to watch this video.

Every course in the lynda.com library contains free videos that let you assess the quality of our tutorials before you subscribe—just click on the blue links to watch them. Become a member to access all 104,141 instructional videos.

get started learn more

If you are already an active lynda.com member, please log in to access the lynda.com library.

Get access to all lynda.com videos

You are currently signed into your admin account, which doesn't let you view lynda.com videos. For full access to the lynda.com library, log in through iplogin.lynda.com, or sign in through your organization's portal. You may also request a user account by calling 1 1 (888) 335-9632 or emailing us at cs@lynda.com.

Get access to all lynda.com videos

You are currently signed into your admin account, which doesn't let you view lynda.com videos. For full access to the lynda.com library, log in through iplogin.lynda.com, or sign in through your organization's portal. You may also request a user account by calling 1 1 (888) 335-9632 or emailing us at cs@lynda.com.

Access to lynda.com videos

Your organization has a limited access membership to the lynda.com library that allows access to only a specific, limited selection of courses.

You don't have access to this video.

You're logged in as an account administrator, but your membership is not active.

Contact a Training Solutions Advisor at 1 (888) 335-9632.

How to access this video.

If this course is one of your five classes, then your class currently isn't in session.

If you want to watch this video and it is not part of your class, upgrade your membership for unlimited access to the full library of 2,025 courses anytime, anywhere.

learn more upgrade

You can always watch the free content included in every course.

Questions? Call Customer Service at 1 1 (888) 335-9632 or email cs@lynda.com.

You don't have access to this video.

You're logged in as an account administrator, but your membership is no longer active. You can still access reports and account information.

To reactivate your account, contact a Training Solutions Advisor at 1 1 (888) 335-9632.

Need help accessing this video?

You can't access this video from your master administrator account.

Call Customer Service at 1 1 (888) 335-9632 or email cs@lynda.com for help accessing this video.

preview image of new course page

Try our new course pages

Explore our redesigned course pages, and tell us about your experience.

If you want to switch back to the old view, change your site preferences from the my account menu.

Try the new pages No, thanks

site feedback

Thanks for signing up.

We’ll send you a confirmation email shortly.


By signing up, you’ll receive about four emails per month, including

We’ll only use your email address to send you these mailings.

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

By signing up, you’ll receive about four emails per month, including

We’ll only use your email address to send you these mailings.

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked