Data Science & Machine Learning
77.8K subscribers
902 photos
1 video
68 files
822 links
Join this channel to learn data science, artificial intelligence and machine learning with funny quizzes, interesting projects and amazing resources for free

For collaborations: @love_data
Download Telegram
But that's not necessarily true. We also need to consider: 

โ€ข How common the disease is 

โ€ข How often the test produces false positives 

โ€ข How accurate the test is 

Bayes' Theorem combines all of this information to calculate the probability of actually having the disease given a positive test. This is called the base-rate effect.

๐Ÿ”น 11. Fraud Detection Example

Suppose a bank monitors transactions. Initially: P(Fraud) = 1%

A transaction contains unusual characteristics.

The system uses historical data to determine: P(Unusual | Fraud)

Bayes' Theorem can then help estimate: P(Fraud | Unusual)

The bank can use this probability to decide whether the transaction should be investigated.

๐Ÿ”น 12. Bayes' Theorem vs Conditional Probability

Conditional Probability answers: "What is the probability of A given B?" โ†’ $P(A|B)$

Bayes' Theorem provides a way to calculate that probability by using the reverse conditional probability:

P(A|B) = P(B|A)P(A)/P(B)

So Bayes' Theorem allows us to reverse conditional probabilities and update our beliefs using evidence.

๐Ÿ”น 13. Prior vs Likelihood vs Posterior โญ

Prior: What we believe before seeing new evidence. โ†’ $P(A)$

Likelihood: How likely the evidence is assuming A is true. โ†’ $P(B|A)$

Posterior: What we believe after considering the evidence. โ†’ $P(A|B)$ 

A simple way to remember: Prior + Evidence โ†’ Posterior

๐Ÿ”น 14. Python Example

Bayes' Theorem can be implemented directly in Python:
prior = 0.10
likelihood = 0.80
evidence = 0.20

posterior = (likelihood * prior) / evidence
print(posterior)

Output:
0.4

So the posterior probability is: 40%

๐Ÿ”น 15. Common Mistake โญ

A common mistake is confusing: P(A|B) with P(B|A)

They are generally not equal.

For example: P(Disease | Positive Test) is not necessarily the same as P(Positive Test | Disease)

This distinction is extremely important in statistics and Machine Learning.

๐ŸŽฏ Practice Questions

1. Write the formula for Bayes' Theorem.

2. What is the difference between prior and posterior probability?

3. What does "P(A|B)" mean?

4. Give two real-world applications of Bayes' Theorem.

5. Why is Bayes' Theorem useful in spam detection?

๐ŸŽฏ Key Takeaways

โœ… Bayes' Theorem updates probability using new evidence.

โœ… The basic formula is: P(A|B)=P(B|A)P(A)/P(B)

โœ… Prior probability represents our initial belief.

โœ… Likelihood measures how likely the evidence is under an assumption.

โœ… Posterior probability represents our updated belief.

โœ… Bayes' Theorem is the foundation of algorithms such as Naive Bayes.

โœ… It is widely used in spam detection, medical diagnosis, fraud detection, classification, and risk analysis.

The key idea to remember is:

ยซBayes' Theorem helps us update what we believe when new evidence becomes available.ยป

Double Tap โค๏ธ For More
โค8๐Ÿ”ฅ3
๐Ÿš€ ๐—š๐—ผ๐—ผ๐—ด๐—น๐—ฒ ๐—™๐—ฅ๐—˜๐—˜ ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ๐˜€ ๐Ÿฎ๐Ÿฌ๐Ÿฎ๐Ÿฒ ๐ŸŽ“

Want to upgrade your resume with Google skills and certifications Explore FREE learning opportunities and build in-demand skills for today's job market.

๐Ÿ‘‰Artificial Intelligence & Generative AI
๐Ÿ“Š Data Analytics
โ˜๏ธ Cloud Computing
๐Ÿ“ข Digital Marketing
๐Ÿ” Cybersecurity
๐Ÿ’ป Tech & Career Skills

๐—˜๐—ป๐—ฟ๐—ผ๐—น๐—น ๐—™๐—ผ๐—ฟ ๐—™๐—ฅ๐—˜๐—˜๐Ÿ‘‡:- 

https://pdlink.in/4z9pdgf

