150 likes | 306 Views
LSP 120. Creating Graphs. The Graphs We Will Use. Pie graphs Bar / column graphs Line graphs XY scatter graphs. But…. Each graph works best in a particular situation You need to decide which is best
E N D
LSP 120 Creating Graphs
The Graphs We Will Use • Pie graphs • Bar / column graphs • Line graphs • XY scatter graphs
But… • Each graph works best in a particular situation • You need to decide which is best • Some will work, some won’t work, there is usually one really good choice, there are often some really bad choices • Let’s look at each graph choice
Pie Charts • You must have all the data in order to use a pie chart • For example, if you are graphing choices of cookies, and the only data you have is: • Oreo 235 million units sold • Chips Ahoy 211 million units sold • Lorna Doone 145 million units sold
Pie Charts • Don’t make a pie chart like this: • What is wrong with this graph?
Pie Graphs • Secondly, make sure the data does not overlap • Consider the following data: • DSL users 26% • Cable modem users 19% • Dial up users 32% • None 23% • Total 100%
Pie Graphs • Note: there is no title on this graph
Pie Graphs • Finally, don’t make a pie with too many slices Look at EnergyConsumption.xls
Bar / Column Charts • Bar / column charts are good when you want to show “amounts” or “levels” of something • For example, four different cities each have a value for the number of traffic accidents: • Chicago 3211 accidents • Detroit 2210 accidents • St. Louis 1349 accidents • Fort Wayne 832 accidents
Bar / Column Charts Look at HomeHeating.xls
XY Scatter Graphs / Line Graphs • These graphs are best at showing how one type of data input changes one output • For example, how as time changes, the sales have gone up • Or, as a person’s height increases, so does their weight • Or, as you drink more drinks, the more drunk you will get
XY Scatter Graphs / Line Graphs • Be careful: A line graph will not treat the first column as X-axis labels; it will treat it as a series of data • Look at Headstart Per Child.xls
Describing Graphs • You should know how to “describe” a graph • Is the graph/data increasing? Decreasing? Flat? Cyclic or periodic? • What is the global or absolute maximum? Minimum? • What is a local or relative maximum? Minimum?
Faulty Graphs • Let’s look at some “faulty” graphs • http://qrc.depaul.edu/djabon/gallery.htm