Exam Review

Introduction

• What is Data Science?- an interdisciplinary field that uses scientific methods, algorithms, and systems to extract knowledge and insights from structured and unstructured data

• Exploration - the purposeful act of traveling to, searching through, or investigating unknown regions, subjects, or data to gain knowledge, resources, or understanding.

• Inference - the logical process of reaching a conclusion, opinion, or judgment based on known facts, evidence, or reasoning

• Prediction - a statement or forecast about what will happen in the future, often based on data, evidence, or scientific reasoning.

• Communication

• Computer Science, Statistics, Mathematics


Cause and Effect

• Response variables, explanatory variables - Response variable is the primary variable of interest. Explanatory variable is a variable that (hopefully) can be used to predict the response.

• Experiments and observational studies

• Confounding variables

• Interacting variables - changes the effect of the explanatory variable on the response variable. Unlike a confounder, interaction means the effect differs by subgroup


Data types

• numeric (floating point) - (10.5, 55, 787)

• integer - (1L, 55L, 100L, where the letter "L" declares this as

an integer)

• complex - (9 + 3i, where "i" is the imaginary part)

• character (string) - ("k", "R is exciting", "FALSE", "11.5")

• logical (boolean) - (TRUE or FALSE)

• factor (categorical data) – (possibilities vary)


Types of relationships

• Cause and effect

• Linear relationships

• Correlation - A measure of the strength and direction of the linear relationship between two measurement variables.


Data visualization

• Graphs

• Plots

• Pictures


Probability and randomness

• Basic rules of probability: Unions, Intersections,


Complements

• Independent events

• Mutually exclusive events


Random variables

• Continuous vs. Discrete

• Uniform (most commonly Uniform(0,1))

• Normal Distribution

• Standard normal (converted to z): Mean = 0, std. dev. = 1


Cumulative Distribution Function

• For a random variable X, the P(X ≤ a) = CDF(a)

• Inverse CDF: If P(X ≤ a) = p then INVCDF(p) = a .

• For continuous RV, P(X = a) = 0 implies


CDF(a) = P(X ≤ a) = P(X < a)

• Normal CDF in R: pnorm()

• Normal INVCDF in R: qnorm()

• By default, pnorm() and qnorm() assume standard normal


Empirical Distribution - a probability distribution derived from observed data, rather than a theoretical model

Population vs. Sample

• Parameters vs. Statistics - parameters = population, statistics = sample, statistics used as a sample for parameters


X in normal, mean = 100, STD = 10

P(X>115)=?:

Z score = (115-100)/10 = 1.5

P(X>115)= 1-pnorm(1.5)