๐Ÿ”ฅ Don't just collect certificates โ€” build skills that can help you stand out in 2026!
โค2๐Ÿ‘1๐Ÿ”ฅ1
Which Machine Learning algorithm is directly based on Bayes' Theorem?
Anonymous Quiz
18%
A) K-Means
11%
B) Random Forest
63%
C) Naive Bayes
8%
D) Linear Regression
๐Ÿš€ DATA ANALYTICS + AI: YOUR NEXT CAREER MOVE!

Data is everywhere. The right skills can put you ahead.
Join the PW Skills Data Analytics With AI Course and learn Excel, SQL, Python, Power BI & AI tools through live sessions and real-world projects.

โœจ What you get:
โœ… Industry-relevant Data Analytics skills
โœ… AI-powered learning
โœ… Microsoft collaboration
โœ… Hands-on projects
โœ… Job assistance*
โœ… Live classes in Hinglish

๐Ÿ“… Starts: 14th August 2026
โณ Duration: 5 Months
๐Ÿ”ฅ Ready to become a future-ready Data Analyst?
๐Ÿ‘‰
Enroll Now & Start Your Upskilling Journey!
https://lp.pwskills.com/data-analytics-with-gen-ai-online-course?utm_source=telegram&utm_medium=influencer&utm_campaign=deepakDAonline
โค8๐ŸŽ‰1
๐Ÿ‡ฎ๐Ÿ‡ณ ๐—™๐—ฅ๐—˜๐—˜ ๐—š๐—ผ๐˜ƒ๐—ฒ๐—ฟ๐—ป๐—บ๐—ฒ๐—ป๐˜-๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฒ๐—ฑ ๐—ข๐—ป๐—น๐—ถ๐—ป๐—ฒ ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ๐˜€ ๐ŸŽ“

Upgrade your skills with *SWAYAM*, an initiative by the Government of India!

โœ… Learn from leading institutes and expert educators
โœ… Courses in AI, Programming, Data Science, Business & more
โœ… Suitable for students, freshers and professionals
โœ… Learn online at your own pace
โœ… Strengthen your rรฉsumรฉ with valuable certifications

๐Ÿ”— ๐—˜๐—ป๐—ฟ๐—ผ๐—น๐—น ๐—™๐—ผ๐—ฟ ๐—™๐—ฅ๐—˜๐—˜๐Ÿ‘‡:- 

https://pdlink.in/4gc1MKx

๐Ÿ“ข Share this opportunity with your friends and classmates!
โค4๐ŸŽ‰1
๐—”๐—œ ๐—˜๐—ป๐—ด๐—ถ๐—ป๐—ฒ๐—ฒ๐—ฟ๐—ถ๐—ป๐—ด ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ ๐Ÿ˜

Build real AI products - not just prompts

๐ŸŽฏ Program Highlights:-

๐Ÿš€ 15+ AI Projects
๐Ÿ‘จโ€๐Ÿซ Live Online Classes + 1-on-1 Mentorship
๐Ÿ’ผ End-to-End Placement Support
๐Ÿค 500+ Partner Companies
๐ŸŽ“ 2000+ Students Placed
๐Ÿ’ฐ Average Salary: โ‚น7.4 LPA
๐Ÿ† Highest Salary: โ‚น41 LPA

๐Ÿ”— ๐—•๐—ผ๐—ผ๐—ธ ๐—ฎ ๐—™๐—ฅ๐—˜๐—˜ ๐——๐—ฒ๐—บ๐—ผ ๐—–๐—น๐—ฎ๐˜€๐˜€:-

https://pdlink.in/4fWJVID

๐Ÿ”ฅ Learn AI โ†’ Build Real Projects โ†’ Create Your Portfolio โ†’ Become Job Ready
โค2
๐Ÿ“Š ๐— ๐—ถ๐—ฐ๐—ฟ๐—ผ๐˜€๐—ผ๐—ณ๐˜ ๐—™๐—ฅ๐—˜๐—˜ ๐—ฃ๐—ผ๐˜„๐—ฒ๐—ฟ ๐—•๐—œ ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ ๐Ÿš€

Want to start a career in Data Analytics & Business Intelligence? Learn Power BI through Microsoft learning modules and build practical, job-relevant analytics skills.

๐ŸŽฏ Perfect for Students | Freshers | Data Analyst Aspirants | Working Professionals

