0% found this document useful (0 votes)
2 views27 pages

Unit 3 R - SEP

Sep r program 2nd sem

Uploaded by

s12764451
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views27 pages

Unit 3 R - SEP

Sep r program 2nd sem

Uploaded by

s12764451
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Statistics and Probability

Statistics

Statistics is a field that focuses on gathering, analyzing, interpreting, presenting, and organizing data. Simply
put, it involves using mathematical methods to collect and summarize information effectively.

“Statistics is a scientific discipline that involved the collection, analysis, and interpretation of data”

Basics of Statistics

Statistics is built on two key concepts: measures of central tendency and measures of dispersion. Central tendencies
include mean, median, and mode, while dispersions cover variance and standard deviation.

Mean : The mean is the average value of all observations in a dataset.

Median : The median is the middle value when the data is arranged in ascending or descending order.

Mode : The mode represents the most frequently occurring value in a dataset.

Dispersion helps to understand how data points are spread out.

• Variance : It quantifies how far each data point is from the mean.

• Standard Deviation : It measures the degree of variation or dispersion of data around the mean.

Types of statistics

Statistics can be broadly classified into two main types:

Descriptive Statistics

Descriptive statistics focus on summarizing and presenting data in a clear and organized way. It involves
describing a dataset through measures like the mean, median, mode, and standard deviation. Charts, graphs,
and tables, such as histograms, pie charts, bar graphs, and scatter plots, are commonly used to visually
represent the data.

Inferential Statistics

Inferential statistics go a step further by interpreting the data summarized in descriptive statistics to draw
meaningful conclusions. Using principles of probability, this type helps determine whether patterns and results
observed in a sample can be applied to the larger population it represents. In short, inferential statistics
transform raw data into actionable insights about broader populations.

Applications of Statistics

Statistics plays a crucial role in Chartered Accountancy (CA) by providing valuable insights for financial analysis,
decision-making, and auditing. Here are some key applications:

• Financial Analysis : CA professionals use statistical tools to analyze financial data, identify trends, and
forecast future performance, helping businesses make informed financial decisions.

• Risk Assessment : Statistics helps in evaluating financial risks and uncertainties, allowing CAs to suggest
strategies for risk mitigation.

• Auditing : Statistical sampling techniques are widely used in audits to select representative samples and
ensure that financial statements are accurate and compliant with regulations.

• Tax Planning : Statistical models assist in predicting tax liabilities and optimizing tax strategies for individuals
and businesses.

• Budgeting and Forecasting : CAs use statistical methods to develop accurate budgets and financial forecasts,
aiding in effective financial planning.
Characteristics of statistics

• It is numerically expressed
• It has an aggregate of facts
• Data are collected in systematic order
• It should be comparable to each other
• Data are collected for a planned purpose

Frequency Distribution

A frequency distribution is a method for organizing data and determining how often each value occurs.

• It shows how many times each value or range of values occurs in a dataset.

• Instead of examining raw, scattered numbers, this approach presents data in a structured table or graph,
making patterns, trends, and comparisons easy to identify.

Types of Data in Statistics with Examples

Statistics data is mainly divided into Qualitative Data and Quantitative Data.

1. Qualitative Data (Categorical Data)

This type of data describes qualities, names, or categories.


It cannot be measured using numbers directly.

A) Nominal Data

Data is grouped into categories without any order.

Examples:

• Gender → Male, Female

B) Ordinal Data

Data is categorized with a meaningful order or ranking.

Examples:

• Class Rank → 1st, 2nd, 3rd

2. Quantitative Data (Numerical Data)

This type of data is represented using numbers.

A) Discrete Data

Countable data, usually whole numbers.

Examples:

• Number of students in a class

B) Continuous Data

Measurable data that can take any value within a range.

Examples:

• Height → 165.5 cm

Discrete Data in Statistics


Discrete data is a type of quantitative data that consists of countable values.
It usually takes whole numbers and cannot have fractions or decimal values in most cases.

Definition

Discrete data refers to data that can be counted individually and has separate distinct values.

Characteristics of Discrete Data

• Countable values

• Usually whole numbers

• Finite or countably infinite

• Gaps exist between values

• Obtained by counting

Arithmetic Mean

Measures of Central Tendency

Measures of Central Tendency

Mean · Median · Mode — Definition, Formulas, Examples & Comparisons | UG Level Notes

What is Central Tendency?

A measure of central tendency is a single value that attempts to describe a dataset by identifying the central position
within it. It is the most representative value of the entire distribution — the value around which all other data points
cluster.

Think of it as the "anchor" of a dataset. If you had to summarise 1000 data points with just one number, that number
would be a measure of central tendency.

Why we need it

To summarise large data sets into one representative value for comparison and decision-making.

Three main measures

Mean (arithmetic average), Median (middle value), Mode (most frequent value).

Arithmetic Mean

The Arithmetic Mean (or simply "mean") is the sum of all values divided by the number of values. It is the most
widely used measure of central tendency.

Formula — Ungrouped data

x̄ = (x₁ + x₂ + ... + xₙ) / n = Σx / n

x̄ = mean | Σx = sum of all values | n = number of observations

Formula — Frequency distribution

