Descriptive Statistics Frequency & Contingency Tables

Slides:



Advertisements
Similar presentations
R Language. What is R? Variables in R Summary of data Box plot Histogram Using Help in R.
Advertisements

Project Maths - Teaching and Learning Relative Frequency % Bar Chart to Relative Frequency Bar Chart What is the median height.
Statistics 1: Introduction to Probability and Statistics Section 3-3.
Chapter 10: Sampling and Sampling Distributions
Lecture 4 Chapter 2. Numerical descriptors
Statistics for Decision Making Descriptive Statistics QM Fall 2003 Instructor: John Seydel, Ph.D.
QM Spring 2002 Statistics for Decision Making Descriptive Statistics.
Statistics Intro Univariate Analysis Central Tendency Dispersion.
Statistical Evaluation of Data
1. Statistics 2. Frequency Table 3. Graphical Representations  Bar Chart, Pie Chart, and Histogram 4. Median and Quartiles 5. Box Plots 6. Interquartile.
1 Introduction to biostatistics Lecture plan 1. Basics 2. Variable types 3. Descriptive statistics: Categorical data Categorical data Numerical data Numerical.
Statistics: Unlocking the Power of Data Lock 5 1 in 8 women (12.5%) of women get breast cancer, so P(breast cancer if female) = in 800 (0.125%)
Research Methods: 2 M.Sc. Physiotherapy/Podiatry/Pain Descriptive statistics.
Mean, Median, and Mode An Introduction to Data Management: Measures of Central Tendencies.
4.4 Measures of Central Tendency Le sson Essential Question: How can I use statistics to describe a particular set of data? Objectives ~ Find the mean,
Statistics for Decision Making Bivariate Descriptive Statistics QM Fall 2003 Instructor: John Seydel, Ph.D.
DAY 3 14 Jan Today is A.January 14, 2014 B.January 13, 2013.
Chapter 3 Descriptive Measures
Determination of Sample Size: A Review of Statistical Theory
Sampling in Research Suter, Chapter 8. Questions about sampling Sample size – do I have enough participants? Is it the right kind of sample? Is it representative?
Univariate EDA. Quantitative Univariate EDASlide #2 Exploratory Data Analysis Univariate EDA – Describe the distribution –Distribution is concerned with.
Statistical Analysis Quantitative research is first and foremost a logical rather than a mathematical (i.e., statistical) operation Statistics represent.
Statistics 1: Introduction to Probability and Statistics Section 3-2.
Copyright © 2011 Pearson Education, Inc. Putting Statistics to Work.
(7.12) Probability and statistics The student uses measures of central tendency and range to describe a set of data. The student is expected to: (A) describe.
Copyright © 2010 Pearson Education, Inc. Publishing as Prentice Hall2(2)-1 Chapter 2: Displaying and Summarizing Data Part 2: Descriptive Statistics.
Univariate EDA. Quantitative Univariate EDASlide #2 Exploratory Data Analysis Univariate EDA – Describe the distribution –Distribution is concerned with.
1 Chapter 10: Describing the Data Science is facts; just as houses are made of stones, so is science made of facts; but a pile of stones is not a house.
DESCRIPTIVE STATISTICS Artur Wasiak. Table of contents definitions definitions Why do we use descriptive statistics? Why do we use descriptive statistics?
Descriptive Statistics Research Writing Aiden Yeh, PhD.
Confidence Intervals for a Population Proportion Excel.
Chapter 2 Descriptive Statistics 2.1 Frequency Distributions and Their Graphs.
R tutorial Stat 140 Linjuan Qian
Measures of Variation. Range, Variance, & Standard Deviation.
Descriptive Statistics using R. Summary Commands An essential starting point with any set of data is to get an overview of what you are dealing with You.
Chapter 1 Review. Why Statistics? The Birth of Statistics Began in the 17th Century System to combine probabilities with Bayesian inference Important.
AP Statistics. Chapter 1 Think – Where are you going, and why? Show – Calculate and display. Tell – What have you learned? Without this step, you’re never.
Exploratory Data Analysis
Applied Business Forecasting and Regression Analysis
Statistical Measures M M O D E E A D N I A R A N G E.
Microsoft Visual Basic 2005: Reloaded Second Edition
Samples & Populations 1.1 pt. 2
2-Way Tables, Statistics, & Probability
Univariate Descriptive Statistics
Part Three. Data Analysis
Chapter 14 Quantitative Data Analysis
Numerical Descriptives in R
Visual Basic .NET BASICS
Central Tendency.
Recoding II: Numerical & Graphical Descriptives
Relations in Categorical Data
Part III: Designing Psychological Research
Contingency Tables and Association
Treat everyone with sincerity,
Sampling Distributions
Statistics 1: Introduction to Probability and Statistics
Producing Descriptive Statistics
Chapter 1: Exploring Data
Samples & Populations 1.1 pt. 2
Probability and Statistics for Engineers
Advanced data management
Ticket in the Door GA Milestone Practice Test
R-lab 2 -Dorji Pelzom.
LINQ to SQL Part 3.
Lecture 4 Psyc 300A.
Finding Statistics from Data
Finding Statistics from a frequency table
Finding Statistics from a Grouped frequency table
Math 10, Spring 2019 Introductory Statistics
Descriptive Statistics Civil and Environmental Engineering Dept.
Presentation transcript:

Descriptive Statistics Frequency & Contingency Tables chapter 7 Descriptive Statistics Frequency & Contingency Tables Instructor: Huang, Jia-Ping

Contents Descriptive statistics Tables

Descriptive statistics The summary() function

Descriptive statistics The summary() does not provide enough information to understand a sample of data. Use a combination of sapply() and functions like mean(), sd(), var(), min(), max(), median(), length(), range(), quantile(), etc., to produce the statistics you need.

sapply() apply() applies a function over the margins of an array sapply() applies a function over a list or vector.

> mydata <- data.frame(x = rnorm(20, 2, 1), y = rnorm(20, 3, 2)) > apply(mydata, 2, sd) x y 0.9729847 1.6987539 > sapply(mydata, sd)

Other useful functions describe() in the Hmics package stat.desc() in the pastecs package describe() in the psych package

The aggregate() function We can divide our data set into groups and produce descriptive statistics for each group. This can be done by using the aggregate() function.

The by() function aggregate() only allows you to use single-value functions such as mean(). With by(), you can return several statistics at once.

Tables R provides several methods for creating frequency and contingency tables.

One-way tables table() prop.table()

Two-way tables

Take row/column sums The index 1 refers to the first variable in the table() statement.

Proportions of the overall sum

Add marginal sums

Summary Descriptive statistics is the first step of statistical analysis. Creating frequency/contingency tables is a useful way of data visualization. Important functions: summary(), sapply(), aggregate(), by(), table(), prop.table()