๐Ÿ”— ๐—˜๐—ป๐—ฟ๐—ผ๐—น๐—น ๐—™๐—ผ๐—ฟ ๐—™๐—ฅ๐—˜๐—˜๐Ÿ‘‡:- 

https://pdlink.in/4zhGTX6

๐Ÿ”ฅ Start learning Power BI and turn raw data into powerful business insights!
โค4๐ŸŽ‰1
๐Ÿ“Š ๐—•๐˜‚๐—ถ๐—น๐—ฑ ๐—ฌ๐—ผ๐˜‚๐—ฟ ๐——๐—ฎ๐˜๐—ฎ ๐—”๐—ป๐—ฎ๐—น๐˜†๐˜€๐˜ ๐—ฃ๐—ผ๐—ฟ๐˜๐—ณ๐—ผ๐—น๐—ถ๐—ผ | ๐Ÿฑ ๐—›๐—ฎ๐—ป๐—ฑ๐˜€-๐—ข๐—ป ๐—ฃ๐—ฟ๐—ผ๐—ท๐—ฒ๐—ฐ๐˜๐˜€ ๐Ÿš€

Learning Data Analytics? Don't stop with tutorials โ€” build real projects that you can showcase on your resume and portfolio! ๐Ÿ’ป

๐Ÿ”ฅ Practice with 5 Hands-On Projects covering:

๐Ÿ—„๏ธ SQL
๐Ÿ“Š Excel
๐Ÿ“ˆ Tableau
๐Ÿ“‰ Power BI

๐Ÿ”—๐—Ÿ๐—ถ๐—ป๐—ธ ๐Ÿ‘‡:- 

https://pdlink.in/45LLDH7

๐ŸŽ“ Perfect for Students | Freshers | Data Analyst Aspirants | Beginners
โค4๐ŸŽ‰1
๐Ÿš€ ๐Ÿฐ ๐—™๐—ฅ๐—˜๐—˜ ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ๐˜€ ๐˜๐—ผ ๐—•๐—ผ๐—ผ๐˜€๐˜ ๐—ฌ๐—ผ๐˜‚๐—ฟ ๐—ฅ๐—ฒ๐˜€๐˜‚๐—บ๐—ฒ & ๐—–๐—ผ๐—ป๐—ณ๐—ถ๐—ฑ๐—ฒ๐—ป๐—ฐ๐—ฒ ๐ŸŽ“๐Ÿ”ฅ

Make your resume stand out and feel more confident during your job search.

๐Ÿš€ Build confidence and a career-focused mindset

โœ… 100% FREE
โœ… Beginner Friendly
โœ… Improve Your Resume
โœ… Develop Career-Ready Skills
โœ… Great for Students, Freshers & Professionals

๐Ÿ”— ๐—˜๐—ป๐—ฟ๐—ผ๐—น๐—น ๐—™๐—ผ๐—ฟ ๐—™๐—ฅ๐—˜๐—˜๐Ÿ‘‡:- 

https://pdlink.in/4gce062

๐Ÿ”ฅ Don't just apply for jobs โ€” build the skills and confidence to stand out!
โค1๐Ÿ‘1
๐Ÿš€ Data Science Roadmap 2026

๐Ÿ“˜ Phase 2: Mathematics for Data Science

๐Ÿ“– Topic 6: Probability Distributions โ€” Discrete, Continuous, PMF, PDF & CDF

Welcome back! ๐Ÿ‘‹

In the previous lesson, you learned Bayes' Theorem, which helps us update probabilities when new evidence becomes available.

Now we'll learn Probability Distributions.

Probability distributions are extremely important in Data Science because they help us understand how values are distributed and how likely different outcomes are.

They are used in:

โœ… Statistical analysis

โœ… Machine Learning

โœ… Hypothesis testing

โœ… A/B testing

โœ… Forecasting

โœ… Risk analysis

โœ… Data simulation

๐Ÿ”น 1. What is a Probability Distribution?

A probability distribution describes how the probabilities of different possible outcomes are distributed.

For example, when rolling a fair die:

1 โ†’ 1/6

2 โ†’ 1/6

3 โ†’ 1/6

4 โ†’ 1/6

5 โ†’ 1/6

6 โ†’ 1/6

Every possible outcome has an associated probability.

The sum of all probabilities must equal: 1 = 100%

๐Ÿ”น 2. Two Main Types of Probability Distributions

Probability distributions can broadly be divided into:

