BPHES
AHMEDNAGAR COLLEGE
DEPARTMENT OF COMPUTER SCIENCE
STATISTICS PROJECT
Submitted To Savitribai Phule Pune University
For Course [Link].(Computer Science)
SUBMITTED BY
NAME : ___________________________________________________________
ROLL NO : ___________________________ DIVISION : ___________________
SEAT NUMBER : ________________________ ___________________________
Signature of Project Incharge
Academic Year :- 2025 - 2026
1
This page is intentionally left blank.
2
STATISTICS PROJECT PART I & II
[Link].(Computer Science)(2024 Pattern)(NEP)
SEC-101-CS : Statistical Methods for Computer Science I &
SEC-151-CS : Statistical Methods for Computer Science II
Project – Part I.
Data Collection, its condensation and representation using MS-Excel.
For project, a group of maximum 8 students be made. All the students
in a group are given equal marks for project. Different data sets from
primary or secondary sources may be collected.
A report must be made separately for the project.
Part II – Data Analysis is to be performed in Sem II
Instructions :
Step 1 : Data Collection and Data Condensation.
Identify the Population of Interest
Identify the research Question
Collect Data either Primary or Secondary related to your project
topic.
Step 2 : Data Organisation and Presentation
Structure/Clean the data.
If the data is not in tabular form, prepare the tables from the
data.
(Enter the data or import in Excel)
Using tally marks or appropriate software, prepare the frequency
distribution table accordingly.
Structure the data properly (in rows and columns)
for further statistical analysis.
Represent the data using Graphs, Diagrams, etc
3
Instructions :
Step 1 : Data Collection and Data Condensation.
Identify the Population of Interest
Identify the research Question
Collect Data either Primary or Secondary related to your project topic.
Identify the Population of Interest: Determine the group you want to study,
such as customers of a product, a specific demographic, or participants in a
survey. This population will define the scope and relevance of your research.
Identify the Research Question: Frame the core question that your project
seeks to answer. For example, if your project is about consumer behavior,
your research question could be: "What factors influence customer
satisfaction in online retail?"
Collect Data: Gather either primary or secondary data based on your
research question. Primary data can be collected through surveys, interviews,
or experiments, while secondary data can be sourced from government
databases, previous studies, or organizational records.
Condense the Data: Summarize and condense the raw data into
manageable formats. For instance, use sampling techniques if dealing with
large datasets, or group responses for similar questions to simplify data
handling.
4
Step 2 : Data Organisation and Presentation
Structure/Clean the data.
If the data is not in tabular form, prepare the tables from
the data.
(Enter the data or import in Excel)
Using tally marks or appropriate software, prepare the frequency
distribution table accordingly.
Structure the data properly (in rows and columns)
for further statistical analysis.
Represent the data using Graphs, Diagrams, etc
Structure and Clean the Data:
1. Remove Duplicates: Eliminate duplicate records to avoid skewing the
analysis and ensure the dataset accurately reflects unique data points.
2. Correct Errors and Inconsistencies: Check for data entry errors such as
typos or incorrect formats (e.g., text instead of numbers) and correct them to
maintain accuracy.
3. Handle Missing Values: Decide whether to remove, fill, or impute missing
values based on the significance of the data points and the analysis you plan
to conduct.
Prepare Tables:
1. Categorize Data into Logical Groups: If dealing with qualitative data, group
responses or data points into categories such as age groups, income
brackets, or satisfaction levels.
2. Create Rows and Columns with Meaningful Labels: Ensure each row and
column has descriptive labels so that the data is easily understood and ready
for further analysis.
5
3. Convert Non-Tabular Data to Tabular Format: If the data is in paragraph
form or unstructured, reformat it into rows and columns for ease of access
and better organization.
4. Segment Data Based on Relevant Factors: Organize data into sub-tables or
layers for variables of interest, such as sales per region, gender-wise
participation, or time-based entries.
Prepare a Frequency Distribution Table:
1. Group Data into Intervals: For continuous data, group values into intervals
(e.g., 0–10, 10–20) to simplify the distribution and make trends more evident.
2. Create a Cumulative Frequency Table: If necessary, add a column for
cumulative frequency to show how data accumulates across categories,
helping to identify trends over time or groups.
3. Interpret the Table: Use the frequency distribution table to summarize and
understand the overall data distribution, providing insight into which
categories are most frequent.
Graphical Representation:
1. Bar Charts: Use bar charts to compare different categories or groups within
the dataset, especially useful for categorical or discrete data.
2. Histograms: Use histograms to display the frequency of data in continuous
intervals, helping to observe the shape of the data distribution.
3. Scatterplots or Line Graphs: For datasets with two numerical variables, use
scatterplots or line graphs to analyze trends and relationships between
variables over time or across categories.
6
Step 3 : Descriptive Statistical Data Analysis
Calculate Summary Statistics (Descriptive)
Mean, Median, Standard Deviation, Quantiles, etc
Comment on skewness and kurtosis of the distribution.
Obtain the results of your analysis.
Calculate Mean, Median, and Mode: Determine the mean (average), median
(middle value), and mode (most frequent value) of your dataset. These
measures of central tendency give insight into the general behavior of your
data.
Calculate Standard Deviation and Variance: Assess how much your data
deviates from the mean. A larger standard deviation indicates more variability,
while a smaller value shows that data points are closer to the mean.
Compute Quantiles (e.g., Quartiles, Percentiles): Use quantiles to divide
your dataset into equal intervals. Quartiles (e.g., Q1, Q2, Q3) and percentiles
help understand the distribution of your data and identify any potential outliers
if needed.
Skewness and Kurtosis Analysis: Examine the skewness to determine
whether the data distribution is symmetrical or skewed. Evaluate kurtosis to
identify whether the distribution is peaked (leptokurtic), flat (platykurtic), or
normal (mesokurtic).
Obtain and Present the Results: After calculating these descriptive
statistics, summarize your findings. Present any patterns, such as symmetry
or dispersion in the dataset, and document key figures (e.g., mean, standard
deviation).
7
Project – Part II.
Data Analysis
Step 4 : Statistical Data Analysis - II (Semester II)
If appropriate conduct hypothesis test (Inferential Analysis)
Z-Test, T-Test, Paired T Test, Chi-Square Test, etc
OR Carry out Predictive Analysis if appropriate.
Scatterplot, Correlation, Regression, Time Series Analysis
Obtain the results of your analysis.
Conduct Hypothesis Tests: Depending on the nature of your dataset and
research question, conduct appropriate hypothesis tests like Z-Test, T-Test,
Paired T-Test, or Chi-Square Test to validate or reject assumptions. Ensure
the use of statistical significance (p-values) to support your conclusions.
Use Predictive Analysis (if applicable): If predictive analysis is relevant,
create scatterplots, calculate correlation coefficients, and perform regression
analysis (linear, multiple, or logistic). Regression helps quantify the
relationships between dependent and independent variables.
Time Series Analysis (if applicable): For time-based datasets, apply time
series analysis to forecast future trends based on historical data. Techniques
like moving averages, autoregressive models (AR), and ARIMA
(AutoRegressive Integrated Moving Average) can be useful.
Obtain Results: Summarize the key outcomes of your inferential or predictive
analysis. Report test statistics (e.g., t-values, p-values, correlation
coefficients), confidence intervals, and model accuracy, depending on the
method used. Make a clear distinction between significant and non-significant
results.
8
Step 5 : Data Interpretation
Prepare Report on research findings and conclusion.
Interpret the Graphs, Make Decisions and draw Inferences from the
results.
Develop your findings, conclusions.
Prepare the Final Report: Create a detailed report based on your research
findings. Summarize your descriptive and inferential statistics, predictive
analysis, and key insights, ensuring that all major points are tied back to your
research question or hypothesis.
Interpret Graphs and Visualizations: Carefully explain the graphical
representations used, such as bar charts, scatterplots, and histograms.
Highlight any trends, outliers, or patterns observed in the data and discuss
how these visualizations support your findings.
Draw Conclusions and Make Decisions: Use the results of your analysis to
draw meaningful conclusions. These conclusions should directly address your
research question. Based on the statistical findings, make informed decisions
or recommendations for further study or action.
Discuss Limitations and Future Research: Acknowledge any limitations in
your dataset, methods, or analysis. Suggest areas for future research where
more data, different methods, or broader analyses could provide additional
insights.
Develop Practical Implications: Discuss the real-world applications of your
findings, whether they pertain to business, science, policy, or other domains.
For instance, if your research identified key factors in customer satisfaction,
suggest actionable strategies for improving service or product offerings.
Use of non programmable calculator, appropriate software and statistical tables is
allowed. Symbols and abbreviations have their usual meaning.
9
Acknowledgment
I would like to express my heartfelt gratitude to everyone who
contributed to the successful completion of this project. First and
foremost, I thank our professor Ms. Farheen Khan, my project team
members, for their invaluable guidance, constant support, and
encouragement throughout the course of this project. Their insights
and suggestions greatly improved the quality of this work.
I am also deeply thankful to Department of Computer Science,
Ahmednagar College for providing me with the resources and
environment needed to carry out this project.
I am especially grateful to my friends and family, whose continuous
support and motivation kept me going. Lastly, I would like to
acknowledge the participants/respondents who took part in the
research process, for without their cooperation, this project would not
have been possible.
Thank you all.
_________________________
10
A Project on Statistical Analysis of Survey Data
REGRESSION ANALYSIS PROJECT
Introduction
Regression analysis is a predictive modelling technique. Linear regression is
one of the simplest and most common supervised machine learning algorithms
that data scientists use for predictive modelling. The determination of explicit
form of regression equation is the ultimate objective of regression analysis to
make predictions. Regression Analysis can be performed on a variety of
software today. The ubiquitous Microsoft Excel is still by far the most popular
tool. A variety of other free and paid tools are available to run regression
analysis. Some of these include EXCEL, PYTHON, SPSS, SAS, R, Python, etc.
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
11
Introduction
Background of the Study
In today’s data-driven world, statistical techniques such as regression analysis
play a pivotal role in various fields like business, healthcare, economics, and
technology. Regression analysis helps to establish the relationship between
dependent and independent variables, allowing researchers to predict
outcomes and make informed decisions based on available data. This project
focuses on the application of regression models to understand and predict
trends within a specific dataset.
Research Problem and Objectives
The primary objective of this project is to explore the relationship between a
dependent variable and an independent variable, using regression analysis to
model and predict the outcome. The research seeks to address the following
questions:
How strong is the relationship between the dependent variable and the
independent variable?
What is the predictive accuracy of the regression model?
Can the regression model provide valuable insights for decision-
making?
12
The dataset used in this project includes variables, which are crucial for
understanding the context, e.g., consumer behavior, market trends, healthcare
outcomes, etc.
Significance of the Study
This study is significant because it provides practical insights into how
regression analysis can be applied to real-world scenarios. By leveraging
statistical models, businesses and researchers can make data-driven
decisions. For example, understanding how an independent variable affects
the dependent variable and can help organizations optimize strategies,
allocate resources more efficiently, or predict future outcomes with greater
accuracy.
Furthermore, this project offers an opportunity to demonstrate the practical
application of regression techniques in analyzing complex relationships in a
dataset. The findings from this study could be used to improve specific
applications or processes relevant to your dataset.
Scope of the Study
The scope of this study is limited to brief description of dataset or area of
application, with a focus on using regression models to predict outcomes.
Data from primary or secondary sources will be analyzed, and the conclusions
drawn from this analysis will help answer the research questions outlined
earlier.
13
Dataset:
14
Data :
Research Question/Purpose :
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
Data Collection :
________________________________________________________
________________________________________________________
Data Description :
Size of Data : ________ x ________
Number of data values : ____________________________________
Number of missing values : _________________________________
Number of Variables : _____________________________________
Variables : _______________________________________________
________________________________________________________
________________________________________________________
Dependent Variable : (Y) ___________________________________
Independent Variable : (X) __________________________________
Data Visualization :
Graph Used : ____________________________________________
________________________________________________________
________________________________________________________
15
Graph :
Interpretation:
________________________________________________________
________________________________________________________
16
Cleaned Data Table :
17
DESCRIPTIVE DATA ANALYSIS
Number of observations (n) :
∑𝑥 = ∑𝑦 =
∑𝑥 = ∑𝑦 =
∑𝑥𝑦 =
∑𝑥
𝑥̅ = = 𝑥̅ =
𝑛
∑𝑦
𝑦= = 𝑦=
𝑛
∑(𝑥 − 𝑥̅ )
𝜎 = =
𝑛
∑(𝑦 − 𝑦)
𝜎 = =
𝑛
∑
𝜎 = − 𝑥̅ 𝑦 =
18
Correlation Analysis:
𝝈𝒙𝒚
𝒓 =
𝝈 𝒙 . 𝝈𝒚
Coefficient of correlation (r) =
Interpretation:
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
19
R-Squared (R²), also known as the coefficient of determination, is a
statistical measure used to evaluate the goodness of fit in a regression model.
It represents the proportion of the variance in the dependent variable that is
predictable from the independent variables.
Definition:
R² measures how well the regression model explains the variability of the
dependent variable around its mean. It is a value between 0 and 1 (or 0% and
100% when expressed as a percentage):
R² = 1 (or 100%) means that the model perfectly explains the variability
in the dependent variable.
R² = 0 (or 0%) indicates that the model explains none of the variability in
the dependent variable (it’s as good as using the mean of the
dependent variable as a predictor).
Interpretation:
Higher R²: A higher value of R² means the model fits the data well and
can explain a large portion of the variance in the dependent variable.
For instance, an R² of 0.85 (or 85%) means that 85% of the variance in
the dependent variable is explained by the independent variables in the
model.
Lower R²: A low R² suggests that the model does not explain much of
the variance, and other factors not included in the model could be
influencing the dependent variable.
Limitations:
Does not always indicate a better model: A high R² does not
necessarily mean the model is good, as it can increase with more
variables, even if they are not significant predictors.
20
Does not detect overfitting: Adding irrelevant variables can inflate R²
without improving model performance.
Adjusted R²: In multiple regression, the Adjusted R² is often used to
adjust for the number of predictors in the model, preventing
overestimation of the model’s predictive power.
Example:
Suppose you have a dataset where you're predicting house prices based on
variables like the number of bedrooms, size, and location. If your R² is 0.75, it
means 75% of the variability in house prices is explained by these factors. The
remaining 25% could be due to factors not included in your model, such as the
age of the house or local market conditions.
Conclusion:
R² is a useful metric for evaluating how well your regression model explains
the variation in the data. However, it should be interpreted in the context of the
data and the model, considering potential limitations like overfitting and the
complexity of the model.
Coefficient of determination (R2) =
Interpretation:
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
21
FITTING OF SIMPLE LINEAR REGRESSION MODEL
In simple linear regression, we predict scores on one variable from the scores on a second
variable. The variable we are predicting is called the criterion variable or dependent variable
and is referred to as Y. The variable we are basing our predictions on is called the predictor
or independent or exploratory variable and is referred to as X. When there is only one
predictor variable and data follows a linear pattern, the model fitted is called simple linear
regression.
where,
a = y-intercept; b = slope; y = dependent variable; x = independent variable
𝜎
𝑏= 𝑂𝑅
𝜎
∑(𝑥 − 𝑥̅ )(𝑦 − 𝑦) ∑𝑥𝑦
𝑤ℎ𝑒𝑟𝑒, 𝜎 = 𝑂𝑅 𝜎 = − 𝑥̅ 𝑦
𝑛 𝑛
22
𝑎 = 𝑦 − 𝑏 𝑥̅
Steps in Excel to fit a regression line :
Enter Data >> Go to Data Tab >> Analysis >> Data Analysis >> Regression >> Enter Details
>> Click OK >> Output
The equation of the fitted linear regression model is as follows:
𝑦= + 𝑥
a=
Interpretation:
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
b=
Interpretation:
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
23
Hypothesis Testing :
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
24
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
________________________________________________________
25
Conclusion :
___________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
___________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
___________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
26
___________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
___________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
______________________________________________________
27
______________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
28
_____________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
____________________________________________________________
29
30
31
32