x̄ = Σfx / Σf (discrete) | x̄ = Σfm / Σf (continuous, m = midpoint)

Properties of Arithmetic Mean


Property 1

Sum of deviations from mean is always zero: Σ(x − x̄) = 0

Property 2

Mean is affected by every value — one extreme value changes the mean significantly.

Property 3

Mean of combined groups: x̄c = (n₁x̄₁ + n₂x̄₂) / (n₁ + n₂)

Property 4

Algebraically tractable — you can compute total from mean: Σx = n × x̄

Example 1 — Simple mean

Marks of 8 students: 45, 60, 55, 70, 40, 65, 50, 75. Find the mean.

Σx = 45+60+55+70+40+65+50+75 = 460
n=8
x̄ = 460 / 8 = 57.5 marks

Example 2 — Effect of outlier on mean

Salaries (₹ thousands): 10, 12, 11, 13, 10, 100 (CEO). See how the CEO salary distorts the mean.

Without CEO: Mean = (10+12+11+13+10)/5 = 11.2


With CEO: Mean = (10+12+11+13+10+100)/6 = 26.0

The mean jumped from 11.2 to 26.0 — not representative of the 5 regular employees. This is why median is
better for skewed data.

Median

The Median is the middle value when data is arranged in ascending or descending order. It divides the data into two
equal halves. It is not affected by extreme values (outliers).

Formula — Ungrouped (odd n)

Median = value of the ((n+1)/2)th term

Formula — Ungrouped (even n)

Median = average of (n/2)th and (n/2+1)th terms

Formula — Grouped continuous data

Median = L + [(N/2 − cf) / f] × h

L = lower limit of median class | cf = cumulative frequency before median class


f = frequency of median class | h = class width

Properties of Median

Property 1

Not affected by extreme values (outliers) — best for skewed distributions.

Property 2

Can be determined graphically using the Less-than Ogive curve.


Property 3

For open-ended class intervals, median can still be calculated (unlike mean).

Property 4

Median = Q₂ = 50th percentile. Always.

Example 3 — Median (same salary data)

Salaries: 10, 12, 11, 13, 10, 100 → Arranged: 10, 10, 11, 12, 13, 100. n = 6 (even).

Median = (3rd + 4th term) / 2 = (11 + 12) / 2 = 11.5

Median = 11.5 — completely unaffected by the CEO's salary of 100. Much more representative here.

Mode

The Mode is the value that appears most frequently in the dataset. A distribution can be unimodal (one mode),
bimodal (two modes), or multimodal. It is the only measure that can be used for qualitative (non-numeric) data.

Formula — Grouped continuous data

Mode = L + [(f₁ − f₀) / (2f₁ − f₀ − f₂)] × h

L = lower limit of modal class (class with highest frequency)


f₁ = frequency of modal class | f₀ = frequency of class before | f₂ = frequency of class after | h = class width

Properties of Mode

Property 1

Not affected by extreme values. Can be used even for qualitative data.

Property 2

May not exist (if no value repeats) or may not be unique (bimodal/multimodal).

Property 3