1๏ธโƒฃ Discrete Distribution

Used when outcomes are countable.

Examples: Number of customers, Number of defective products, Number of emails, Number of heads in coin tosses

2๏ธโƒฃ Continuous Distribution

Used when values can take any value within a range.

Examples: Height, Weight, Temperature, Time, Salary

๐Ÿ”น 3. Discrete Random Variable

A discrete random variable takes countable values.

Example: Number of customers arriving at a store: 0, 1, 2, 3, 4, 5, ...

Another example: Number of defective products in a batch.

๐Ÿ”น 4. Continuous Random Variable

A continuous random variable can take infinitely many possible values within a range.

For example: someone's height could be: 170 cm, 170.1 cm, 170.15 cm, 170.157 cm...

There are infinitely many possible values.

๐Ÿ”น 5. PMF โ€” Probability Mass Function โญ

PMF stands for: Probability Mass Function

It is used for discrete random variables.

PMF tells us the probability of a specific outcome.

For example, when rolling a fair die:

P(X=3) = 1/6

Important Rule:

The probabilities of all possible outcomes must add up to 1:

โˆ‘P(X=x) = 1

๐Ÿ”น 6. PDF โ€” Probability Density Function โญ

PDF stands for: Probability Density Function

It is used for continuous random variables.

Unlike PMF, the PDF does not directly give the probability of a single exact value.

Instead, the area under the PDF curve over an interval represents probability.

For example: P(170 < Height < 180) is represented by the area under the PDF between 170 and 180.

Important Point:

For a continuous variable:

P(X=x) = 0

for any exact single value under the usual continuous probability model.

This doesn't mean the value is impossible. It means probability is assigned to intervals, not individual points.

๐Ÿ”น 7. CDF โ€” Cumulative Distribution Function โญ

CDF stands for: Cumulative Distribution Function

It tells us the probability that a random variable is less than or equal to a particular value.

Formula:

F(x) = P(X โ‰ค x)

Example: Suppose X = Test Score

Then: F(80) = P(X โ‰ค 80)
โค4
This tells us the probability that the score is 80 or less.

๐Ÿ”น 8. PMF vs PDF vs CDF

PMF: Used for Discrete data. Represents Probability of an exact outcome

PDF: Used for Continuous data. Represents Probability density

CDF: Used for Discrete & continuous. Represents Probability up to a value

A simple way to remember:

PMF โ†’ Exact probability for discrete outcomes

PDF โ†’ Density across continuous values

CDF โ†’ Cumulative probability up to a value

๐Ÿ”น 9. Example: Discrete Distribution

Suppose a machine produces defective products.

Let: X = Number of defective products

Possible values: 0, 1, 2, 3

Suppose:

P(X=0) = 0.50

P(X=1) = 0.30

P(X=2) = 0.15

P(X=3) = 0.05

Check: 0.50 + 0.30 + 0.15 + 0.05 = 1.00

Therefore, this is a valid probability distribution.

๐Ÿ”น 10. Example: Continuous Distribution

Suppose: X = Customer waiting time

Waiting time could be: 2.1 minutes, 2.15 minutes, 2.157 minutes, 2.1578 minutes...

Because there are infinitely many possible values, we treat it as a continuous random variable.

A PDF can describe how densely the waiting times are distributed.

๐Ÿ”น 11. Normal Distribution โญ

One of the most important probability distributions in Data Science is the Normal Distribution.

It is often called the bell curve because of its shape.

A normal distribution is characterized by: Mean, Standard deviation

Many natural and measurement-related variables can be approximately normally distributed under suitable conditions.

Examples: Measurement errors, Certain biological measurements, Standardized test scores

๐Ÿ”น 12. Properties of Normal Distribution

For a perfectly symmetric normal distribution: Mean = Median = Mode

The distribution is symmetric around its mean.

A common rule of thumb is the 68โ€“95โ€“99.7 rule:

Within 1 Standard Deviation: Approximately 68%

Within 2 Standard Deviations: Approximately 95%

Within 3 Standard Deviations: Approximately 99.7%

๐Ÿ”น 13. Binomial Distribution

The Binomial Distribution is a discrete probability distribution used when:

There are a fixed number of trials, Each trial has two possible outcomes, The probability of success is constant, Trials are independent.

Examples: Number of successful predictions, Number of heads in coin tosses, Number of defective products in a fixed sample

