Unit – I : Introduction to Data Analytics (Detailed but Easy Explanation)
1.1 Data Analytics: An Overview, Importance of Data Analytics
Overview
• Data Analytics ek systematic process hai jisme hum raw data ko useful information me
convert karte hain.
• Steps: Data collect karna → clean karna → analyze karna → graphs/visuals banana → results
interpret karke decision lena.
Simple Example:
Tu ek shop chalata hai. Har din ka sale record karta hai. Agar tu bas record likhta rahe to wo raw data
hai. Lekin agar tu us data ka average sale nikal ke trend dekhe (jaise Sunday ko zyada sale hoti hai), to
wo data analytics hai.
Importance of Data Analytics
1. Decision Making Better Hota Hai – facts ke basis pe.
2. Future Predict Karne Me Help – demand/supply ka अंदाजा lagana.
3. Customer Behavior Samajhne Ke Liye – kaunsa product pasand aa raha hai.
4. Efficiency Improve Karna – waste kam aur profit zyada.
5. Fraud Detection – abnormal patterns identify karke.
Example: Netflix apna users ka data analyze karta hai aur recommend karta hai movies/series.
1.2 Types of Data Analytics
1. Descriptive Analytics – "Kya Hua?"
o Past data summarize karta hai.
o Example: “Last month 200 laptops bike.”
2. Diagnostic Analytics – "Kyu Hua?"
o Reason find karta hai.
o Example: Sales kam hui kyunki ads kam diye gaye.
3. Predictive Analytics – "Future me kya hoga?"
o Statistical models & ML se future forecast.
o Example: “Agla month sales 20% increase ho sakti hai.”
4. Prescriptive Analytics – "Ab kya karna chahiye?"
o Suggestion deta hai future ke liye.
o Example: “Discount do aur production badhao.”
5. Visual Analytics
o Data ko charts, dashboards, graphs ke form me dikhana.
o Non-technical users ke liye easy samajhne ka tareeka.
1.3 Life Cycle of Data Analytics, Quality & Quantity of Data, Measurement
Life Cycle of Data Analytics
1. Data Collection – Different sources (Databases, Surveys, Excel, Sensors).
2. Data Preparation / Cleaning – Missing values, duplicates, errors remove.
3. Data Analysis – Statistical & computational techniques use karke.
4. Visualization & Reporting – Charts, dashboards, graphs.
5. Decision Making – Jo result nikla uske basis pe business decision lena.
Example: Ola cab data analyze karke dekhta hai kis area me demand zyada hai → waha drivers
allocate karta hai.
Data Quality & Quantity
• Quality: Data correct, reliable aur consistent ho. Agar galat data hoga to galat analysis hoga
(“Garbage In, Garbage Out”).
• Quantity: Enough volume ho data ka. Bahut kam data hoga to biased result aa sakta hai.
Measurement Scales
1. Nominal: Bas categories (e.g., Gender = Male/Female).
2. Ordinal: Order hota hai (Rank = 1st, 2nd, 3rd).
3. Interval: Ordered numbers, difference meaningful, but no true zero (Temperature in °C).
4. Ratio: Ordered numbers with true zero (Height, Salary, Age).
1.4 Data Types, Measures of Central Tendency, Measures of Dispersion
Data Types
• Qualitative (Categorical): Non-numeric (color, city).
• Quantitative (Numeric): Numbers
o Discrete: Countable (No. of students).
o Continuous: Measurement (Height, Weight).
Measures of Central Tendency
1. Mean (Average):
Mean=Σxn\text{Mean} = \frac{\Sigma x}{n}Mean=nΣx
Example: (10+20+30)/3 = 20
2. Median (Middle value):
Arrange data → pick middle.
Example: 5, 10, 15 → Median = 10
3. Mode (Most frequent):
Example: 2, 3, 3, 4 → Mode = 3
Measures of Dispersion (Spread of Data)
1. Range = Max – Min
2. Variance = Average of squared differences from mean
3. Standard Deviation (σ) = √Variance
4. IQR (Inter Quartile Range) = Q3 – Q1
Example:
Marks = 20 to 95 → high dispersion.
Marks = 80 to 85 → low dispersion.
1.5 Sampling Funnel, CLT, Confidence Interval, Sampling Variation
Sampling Funnel
• Large population → chhota sample choose karke analysis karte hain.
• Time aur cost bachta hai.
Example: India me sab logon ka survey impossible → chhota sample leke poore country ka अंदाजा
lagate hain.
Central Limit Theorem (CLT)
• Agar hum multiple samples lete hain aur unka mean nikalte hain → un sabka distribution
approx. Normal Distribution hoga.
• Matlab: sample ke mean se population ke mean ka अंदाजा lagaya ja sakta hai.
Confidence Interval (CI)
• Ek range jo population parameter ko cover karta hai with certain % chance.
• Example: “Average marks = 75 ± 5 at 95% confidence.”
Matlab: actual mean 70–80 ke beech hone ka 95% chance hai.
Sampling Variation
• Alag-alag sample lene par result thoda change hota hai.
• Is difference ko hi sampling variation bolte hain.
Example: Agar 1000 students ke population se 50 students ka sample lo, aur phir alag 50
students lo → dono ka average thoda alag hoga.
Unit – II : Statistical Analysis (Detailed Notes)
2.1 Graphical Techniques, Box Plot, Skewness, Kurtosis, Descriptive Stats
Graphical Techniques
Data ko visual form me dikhane ke liye graphs/plots use hote hain.
• Histogram: Data ko intervals (bins) me divide karke frequency bars show karta hai. Example:
Students ke marks 0–10, 10–20 group me.
• Bar Chart: Categories compare karne ke liye (e.g., sales by region).
• Pie Chart: Data ka percentage share (e.g., budget ka distribution).
• Line Graph: Trend over time (e.g., stock price daily change).
Graphical representation data ko fast aur easy samajhne me help karta hai.
Box Plot (Whisker Plot)
• Box plot data ka spread aur outliers dikhata hai.
• Components:
1. Minimum
2. Q1 (25th percentile)
3. Median (50th percentile)
4. Q3 (75th percentile)
5. Maximum
• Agar koi value normal range se bahut dur hai → Outlier.
Example: Class test scores 20–95 ke beech hain, median = 60, aur ek student 10 laya → 10 =
outlier.
Skewness
• Data ka symmetry/asymmetry measure.
• Positive skew (Right skew): Tail right side me. Mean > Median. Example: Salary distribution
(few people earn very high).
• Negative skew (Left skew): Tail left side me. Mean < Median. Example: Easy exam me sab
high marks lete hain.
• Zero skew: Data symmetric, Mean = Median = Mode.
Kurtosis
• Data distribution ka peakness (sharpness ya flatness).
• Leptokurtic: High peak, heavy tails (extreme values zyada).
• Platykurtic: Flat distribution (values evenly spread).
• Mesokurtic: Normal curve, balanced.
Descriptive Statistics
• Data ko summarize karne ke liye.
1. Central Tendency: Mean, Median, Mode.
2. Dispersion: Range, Variance, Standard Deviation, IQR.
3. Shape: Skewness, Kurtosis.
Example: Agar ek class ke average marks 70 hai, SD = 10 hai → matlab mostly students 60–80 ke
beech score karte hain.
2.2 Correlation and Regression, Data Cleaning
Correlation
• Measures relationship strength between two variables.
• Coefficient (r): –1 to +1.
o r = +1 → perfect positive (X ↑ → Y ↑).
o r = –1 → perfect negative (X ↑ → Y ↓).
o r = 0 → no relation.
Example: Height vs Weight (positive correlation).
Regression
• Predicting one variable (Y) using another (X).
• Formula:
Y=a+bXY = a + bXY=a+bX
• Y = dependent variable
• X = independent variable
• a = intercept, b = slope
Example: Study Hours (X) se Marks (Y) predict karna.
Data Cleaning
• Raw data = errors, missing values, duplicates.
• Steps:
1. Identify missing values.
2. Handle missing (imputation).
3. Remove duplicates.
4. Correct wrong entries.
5. Normalize (units same).
6. Outliers check karna.
Clean data = reliable results.
2.3 Imputation Techniques
• Missing values ko fill karne ke methods.
1. Mean / Median / Mode replacement (numerical data).
2. Forward/Backward fill (time series).
3. Regression imputation – missing value ko predict karna.
4. KNN imputation – nearest neighbors ke basis pe.
Example: Salary column me ek value missing hai → usko dataset ke average salary se replace kar
sakte hain.
2.4 ANOVA and Chi-Square
ANOVA (Analysis of Variance)
• Test karta hai ki 3 ya usse zyada groups ke means different hain ya nahi.
• One-way ANOVA: 1 factor (e.g., Marks vs Different Schools).
• Two-way ANOVA: 2 factors (e.g., Marks vs Schools + Gender).
Example: 3 coaching centers ke Maths marks compare karna.
Chi-Square Test
• Categorical data ke relation check karne ke liye.
• Formula:
χ2=∑(O−E)2E\chi^2 = \sum \frac{(O - E)^2}{E}χ2=∑E(O−E)2
• O = Observed frequency, E = Expected frequency.
Example: Gender (Male/Female) aur Product Preference (Shoes/Watch) ke beech relation hai ya
nahi.
2.5 Scatter Diagram
• Do variables ka relationship plot karta hai.
• Graph = X vs Y.
• Types:
o Positive relation → upward slope.
o Negative relation → downward slope.
o No relation → random points.
Example: Advertising spend vs Sales revenue scatter plot → ads ↑ to sales ↑.
2.6 Estimation and Hypothesis Testing
Estimation
• Sample se population ke parameter ka अंदाजा lagana.
• Point Estimate: Single value (e.g., mean = 50).
• Interval Estimate (Confidence Interval): Range (e.g., 48–52).
Hypothesis Testing
1. Null Hypothesis (H₀): No effect / no difference.
2. Alternative Hypothesis (H₁): Effect / difference exists.
3. Choose significance level (α = 0.05).
4. Test statistic (z, t, χ²) calculate.
5. Compare with critical value.
6. Accept/Reject H₀.
Example: Test whether average marks = 60 using sample data.
2.7 Sampling Distributions, Counting
Sampling Distribution
• Agar ek population se multiple random samples le kar mean calculate karein → unka
distribution approx. Normal distribution hota hai (Central Limit Theorem).
Matlab: Sample ka mean population mean ka अंदाजा deta hai.
Counting (Combinatorics)
1. Permutation: Order important.
Formula:
nPr=n!(n−r)!nPr = \frac{n!}{(n-r)!}nPr=(n−r)!n!
Example: 3 students se 2 arrange karna → AB, BA, AC, CA, BC, CB (6 ways).
2. Combination: Order important nahi.
Formula:
nCr=n!r!(n−r)!nCr = \frac{n!}{r!(n-r)!}nCr=r!(n−r)!n!
Example: 3 students se 2 choose karna → AB, AC, BC (3 ways).
2.8 Probability and Probability Distributions
Probability
• Kisi event ke hone ka chance.
• Formula:
P(E)=Favourable outcomesTotal outcomesP(E) = \frac{\text{Favourable outcomes}}{\text{Total
outcomes}}P(E)=Total outcomesFavourable outcomes
Example: Dice me 6 aane ka chance = 1/6.
Probability Distributions
1. Discrete Distributions
o Binomial Distribution: Success/failure experiments (e.g., 10 coin tosses → number
of heads).
o Poisson Distribution: Rare events (e.g., no. of accidents per day).
2. Continuous Distributions
o Normal Distribution: Bell-shaped curve (e.g., human height).
o Exponential Distribution: Time between events (e.g., time between two bus
arrivals).
Unit – III : Data Analytics with Excel (Full Proper Notes)
3.1 Excel Dashboard
Dashboard kya hota hai?
• Dashboard ek single interactive page hota hai jo important data ko charts, tables, filters ke
through summarize karta hai.
• Matlab: Poora data alag-alag sheets me dekhne ki zarurat nahi → ek hi jagah par overview
mil jata hai.
Components
1. Tables and Data Grids
o Data ko rows & columns me arrange karna.
o Example: Sales data with Product, Region, Sales Amount.
2. Dynamic Filters and Controls
o Tools jaise Slicers, Drop-down lists, Checkboxes.
o Example: Agar tu "Region = North" select kare, to dashboard me sirf North ka data
show hoga.
3. Trend Analysis and Forecasting
o Trend line: Data ka pattern dikhata hai (increasing/decreasing).
o Forecasting: Excel ke tool se future prediction kar sakte ho (e.g., Next month sales
kitne ho sakte hain).
Dashboard = Decision-making ke liye ek fast summary tool.
3.2 Pivot Tables
Pivot Table kya hai?
• Pivot Table ek Excel feature hai jo large dataset ko summarize aur analyze karta hai.
• Tum raw data ke basis pe totals, averages, counts, comparisons easily nikal sakte ho.
Steps to Create Pivot Table
1. Dataset select karo → Insert → Pivot Table.
2. Choose location (new sheet/existing sheet).
3. Fields ko drag & drop karo:
o Rows: Category (e.g., Region).
o Columns: Sub-category (e.g., Product).
o Values: Numbers/Calculations (e.g., SUM of Sales).
o Filters: Data ko filter karne ke liye.
Example: Tumhare paas 10,000 sales entries hai → Pivot Table easily "Region-wise Total Sales"
dikha dega.
3.3 Modifying Pivot Table: Calculation, Filtering, Sorting
1. Changing Pivot Table
o Fields ko drag-and-drop karke analysis change karna.
o Example: "Region-wise Sales" → change to "Year-wise Sales".
2. Calculations in Pivot Table
o Default: SUM, COUNT, AVERAGE, MAX, MIN.
o Extra: % of Total, % Difference, Running Total.
3. Filtering Pivot Table
o Filters tab ya slicers se dataset filter karna.
o Example: Sirf “North Region” ka data dekhna.
4. Sorting Pivot Table
o Data ko ascending/descending order me arrange karna.
o Example: Top 5 products by sales.
3.4 Pivot Chart & Grouping Items
1. Pivot Chart
o Pivot Table ka graphical version.
o Automatically update hota hai jab Pivot Table update hoti hai.
o Chart Types: Bar, Line, Pie, Column, Area.
2. Grouping Items
o Dates group karna: Year, Quarter, Month.
o Numbers group karna: 0–10, 10–20, etc.
o Text group karna: Similar categories ko merge karna.
Example: Sales ko “Quarterly” group karke dekhna.
3.5 Updating, Formatting Pivot Table, Using Slicers
1. Updating Pivot Table
o Agar source data change hota hai → Refresh karna padta hai.
o Shortcut: Right-click → Refresh.
2. Formatting Pivot Table
o Design → Styles, Borders, Colors.
o Show/Hide Subtotals and Grand Totals.
o Conditional Formatting (e.g., highlight top 10 values).
3. Slicers (Interactive Filter)
o Button-based visual filters.
o Example: Agar slicer me “Region” add karo → bas North/South/East click karke
specific data filter kar sakte ho.