 Hi this is Dr. Don. I want to take a few minutes and work through a problem out of my stat lab where we're required to create some histograms. We're given raw data, a data table, and then we're asked to create three histograms with five, 10, and 20 classes. Now I'm going to walk you through step by step showing you both stat crunch and also excel. Well let me show you this just so you'll see where I get this to save a bit of time. Here are the right answers for the five class histogram. You can see it's pretty straightforward. I'm going to grab a screenshot of these and I'll compare these to what we do with excel and stat crunch in a minute. Down here when we're looking for the 10 classes is this one. Pop that out and we've got some ups and downs there on that one and then on 20 I'll pop this one up and it looks even more funky. We've got a lot of bins there but some white space. So I'm going to grab screenshots of those so we can compare them as we go through stat crunch and excel. Now remember when you're in my stat lab you've got this little blue rectangle there. You can click on it and you can open up that data table in stat crunch or excel or you can copy to a clipboard if you've got some other software you're using. I'm going to open it both in excel and in stat crunch. I like to use excel to do the preliminary calculations. Now you can do this with a hand calculator if you want but I just prefer to use excel. You know if you follow me I use excel and stat crunch interchangeably to get the best of both worlds. So we're going to jump over here to excel. So here's the data once I open it in excel it puts it in column A and in order to get the information you need you need to get the max value the min value and the range and you can just do that with excel functions the max function the min function and then just attract those two values to get the range. Once you get the range we divide that by the number of classes. So if we divide 14 by 5 we get 2.8 and then 1.4 and 0.7 for each of the other two. But remember when we're making histograms in particular with my stat lab and stat crunch we always want to round up to the next integer value. So I use the roundup function there to give me 3, 2, 1 for 5, 10 and 20. So let's jump back to stat crunch. So I'm in stat crunch there's my data and the first column which it is called variable 1. To get the histogram we're going to go to graph and then go down to histogram and we get a dialog box we've got to tell us which column has our data variable one click on that and what we need for this particular problem we just need to pay attention to this part here which says it's about the bins it defaults to the frequency distribution which is what we want for this histogram. So we've got to start the bin somewhere it's important again in stat crunch and my stat lab that you start with your minimum value which would be one and then we're going to set the width here for the first option five classes and the width is three for this first option. So we just click compute and here we've got our basic histogram and I'm going to expand this just a little bit you can see comparing it to the correct answer for five classes it looks pretty pretty close the only difference here is that the x-axis starts at zero ours is one we can fix that by going to x-axis and we're just going to start that at zero and click okay. Now you can see the charts are identical here this is at seven and this upper one here is above 15 but not to 16 and so that looks pretty good. One final thing I want to show you because it's critical when we do this in Excel is to understand how stat crunch creates histograms. Notice here when I hover over the first bin it gives me the frequency the number seven and it also tells me down here where it says variable one column and it says it's one and four if you notice one has a left excuse a left bracket by it and that's called a closed symbol so that means it includes one in that particular bin the four has a parentheses that's an open symbol which means four is not in this first bin it's over here in the second bin now you can see four has the closed bracket by it so it says four is in this bin seven is not and then seven is in the third bin ten is not so four ten is in the fourth bin 13 is not and 13 is in the last bin so that's going to be important when we get over to excel now to create the next portion we're going to go to options edit and all we need to do is change this width from three to two which is our next histogram and there we get that histogram we could change the x-axis again I'm going to go ahead and bring up the the same basic form is there again you can set that to zero and then finally I will edit it and go to one for the 20 you can see again it matches that we've got the same pattern here so you can get the right answer so now we're going to do this second part and the next video which I have a link to below