Example: 10 coin tosses. X = Number of Heads. Possible values: 0, 1, 2, ..., 10

๐Ÿ”น 14. Poisson Distribution

The Poisson Distribution is commonly used to model the number of events occurring within a fixed interval when events occur at a certain average rate under appropriate assumptions.

Examples: Number of customer calls per hour, Number of website visits per minute, Number of machine failures per month, Number of support tickets per day

๐Ÿ”น 15. Why Probability Distributions Matter in Data Science?

Probability distributions help Data Scientists:

โœ… Understand data patterns

โœ… Detect unusual observations

โœ… Model uncertainty

โœ… Perform statistical tests

โœ… Build predictive models

โœ… Simulate data

โœ… Estimate probabilities

๐Ÿ”น 16. Python Example

import numpy as np

data = np.random.normal(
loc=50,
scale=10,
size=1000
)

print(data[:5])
โค6
Here: loc = 50 represents the mean. scale = 10 represents the standard deviation.

๐Ÿ”น 17. Common Mistakes

โŒ Confusing PMF and PDF โ†’ Remember: PMF โ†’ Discrete, PDF โ†’ Continuous

โŒ Thinking PDF value is probability โ†’ For a continuous distribution, the PDF value at a point is a density, not the probability of that exact value. Probability comes from the area over an interval.

โŒ Forgetting that CDF is cumulative โ†’ CDF always represents: P(X โ‰ค x)

๐ŸŽฏ Practice Questions

1. What is the difference between a discrete and continuous random variable?

2. What is PMF used for?

3. What does a PDF represent?

4. What does CDF calculate?

5. Name three probability distributions commonly used in Data Science.

๐ŸŽฏ Key Takeaways

โœ… Probability distributions describe how probabilities are distributed across possible outcomes.

โœ… Discrete variables have countable outcomes.

โœ… Continuous variables can take infinitely many values within a range.

โœ… PMF is used for discrete random variables.

โœ… PDF is used for continuous random variables.

โœ… CDF gives the cumulative probability up to a particular value.

โœ… Normal, Binomial, and Poisson distributions are important distributions for Data Scientists.

Understanding probability distributions gives you the foundation needed for statistical inference, hypothesis testing, machine learning, and advanced Data Science.

๐Ÿ‘‰ Double Tap โค๏ธ For More
โค9
โœ… SQL for Data Science ๐Ÿ—„๏ธ๐Ÿ“Š

๐Ÿ‘‰ SQL is one of the most important skills for Data Scientists and Data Analysts.

Almost every company stores data inside databases, and SQL helps retrieve and analyze that data.

๐Ÿ”น 1. What is SQL?
SQL = Structured Query Language

๐Ÿ‘‰ Used to:
โœ” Store data
โœ” Retrieve data
โœ” Filter data
โœ” Analyze data

๐Ÿ”ฅ 2. Common Database Systems
โœ” MySQL
โœ” PostgreSQL
โœ” SQLite
โœ” Microsoft SQL Server

๐Ÿ”น 3. Basic SQL Query

โœ… SELECT Statement
Used to retrieve data from a table.

SELECT * FROM employees;

๐Ÿ‘‰ ** means all columns.

๐Ÿ”น 4. Select Specific Columns
SELECT name, salary FROM employees;

๐Ÿ”น 5. WHERE Clause โญ
Used for filtering data.

SELECT * FROM employees
WHERE salary > 50000;

๐Ÿ”น 6. ORDER BY
Sort data.

SELECT * FROM employees
ORDER BY salary DESC;

โœ” ASC โ†’ Ascending
โœ” DESC โ†’ Descending

๐Ÿ”น 7. Aggregate Functions โญ
Used for calculations.

Function: COUNT()
Purpose: Count rows

Function: SUM()
Purpose: Total

Function: AVG()
Purpose: Average

Function: MAX()
Purpose: Highest value

Function: MIN()
Purpose: Lowest value

โœ… Example
SELECT AVG(salary)
FROM employees;

๐Ÿ”น 8. GROUP BY โญ
Used to group data.
SELECT department, AVG(salary)
FROM employees
GROUP BY department;

๐Ÿ”น 9. Why SQL is Important?
โœ” Most asked interview skill
โœ” Used daily by analysts & data scientists
โœ” Essential for working with databases