Can be found graphically from a histogram (the tallest bar's midpoint).

Example 4 — Mode from discrete data

Shoe sizes sold in a shop: 7, 8, 9, 9, 10, 8, 9, 7, 9, 10, 8, 9

Size 7: appears 2 times


Size 8: appears 3 times
Size 9: appears 5 times ← highest
Size 10: appears 2 times
Mode = 9

Empirical Relationship — Mean, Median & Mode

For a moderately skewed distribution, Karl Pearson established a very useful empirical relationship that
connects all three measures. Examiners test this frequently.

Pearson's Empirical Formula

Mode = 3 × Median − 2 × Mean

Valid for moderately skewed distributions. Used to find one measure when the other two are known.
Rearrangements: Mean = (3×Median − Mode)/2 | Median = (Mode + 2×Mean)/3
Example 5 — Using Pearson's formula

For a distribution: Mean = 50 and Median = 45. Find the Mode.

Mode = 3 × Median − 2 × Mean


Mode = 3 × 45 − 2 × 50
Mode = 135 − 100 = 35

Interactive Explorer — See all three on a chart

Edit the data values below (comma-separated) and watch Mean, Median and Mode update live on the chart.

Data values:Recalculate ↗

Mean

38.00

Median

40.00

Mode

40

Data frequencyMeanMedianMode

1. What is Arithmetic Mean?

The Arithmetic Mean (commonly called the "mean" or "average") is the most widely used measure of central
tendency. It is calculated by adding all the values in a dataset and dividing the sum by the total number of
values.

GENERAL FORMULA

Mean (x̄) = Σx / N

where Σx = sum of all values | N = total number of observations

2. Arithmetic Mean for Discrete Data

Discrete data consists of exact, countable values — for example, the number of students, marks scored,
number of items sold, etc. There is no continuity between values.

Method A — Direct MethodMethod B — Assumed Mean MethodMethod C — Step Deviation Method

Method A — Direct Method (Most Common)

FORMULA — DISCRETE (DIRECT)

x̄ = Σfx / Σf

where f = frequency | x = value | fx = product of frequency and value

Example 1 — Marks of 30 students

The following table shows the marks obtained by students. Find the Arithmetic Mean.
Marks (x) Frequency (f) Fx

10 2 20

20 4 80

30 8 240

40 10 400

50 6 300

Total Σf = 30 Σfx = 1040

SOLUTION

x̄ = 1040 / 30 = 34.67 marks

STEP 1

Multiply each value x by its frequency f to get fx

STEP 2

Add all fx values to get Σfx = 1040

STEP 3

Add all frequencies: Σf = 30

STEP 4

Divide Σfx by Σf → Mean = 34.67

3. Arithmetic Mean for Continuous Data

Continuous data is grouped into class intervals (e.g. 0–10, 10–20, …). Since we don't know the exact values, we use
the mid-point (m) of each class as a representative value.

MID-POINT FORMULA

m = (Lower class limit + Upper class limit) / 2

Method A — Direct MethodMethod B — Assumed Mean MethodMethod C — Step Deviation Method

Method A — Direct Method

FORMULA — CONTINUOUS (DIRECT)

x̄ = Σfm / Σf

m = mid-point of each class interval | f = frequency of that class

Example 3 — Wages of 50 workers

The following frequency distribution shows daily wages. Find the mean wage.
Wages (₹) Frequency (f) Mid-point (m) fm

100 – 120 5 110 550

120 – 140 10 130 1300

140 – 160 18 150 2700

160 – 180 12 170 2040

180 – 200 5 190 950

Total Σf = 50 — Σfm = 7540

SOLUTION

x̄ = 7540 / 50 = ₹150.80

STEP 1

Find mid-point m of each class: (L + U) / 2

STEP 2

Multiply m by frequency f to get fm

STEP 3

Sum up: Σfm = 7540, Σf = 50

STEP 4

Mean = 7540 ÷ 50 = 150.80

4. Key Differences at a Glance

Feature Discrete Data Continuous Data

Nature of data Exact, countable values Grouped in class intervals

Representative value used Actual value (x) Mid-point of class (m)

Formula x̄ = Σfx / Σf x̄ = Σfm / Σf

Example Marks, no. of items sold Wages, height, weight

Median

The Median is the middle value of a dataset when arranged in ascending or descending order. It divides the
distribution into two equal halves — 50% of values lie below it and 50% above it.

It is not affected by extreme values (outliers), making it more reliable than the mean for skewed data.
Median for Discrete Data (ungrouped)

Formula — odd n

Median = value of ((N+1)/2)th term

After arranging data in ascending order

Formula — even n

Median = (N/2 th term + (N/2 + 1)th term) / 2

Example 1 — Ungrouped discrete data

Marks of 7 students: 42, 55, 18, 70, 35, 60, 28. Find the median.

Step 1

Arrange in ascending order: 18, 28, 35, 42, 55, 60, 70

Step 2

N = 7 (odd). Median position = (7+1)/2 = 4th term

Step 3

4th term = 42

18·28·35·42 ← Median·55·60·70

Median

42 marks

A2 — Median for Discrete Frequency Distribution

Steps

1. Find cumulative frequency (cf)


2. Find N/2
3. Locate the cf just greater than N/2 → that is the Median class value

Example 2 — Discrete frequency distribution

Find the median for the following data (N = 30, so N/2 = 15).

Marks (x) Frequency (f) Cumulative Freq (cf)

10 3 3

20 5 8

30 8 16

40 9 25 ← cf just > 15

50 5 30

Total 30 —
Median

Median = 40 marks (cf just > N/2 = 15 is 16, corresponding to x = 30... wait: cf at x=30 is 16 > 15, so Median = 30)

Correction: cf just greater than 15 is 16, at x = 30. So Median = 30 marks.

A3 — Median for Continuous Data (Grouped)

Interpolation Formula

Median = L + [(N/2 − cf) / f] × h

L = lower boundary of median class | cf = cumulative frequency before median class | f = frequency of median
class | h = class width

Example 3 — Continuous frequency distribution

Wages of 50 workers. Find the median. (N = 50, N/2 = 25)

Wages (₹) F cf

100–120 5 5

120–140 10 15

140–160 ← Median class 18 33

160–180 12 45

180–200 5 50

Total 50 —

140 (lower limit of median class)

cf

15 (cumulative frequency before median class)

18 (frequency of median class)

20 (class width)

Solution

Median = 140 + [(25−15)/18] × 20 = 140 + (10/18)×20 = 140 + 11.11 = ₹151.11

Quartiles

Quartiles divide the distribution into four equal parts. There are three quartiles:

Q₁ — First Quartile
Lower quartile. 25% of data lies below Q₁. Also called the 25th percentile.

Q₂ — Second Quartile

This is the Median. 50% of data lies below Q₂. = 50th percentile.

Q₃ — Third Quartile

Upper quartile. 75% of data lies below Q₃. Also called the 75th percentile.

B1 — Quartile Formulas for Continuous Data

Q₁ — First Quartile

Q₁ = L + [(N/4 − cf) / f] × h

Locate the class where cf just exceeds N/4

Q₃ — Third Quartile

Q₃ = L + [(3N/4 − cf) / f] × h

Locate the class where cf just exceeds 3N/4

Example 4 — Quartiles for the wages data

Using the same wages table (N = 50). Find Q₁ and Q₃.

Wages (₹) F cf

100–120 5 5

120–140 ← Q₁ class 10 15

140–160 18 33

160–180 ← Q₃ class 12 45

180–200 5 50

For Q₁: N/4 = 50/4 = 12.5 → cf just > 12.5 is 15, so Q₁ class = 120–140. L=120, cf=5, f=10, h=20

Q₁

Q₁ = 120 + [(12.5−5)/10] × 20 = 120 + 15 = ₹135

For Q₃: 3N/4 = 37.5 → cf just > 37.5 is 45, so Q₃ class = 160–180. L=160, cf=33, f=12, h=20

Q₃

Q₃ = 160 + [(37.5−33)/12] × 20 = 160 + 7.5 = ₹167.50

B2 — Interquartile Range (IQR) & Quartile Deviation

Important Derived Measures

IQR = Q₃ − Q₁
Quartile Deviation (QD) = (Q₃ − Q₁) / 2
Coefficient of QD = (Q₃ − Q₁) / (Q₃ + Q₁)

IQR covers the middle 50% of the data. QD is also called the Semi-Interquartile Range.
From Example 4

IQR = 167.50 − 135 = ₹32.50 | QD = 32.50/2 = ₹16.25

Mode

The Mode is the value that appears most frequently in a dataset. A distribution can have one mode (unimodal), two
modes (bimodal), or more (multimodal).

It is the only measure of central tendency that can be used for qualitative (non-numeric) data such as the most popular
colour or brand.

C1 — Mode for Discrete Data

Simply identify the value with the highest frequency.

Example 5 — Mode from frequency table

Shoe Size 7 8 9 10 11

Frequency 4 9 14 8 3

Mode

Mode = Size 9 (highest frequency = 14)

C2 — Mode for Continuous Data (Grouped)

First identify the modal class — the class with the highest frequency. Then apply the interpolation formula.

Formula — Continuous data

Mode = L + [f₁ − f₀ / (2f₁ − f₀ − f₂)] × h

L = lower boundary of modal class | f₁ = frequency of modal class


f₀ = frequency of class before modal class | f₂ = frequency of class after modal class | h = class width

Example 6 — Mode for wages data

Using the same wages distribution. Identify the modal class and find Mode.

Wages (₹) Frequency (f)

100–120 5 = f₀

140–160 ← Modal class (highest f) 18 = f₁

160–180 12 = f₂

120–140 10

180–200 5

Modal class = 140–160 (f = 18, highest). L = 140, f₁ = 18, f₀ = 10, f₂ = 12, h = 20

Numerator
f₁ − f₀ = 18 − 10 = 8

Denominator

2f₁ − f₀ − f₂ = 36 − 10 − 12 = 14

Fraction × h

(8/14) × 20 = 11.43

Mode

Mode = 140 + 11.43 = ₹151.43

Quick comparison of all three

Feature Median Quartiles Mode

Divides data into 2 equal halves 4 equal parts — (most frequent)

Affected by outliers? No No No

Best used for Skewed distributions Spread & dispersion Categorical/nominal data

Formula involves N/2 N/4, 3N/4 Highest frequency

Can be located graphically? Yes — Ogive Yes — Ogive Yes — Histogram

Advantages of Mode

• Easy to understand

• Not affected by extreme values

• Useful for categorical data

• Represents most common observation

Disadvantages of Mode

• May not exist in some datasets

• Multiple modes may occur

• Not based on all observations

Real-Life Applications

• Most common shoe size

• Most popular product

• Frequently occurring marks

• Market demand analysis

Probability
Probability is the mathematical measure of how likely an event is to occur, ranging from (0) (impossible) to (1)
(certain). In statistics, it provides the theoretical foundation for predicting data behavior, evaluating risks, and
generalizing findings from a sample to an entire population. [1, 2, 3, 4]

Key concepts of probability in statistics include:

1. The Core Formula

The probability of an event (P(E)) is mathematically defined as the ratio of favorable outcomes to the total possible
outcomes within a given sample space:
P(E)= {Number of Favorable Outcomes}/{Total Number of Possible Outcomes}

• (0): The event is impossible.

• (1): The event is absolutely certain to happen.

• Example: The probability of rolling an even number on a standard 6-sided die is (frac{3}{6}) (or (0.5)),
because there are 3 even numbers (2, 4, 6) out of 6 total possible outcomes. [1, 2]

[Link] Probability

• Concept: Based on mathematics and logic, assuming all outcomes in a sample space are equally likely to
happen. It relies solely on reasoning rather than experimentation.

• Formula: \(P(A) = \frac{\text{Number of favorable outcomes}}{\text{Total number of possible outcomes}}\)

• Example: Rolling a standard six-sided die. The probability of rolling a \(4\) is \(P(4) = \frac{1}{6}\) because
there is \(1\) favorable outcome and \(6\) possible outcomes in total. [1, 2, 3, 4, 5]

2. Empirical (Experimental) Probability

• Concept: Based on actual observations, experiments, or historical data rather than theoretical logic. It
calculates the likelihood of an event by dividing the number of times the event occurred by the total number of
trials.

• Formula: \(P(A) = \frac{\text{Number of times event A occurs}}{\text{Total number of trials}}\)

• Example: A basketball player shoots \(100\) free throws and makes \(75\) of them. The empirical probability
of them making the next free throw is \(\frac{75}{100} = 0.75\) (or \(75\%\)). [1, 2, 3, 4, 5]

3. Subjective Probability

• Concept: Based on personal judgment, experience, intuition, or an educated guess. There are no formal
calculations or past data; it is simply a reflection of an individual's belief about an event.

• Example: A meteorologist predicts there is a \(20\%\) chance of rain tomorrow, based on their expertise and
current weather patterns. [1]

4. Axiomatic Probability

• Concept: A formalized, rigorous approach that uses a set of foundational rules (axioms) to assign probabilities.
It serves as the mathematical foundation for advanced statistics.

• Rules:

1. The probability of any event is between \(0\) and \(1\) (\(0 \le P(A) \le 1\)).

2. The sum of probabilities of all possible outcomes equals \(1\).

• Example: The probability of flipping a coin and getting heads \(P(H) = 0.5\), and getting tails \(P(T) = 0.5\).
Axiomatically, \(P(H) + P(T) = 0.5 + 0.5 = 1.0\).

Conditional Probability and Bayes' Theorem


Conditional Probability is the probability of an event A occurring, given that another event B has already occurred.
Given by:
𝑃(𝐴 ∩ 𝐵)
𝑃(𝐴 ∣ 𝐵) =
𝑃(𝐵)

• P(A∣B) = Probability of A given B

• P(A∩B) = Probability that both A and B will occur

• P(B) = Probability of event B occurring.

Bayes' Theorem states that given P(B)>0, the probability of A given B is denoted by:
𝑃(𝐵 ∣ 𝐴) × 𝑃(𝐴)
𝑃(𝐴 ∣ 𝐵) =
𝑃(𝐵)

Application of Conditional Probability and Theorem in CS

• Naive Bayes Classifier/ Bayesian Classifiers

Application of Probability

• Weather forecasts
• Risk Assessments
• Dice Games, Card Games
• Stock Market Analysis
• Drug testing
• Genetics probabilities

Problems on Probability with solutions:


Example 1: A coin is thrown 3 times .what is the probability that atleast one head is obtained?
Sol: Sample space = [HHH, HHT, HTH, THH, TTH, THT, HTT, TTT]
Total number of ways = 2 × 2 × 2 = 8. Fav. Cases = 7
P (A) = 7/8

Example 2: Find the probability of getting a numbered card when a card is drawn from the pack of 52 cards.
Sol: Total Cards = 52. Numbered Cards = (2, 3, 4, 5, 6, 7, 8, 9, 10) 9 from each suit 4 × 9 = 36
P (E) = 36/52 = 9/13

What is a Random Variable?


A random variable is a variable that can take on many values. This is because there can be several outcomes of
a random occurrence. Thus, a random variable should not be confused with an algebraic variable. An algebraic
variable represents the value of an unknown quantity in an algebraic equation that can be calculated.

Types of Random variable


Random Variables can be divided into two broad categories depending upon the type of data available. These
are given as follows:
• Discrete random variable
• Continuous random variable
A probability mass function is used to describe a discrete random variable and a probability density function
describes a continuous random variable. The upcoming sections will cover these topics in detail.
Discrete Random Variable
A discrete random variable is a variable that can take on a finite number of distinct values. For example, the
number of children in a family can be represented using a discrete random variable. A probability
distribution is used to determine what values a random variable can take and how often does it take on these
values.

Continuous Random Variable


A random variable that can take on an infinite number of possible values is known as a continuous random
variable. Such a variable is defined over an interval of values rather than a specific value. An example of a
continuous random variable is the weight of a person.

Mathematical Expectation of random variable

1. Discrete Random Variables


For a discrete random variable(X) that can assume values (x_1, x_2, …., x_n) with probabilities (P(x_1),
P(x_2), \dots, P(x_n)\), the expectation is the sum of the products of each value and its probability:

For random variable X which assumes values x1, x2, x3,...xn with probability P(x1), P(x2), P(x3), ... P(xn)

Expectation of X is defined as,

E(x) = ∑ 𝑃 ( 𝑥 𝑖 ) 𝑥 𝑖 ∑P(x i )x i

Problem 1: Find the expected value of the outcome when a die is rolled.

Solution:

Consider X is a random variable that represents the value that comes when a die is rolled.

X = {1, 2, 3, 4, 5, 6}

Now, since the die is a fair die, the probability of getting each outcome is equal. That is 1 6 6 1

E(X) = ∑ 𝑥 𝑖 𝑃 ( 𝑋
𝑥 𝑖 ) ∑x i P(X=x i )

⇒ E(X) = P(X = 1)(1) + P(X = 2)(2) + P(X = 3)(3) + P(X = 4)(4) + P(X = 5)(5) + P(X = 6)(6)

⇒ E(X) = 1 6 ( 1 + 2 + 3 + 4 + 5 + 6 ) 6 1 (1+2+3+4+5+6)

⇒ E(X) = 3

[Link] Expectation of a Continuous Random Variable

The Mathematical Expectation or Expected Value of a continuous random variable represents the average or
mean value of the variable over a large number of observations.
It is denoted by:
E(X)
or
\mu

Definition
If (X) is a continuous random variable with probability density function (f(x)), then the mathematical
expectation is:
1
E(X)=∫0 𝑥. 2𝑥 𝑑𝑥

Conditions
For a valid probability density function:
1. Probability must be non-negative:
f(x)\geq0
2. Total probability must equal 1:

Properties of Expectation
1. Expectation of Constant
E(c)=c

2. Linearity Property
E(aX+b)=aE(X)+b

3. Sum of Expectations
E(X+Y)=E(X)+E(Y)

Probability Distribution

Definition
A probability distribution is a mathematical representation that specifies all possible values of a random
variable together with their corresponding probabilities.
It completely describes the probabilistic behavior of a random variable.

Formal Representation
If (X) is a random variable, then its probability distribution specifies:
P(X=x)
for every possible value of (x).

Characteristics of Probability Distribution


For any valid probability distribution:
1. Probabilities are Non-negative
P(X=x)\=0

2. Sum of Probabilities Equals 1


sum P(X=x)=1

Types of Probability Distributions


1. Discrete Probability Distribution
Used when the random variable takes finite or countable values.
Examples:
• Number of students
• Number of defective items
• Dice outcomes

2. Continuous Probability Distribution


Used when the random variable takes values from a continuous interval.
Examples:
• Height
• Weight
• Temperature
Continuous distributions are described using a Probability Density Function (PDF).

Probability Mass Function (PMF)

Definition
A Probability Mass Function (PMF) is a function that gives the probability that a discrete random variable is
exactly equal to a particular value.
If (X) is a discrete random variable, then:
P(X=x)=f(x)
where:
• (f(x)) is called the probability mass function.

Conditions for a Valid PMF


Condition 1: Non-negativity
For every value of (x):
f(x)\geq0

Condition 2: Total Probability Equals One


\sum f(x)=1

Example 1: Tossing a Coin Three Times


Suppose a fair coin is tossed three times.
Let:
X=\text{Number of Heads}

Step 1: Sample Space


[
S={HHH,HHT,HTH,THH,HTT,THT,TTH,TTT}
]
Total outcomes:
n(S)=8

Types of Probability

Theoretical, Empirical, Conditional, Joint & Axiomatic Approaches | UG Level Notes

Basic Terminology (must know)

Before studying types of probability, these terms must be clear:

Experiment

Any action with a well-defined set of outcomes. E.g. tossing a coin, rolling a die.

Sample Space (S)

The set of ALL possible outcomes. Tossing a coin: S = {H, T}

Event (E)

Any subset of the sample space. Getting a Head is event E = {H}.

Favourable outcomes

Outcomes that satisfy the condition of the event being considered.

Probability — General Definition

P(E) = Number of favourable outcomes / Total number of outcomes in S

Range: 0 ≤ P(E) ≤ 1 | P(impossible event) = 0 | P(certain event) = 1

Types of Probability

Type 1 Classical (Theoretical)

Based on equally likely outcomes. Known before the experiment.

Type 2 Empirical (Statistical)

Based on actual observations or past data. Relative frequency.

Type 3 Axiomatic

Based on mathematical axioms by Kolmogorov. Foundation of all modern probability.

Type 4 Conditional

Probability of an event given that another event has already occurred.

Type 5 Joint Probability

Probability that two events occur simultaneously.

Type 6 Subjective

Based on personal belief or judgement. Used in Bayesian reasoning.


Type 1 — Classical (Theoretical) Probability

Proposed by Pierre-Simon Laplace. This approach assumes that all outcomes of an experiment are equally
likely. It is known before the experiment is conducted — hence called "a priori" probability.

Formula

P(A) = n(A) / n(S)

n(A) = number of favourable outcomes for event A | n(S) = total outcomes in sample space

Example 1 — Rolling a fair die

Type 2 — Empirical (Statistical / Relative Frequency) Probability

Proposed by Von Mises. This approach is based on actual observations from a large number of experiments.
Probability is estimated from past data — hence called "a posteriori" probability.

Formula

P(A) = (Frequency of event A) / (Total number of trials)

P(A) = lim(n→∞) [f/n]

Type 3 — Axiomatic Probability (Kolmogorov's Approach)

Proposed by A. N. Kolmogorov in 1933. This is the most rigorous and mathematically complete approach. It
does not define what probability "is" — instead, it gives three axioms that any probability function must
satisfy.

The Three Axioms of Probability

Axiom 1: P(A) ≥ 0 (probability is non-negative)


Axiom 2: P(S) = 1 (probability of sample space = 1)
Axiom 3: P(A ∪ B) = P(A) + P(B), if A ∩ B = ∅ (addition rule for mutually exclusive events)

All other probability rules are derived from these three axioms.

Theorems derived from axioms:

Complement rule

P(A') = 1 − P(A)
where A' = complement of A

Impossible event

P(∅) = 0
Empty set has zero probability

Addition rule (general)

P(A∪B) = P(A) + P(B) − P(A∩B)

Type 4 — Conditional Probability

The probability of event A occurring given that event B has already occurred. The sample space is reduced
to B. This is one of the most important concepts in probability.

Formula

P(A | B) = P(A ∩ B) / P(B), provided P(B) ≠ 0


P(A|B) reads as "probability of A given B" | The sample space narrows down to B

Bayes' Theorem (Very Important for Exams)

Bayes' Theorem allows us to update the probability of a hypothesis based on new evidence. It connects
prior probability with conditional probability.

Bayes' Theorem

P(Aᵢ | B) = [P(Aᵢ) × P(B | Aᵢ)] / [Σ P(Aⱼ) × P(B | Aⱼ)]

P(Aᵢ) = Prior probability | P(B|Aᵢ) = Likelihood | P(Aᵢ|B) = Posterior probability

PMF & PDF (Probability Mass Function & Probability Density Function )

Why do we need PMF and PDF?

In probability theory, we want to describe how probability is distributed across the possible values of a
random variable. The tool we use depends on the type of random variable:

Discrete random variable

Takes countable values: 0, 1, 2, 3… Use PMF — assigns probability to each exact value.

Continuous random variable

Takes any value in a range. Use PDF — probability is the area under a curve, not a point.

Part A — Probability Mass Function (PMF)

A Probability Mass Function is defined for a discrete random variable X. It gives the probability that X
takes exactly a specific value x.

Definition

P(X = x) = f(x)

The PMF assigns a probability to every individual value that X can take.

Properties of PMF

Property 1 — Non-negativity

P(X = x) ≥ 0 for all x. Probability is never negative.

Property 2 — Summation

Σ P(X = x) = 1. All probabilities must add up to exactly 1.

Property 3 — Point probability

P(X = x) gives exact probability at that point.

Example 1 — Tossing two fair coins

Let X = number of Heads. Possible values: 0, 1, 2. Sample space: {TT, TH, HT, HH}
X (Heads) Outcomes P(X = x)

0 {TT} 1/4 = 0.25

1 {TH, HT} 2/4 = 0.50

2 {HH} 1/4 = 0.25

Total — Σ = 1.00 ✓

PMF graph — number of heads in two coin tosses

P(X = x)

Key observation from the PMF graph: Each bar is an isolated spike at a discrete point. There is NO bar
between x = 0 and x = 1 — because X cannot take fractional values like 0.5.

Example 2 — Binomial PMF (rolling a die 3 times)

X = number of times 6 appears when rolling a fair die 3 times. P(6) = 1/6, n = 3.

Binomial PMF

P(X = k) = C(n,k) × p^k × (1−p)^(n−k)

n = 3, p = 1/6, k = 0, 1, 2, 3

Values

P(0) = 0.579 | P(1) = 0.347 | P(2) = 0.069 | P(3) = 0.005 | Sum = 1.000 ✓

Part B — Probability Density Function (PDF)

A Probability Density Function is defined for a continuous random variable X. Because X can take infinitely
many values in a range, P(X = any exact value) = 0. Instead, probability is defined over an interval as the area under
the curve.

Definition

P(a ≤ X ≤ b) = ∫[a to b] f(x) dx

f(x) is the PDF. The probability is the AREA under f(x) between a and b — NOT the height at a point.

Properties of PDF

Property 1 — Non-negativity

f(x) ≥ 0 for all x. The curve never goes below zero.

Property 2 — Total area = 1

∫(−∞ to +∞) f(x) dx = 1. Total area under the entire curve equals 1.

Property 3 — Point probability = 0

P(X = exactly a) = 0. This is why we always use intervals.

Property 4 — Interval probability


P(a ≤ X ≤ b) = P(a < X < b). Endpoints don't matter.

Example 3 — Uniform Distribution PDF

X is uniformly distributed between 2 and 6. Find f(x) and P(3 ≤ X ≤ 5).

Uniform PDF

f(x) = 1/(b−a) = 1/(6−2) = 1/4 = 0.25, for 2 ≤ x ≤ 6


f(x) = 0, otherwise

P(3 ≤ X ≤ 5)

= Area of rectangle = width × height = (5−3) × 0.25 = 2 × 0.25 = 0.50

Example 4 — Normal Distribution PDF (most important)

The Normal distribution is the most important continuous distribution. Its PDF has the famous bell curve
shape.

Normal PDF formula

f(x) = (1 / σ√(2π)) × e^[−(x−μ)² / (2σ²)]

μ = mean (centre of curve) | σ = standard deviation (spread of curve)


Curve is symmetric around μ. Total area = 1.

PDF graph — normal distribution (interactive)

Mean (μ)0

Std dev (σ)1

f(x) — PDF curveShaded area = P(μ−σ ≤ X ≤ μ+σ)

Drag the sliders to see how μ shifts the centre and σ changes the spread of the curve.

Part C — CDF (Cumulative Distribution Function)

Both PMF and PDF have a corresponding Cumulative Distribution Function (CDF), written F(x), which gives the
probability that X is less than or equal to x.

CDF from PMF (discrete)

F(x) = P(X ≤ x) = Σ P(X = k) for all k ≤ x

CDF is a step function — it jumps at each discrete value.

CDF from PDF (continuous)

F(x) = P(X ≤ x) = ∫(−∞ to x) f(t) dt

CDF is a smooth S-shaped curve (for the normal distribution). F(−∞) = 0, F(+∞) = 1.

CDF comparison — discrete (PMF) vs continuous (PDF)

Discrete CDF (step function)

Continuous CDF (smooth S-curve)


Difference Between PMF and PDF

PMF PDF

Used for discrete variables Used for continuous variables

Gives exact probabilities Gives probability density

Probability at a point can be non-zero Probability at a point is zero

Summation used Integration used

Probability distributions

Probability distributions are mathematical models used to describe the behavior of random variables. In statistics and
probability theory, Bernoulli, Binomial, and Poisson distributions are among the most important discrete probability
distributions.

1. Bernoulli Distribution
Definition:
A Bernoulli distribution is a discrete probability distribution for a random variable that takes only two possible
outcomes: Success (1) and Failure (0).

Conditions:
• Only one trial is conducted.
• There are only two outcomes.
• Probability of success is p.
• Probability of failure is q = 1 − p.

PMF Function:
P(X = x) = p^x (1-p)^(1-x), where x = 0 or 1

Mean and Variance:


Mean E(X) = p
Variance Var(X) = p(1-p)

Example:
Consider tossing a coin once.
Success = Head, Failure = Tail.
If p = 0.5:
P(X=1)=0.5 and P(X=0)=0.5

2. Binomial Distribution
Definition:
A Binomial distribution represents the number of successes in a fixed number of independent Bernoulli trials.

Conditions:
• Number of trials n is fixed.
• Each trial has two outcomes.
• Trials are independent.
• Probability of success remains constant.

PMF Function:
P(X = x) = nCx * p^x * (1-p)^(n-x), where x = 0,1,2,...,n
Mean and Variance:
Mean E(X) = np
Variance Var(X) = np(1-p)

Example:
Suppose a coin is tossed 3 times.
Find probability of getting exactly 2 heads.
Here, n=3, x=2, p=0.5
P(X=2)=3C2*(0.5)^2*(0.5)^1
=3*(0.25)*(0.5)=0.375

3. Poisson Distribution
Definition:
A Poisson distribution is used to model the number of times an event occurs within a fixed interval of time,
area, or space.

Characteristics:
• Events occur independently.
• Average rate of occurrence is constant.
• Events occur one at a time.

PMF Function:
P(X = x) = (e^-λ * λ^x) / x!, where x = 0,1,2,...

Mean and Variance:


Mean E(X) = λ
Variance Var(X) = λ

Example:
Suppose a call center receives an average of 4 calls per minute.
Find probability of receiving exactly 2 calls in a minute.
Here λ=4, x=2
P(X=2)= (e^-4 * 4^2)/2!
= (0.0183 * 16)/2
=0.1465 approximately.

4. Comparison of Distributions
Distribution Trials Mean Application
Bernoulli Single Trial p Single success/failure
experiment
Binomial Fixed number of np Repeated
trials success/failure trials
Poisson Infinite possible λ Rare event
occurrences occurrences

Common Probability Density Functions


Probability Density Functions (PDFs) are used to describe the probability distribution of continuous random variables.
The area under a PDF curve over an interval represents the probability that the variable lies within that interval.

1. Continuous Uniform Distribution


Definition:
A continuous uniform distribution is a probability distribution in which all values within a given interval are
equally likely to occur.
Probability Density Function (PDF):
f(x) = 1 / (b - a), for a ≤ x ≤ b

Properties:

• Mean E(X) = (a + b)/2


• Variance Var(X) = (b - a)^2 / 12

Example:
Suppose a bus arrives uniformly between 10 AM and 11 AM.
Let X be the waiting time in minutes.
Interval: a = 0, b = 60
PDF:
f(x) = 1/60, for 0 ≤ x ≤ 60
Probability that the bus arrives within first 20 minutes:
P(X ≤ 20) = 20/60 = 1/3

2. Normal Distribution
Definition:
The normal distribution is a continuous probability distribution that is symmetric about its mean and has a
bell-shaped curve.

Probability Density Function (PDF):


f(x) = [1 / (σ√(2π))] * e^(-(x-μ)^2 / (2σ^2))

Properties:

• Mean = Median = Mode = μ


• Variance = σ²
• Bell-shaped and symmetric curve

Example:
Suppose marks of students are normally distributed with mean μ = 70 and standard deviation σ = 10.
Find the standardized value (Z-score) for a student scoring 85 marks.
Z = (X - μ)/σ = (85 - 70)/10 = 1.5

3. Student's t Distribution
Definition:
Student's t distribution is a continuous probability distribution used when the sample size is small and
population standard deviation is unknown.

Probability Density Function (PDF):


f(t) = Γ((ν+1)/2) / [√(νπ) Γ(ν/2)] * (1 + t²/ν)^(-(ν+1)/2)

Properties:

• Symmetric about zero


• Depends on degrees of freedom ν
• Approaches normal distribution as ν increases

Example:
Suppose a sample of size n = 10 has sample mean = 50, sample standard deviation = 5, and population mean μ
= 47.
Compute t-statistic:
t = (x̄ - μ) / (s/√n)
t = (50 - 47)/(5/√10)
t ≈ 1.897

4. Comparison of Distributions
Distribution Nature Main Parameter Applications
Continuous Uniform Equal probability a, b Random waiting time
over interval
Normal Bell-shaped μ, σ Natural and social
symmetric sciences
Student's t Similar to normal but Degrees of freedom Small sample
wider tails hypothesis testing

You might also like