๐ŸŽฏ Todayโ€™s Goal
โœ” Learn SELECT queries
โœ” Filter using WHERE
โœ” Use aggregate functions
โœ” Understand GROUP BY

๐Ÿ‘‰ SQL Resources: https://whatsapp.com/channel/0029VanC5rODzgT6TiTGoa1v ๐Ÿ—„๏ธ๐Ÿ”ฅ

๐Ÿ’ฌ Tap โค๏ธ for more!
โค5
๐Ÿš€ Data Science Roadmap 2026

๐Ÿ“˜ Phase 2: Mathematics for Data Science

๐Ÿ“– Topic 7: Descriptive Statistics โ€” Range, Percentiles, Quartiles, IQR & Five-Number Summary

Welcome back! ๐Ÿ‘‹

In the previous lesson you covered Probability Distributions.

Now weโ€™re moving to Descriptive Statistics โ€” how we summarize data without predicting the population.

Today weโ€™ll cover: Range, Percentiles, Quartiles, IQR, Five-number summary, Outlier detection

These are core for EDA.

๐Ÿ”น 1. What is Descriptive Statistics?

Summarizes key characteristics of a dataset.

Example: Salaries: 30000, 35000, 40000, 45000, 50000

Instead of checking each value, use: Min, Max, Mean, Median, Quartiles, Percentiles, Std Dev

๐Ÿ”น 2. Range

Formula:

Range = Maximum โˆ’ Minimum

Example: 10, 20, 30, 40, 50 โ†’ Range = 50 โˆ’ 10 = 40

Note: Very sensitive to outliers. 50 โ†’ 500 makes range jump to 490.

๐Ÿ”น 3. Percentiles โญ

Value below which X% of observations fall.

50th Percentile = Median

25th Percentile = 25% at or below

90th Percentile = 90% at or below

๐Ÿ”น 4. Real-World Example

90th percentile score โ‰  90% marks. It means you did better than โˆผ90% of people.

๐Ÿ”น 5. Quartiles

Divide data into 4 equal parts:

Q1 = 25th percentile

Q2 = 50th percentile = Median

Q3 = 75th percentile

๐Ÿ”น 6. Visualizing Quartiles

0% ---- Q1 ---- Q2 ---- Q3 ---- 100%

25% 50% 75%

๐Ÿ”น 7. Interquartile Range (IQR) โญ

Formula: IQR = Q3 โˆ’ Q1

Example: Q1=20, Q3=60 โ†’ IQR = 40. Middle 50% spans 40 units.

๐Ÿ”น 8. Why IQR Matters

Less affected by outliers than Range.

Data: 10,20,30,40,50,1000 โ†’ Range=990 but IQR ignores the 1000.

๐Ÿ”น 9. Detecting Outliers Using IQR โญ

Lower Bound = Q1 โˆ’ 1.5 ร— IQR

Upper Bound = Q3 + 1.5 ร— IQR

Values outside = potential outliers

๐Ÿ”น 10. Outlier Example

Q1=20, Q3=60 โ†’ IQR=40

Lower = 20-60 = -40

Upper = 60+60 = 120

So < -40 or > 120 are outliers

๐Ÿ”น 11. Five-Number Summary โญ

1. Minimum 2. Q1 3. Median 4. Q3 5. Maximum

Ex: 10, 20, 30, 40, 50

๐Ÿ”น 12. Box Plot

Visualizes the 5-number summary.

Box = Q1 to Q3. Line inside = Median. Whiskers = range without outliers.

๐Ÿ”น 13. Python Example

import numpy as np

data = [10, 20, 30, 40, 50, 60, 70]
q1 = np.percentile(data, 25)
median = np.percentile(data, 50)
q3 = np.percentile(data, 75)
iqr = q3 - q1
print("Q1:", q1, "Median:", median, "Q3:", q3, "IQR:", iqr)


๐Ÿ”น 14. Descriptive Statistics in Pandas

import pandas as pd

df = pd.DataFrame({"Salary": [30000, 35000, 40000, 45000, 50000]})
print(df["Salary"].describe())


describe() gives Count, Mean, Std, Min, 25%, 50%, 75%, Max

๐Ÿ”น 15. Real-World Example

Transactions: Q1=โ‚น500, Median=โ‚น1000, Q3=โ‚น2000 โ†’ IQR=โ‚น1500

Use IQR to flag fraud, bulk orders, errors, or VIP customers. Investigate before deleting.

๐Ÿ”น 16. Range vs IQR

Range: Easy but outlier-sensitive

IQR: Middle 50% only, robust to outliers

๐Ÿ”น 17. Percentile vs Percentage

Percentage = out of 100.

Ex: 80% marks

Percentile = relative position.

Ex: 90th percentile

๐Ÿ”น 18. Common Mistakes

โŒ 90th percentile = 90% score

โŒ Deleting all outliers blindly

โŒ Thinking IQR covers all data

๐ŸŽฏ Practice Questions

1. Range of 10, 20, 30, 40, 50 = ?

2. Median = which percentile?

3. Q1=25, Q3=75 โ†’ IQR = ?

4. Upper outlier boundary formula?

5. 5 components of five-number summary?

๐ŸŽฏ Key Takeaways

โœ… Range = Max - Min

โœ… Q1=25th, Q2=50th=Median, Q3=75th

โœ… IQR = Q3 - Q1

โœ… 5-number summary = Min, Q1, Median, Q3, Max

โœ… Percentile โ‰  Percentage

๐Ÿ‘‰ Double Tap โค๏ธ For More
โค9๐Ÿ‘2
Essential Excel Functions for Data Analysts ๐Ÿš€

1๏ธโƒฃ Basic Functions

SUM() โ€“ Adds a range of numbers. =SUM(A1:A10)

AVERAGE() โ€“ Calculates the average. =AVERAGE(A1:A10)

MIN() / MAX() โ€“ Finds the smallest/largest value. =MIN(A1:A10)


2๏ธโƒฃ Logical Functions

IF() โ€“ Conditional logic. =IF(A1>50, "Pass", "Fail")

IFS() โ€“ Multiple conditions. =IFS(A1>90, "A", A1>80, "B", TRUE, "C")

AND() / OR() โ€“ Checks multiple conditions. =AND(A1>50, B1<100)


3๏ธโƒฃ Text Functions

LEFT() / RIGHT() / MID() โ€“ Extract text from a string.

=LEFT(A1, 3) (First 3 characters)

=MID(A1, 3, 2) (2 characters from the 3rd position)


LEN() โ€“ Counts characters. =LEN(A1)

TRIM() โ€“ Removes extra spaces. =TRIM(A1)

UPPER() / LOWER() / PROPER() โ€“ Changes text case.


4๏ธโƒฃ Lookup Functions

VLOOKUP() โ€“ Searches for a value in a column.

=VLOOKUP(1001, A2:B10, 2, FALSE)


HLOOKUP() โ€“ Searches in a row.

XLOOKUP() โ€“ Advanced lookup replacing VLOOKUP.

=XLOOKUP(1001, A2:A10, B2:B10, "Not Found")



5๏ธโƒฃ Date & Time Functions

TODAY() โ€“ Returns the current date.

NOW() โ€“ Returns the current date and time.

YEAR(), MONTH(), DAY() โ€“ Extracts parts of a date.

DATEDIF() โ€“ Calculates the difference between two dates.


6๏ธโƒฃ Data Cleaning Functions

REMOVE DUPLICATES โ€“ Found in the "Data" tab.

CLEAN() โ€“ Removes non-printable characters.

SUBSTITUTE() โ€“ Replaces text within a string.

=SUBSTITUTE(A1, "old", "new")



7๏ธโƒฃ Advanced Functions

INDEX() & MATCH() โ€“ More flexible alternative to VLOOKUP.

TEXTJOIN() โ€“ Joins text with a delimiter.

UNIQUE() โ€“ Returns unique values from a range.

FILTER() โ€“ Filters data dynamically.

=FILTER(A2:B10, B2:B10>50)



8๏ธโƒฃ Pivot Tables & Power Query

PIVOT TABLES โ€“ Summarizes data dynamically.

GETPIVOTDATA() โ€“ Extracts data from a Pivot Table.

POWER QUERY โ€“ Automates data cleaning & transformation.


You can find Free Excel Resources here: https://xn--r1a.website/excel_data

Hope it helps :)

#dataanalytics
โค11
What is the range of the dataset below?

10, 20, 30, 40, 50
Anonymous Quiz
18%
A) 30
39%
B) 40
31%
C) 50
12%
D) 60
โค3