AL-405 Machine Learning Lab Manual
AL-405 Machine Learning Lab Manual
Acropolis Institute of
Technology and
Research, Indore
Submitted To:
Department of CSE
Prof. Rishi Acharya
(Artificial Intelligence & Machine Learning)
Submitted By:
0827AL2311xx
ALS-2/2nd Year/ 4th Sem
understanding of estimating the time and space resources needed to execute machine learning algorithms.
CERTIFICATE
This is to certify that the experimental work entered in this journal as per
the B. TECH. II year syllabus prescribed by the RGPV was done by Mr. Yash
1. DO’S
✔ While entering into the LAB students should wear their ID cards.
✔ Students should sign in the LOGIN REGISTER before entering into the
laboratory.
✔ Students should come with observation and record note book to the laboratory.
✔ After completing the laboratory exercise, make sure to shutdown the system
properly.
2. DONT’S
Module1: Introduction to machine learning, scope and limitations, machine learning models,
Supervised Learning, Unsupervised Learning, hypothesis space and inductive bias, evaluation, cross-
validation, Dimensionality Reduction: Subset Selection, Shrinkage Methods, Principle Components
Analysis, Partial Least Squares.
Module2: Neural Networks: From Biology to Simulation, Neural network representation, Neural
Networks as a paradigm for parallel processing Perceptron Learning, Training a perceptron,
Multilayer perceptron, back propagation Algorithm, Training & Validation, Activation functions,
Vanishing and Exploding Gradients.
Module3: Supervised Learning Techniques:- Decision Trees, Naive Bayes, Classification, Support
vector machines for classification problems, Random forest for classification and regression
problems, Linear regression for regression problems, Ordinary Least Squares Regression, Logistic
Regression.
Module5: Design and Analysis of Machine Learning Experiments: Factors, response and strategy of
experimentation, Guidelines for machine learning experiments, cross-validation and resampling
methods, Measuring classifier performance, Hypothesis testing, comparing multiple algorithms,
comparison over multiple datasets
Software Requirements:
RATIONALE:
This subject aims to impart fundamental concepts and practical skills in analyzing and designing
algorithms within the domain of Machine Learning (ML). By covering both theoretical foundations
and practical implementation aspects, students gain a comprehensive understanding of algorithmic
principles specific to ML.
PREREQUISITE:-
Course Outcomes :
1. NumPy:
1. Utilize NumPy arrays for efficient data manipulation and numerical computations.
2. Apply various mathematical functions and operations available in NumPy to analyze data
effectively.
3. Understand and implement basic linear algebra operations using NumPy arrays.
2. pandas:
1. Use pandas DataFrame and Series to efficiently handle and manipulate tabular data.
2. Perform data cleaning, manipulation, and transformation tasks using pandas methods and
functions.
3. Apply grouping, aggregation, and filtering techniques to analyze and summarize data
effectively.
3. Matplotlib:
1. Create various types of plots, including line plots, scatter plots, histograms, and bar plots, using
Matplotlib.
2. Customize plot aesthetics such as colors, labels, titles, and legends to improve
visualization clarity.
3. Understand and apply advanced plotting techniques such as subplots, annotations, and 3D
plotting to visualize complex data relationships.
Index
1
Introduction to Pandas
2
NumPy
3
Matplotlib
4
Car Price Project
5
Diabetes Prediction Project
6
Loan Status
7
House Price Prediction
8
Wine Quality Prediction
Program Outcomes:
2.Able to identify, formulate, and demonstrate with excellent programming, and problem solving skills.
3.Design solutions for engineering problems including design of experiment and processes to meet
desired needs within reasonable constraints of manufacturability, sustainability, ecological, intellectual
and health and safety considerations.
4.Propose and develop effective investigational solution of complex problems using research
methodology; including design of experiment, analysis and interpretation of data, and combination of
information to provide suitable conclusion. synthesis
5.Ability to create, select and use the modern techniques and various tools to solve engineering problems and
to evaluate solutions with an understanding of the limitations.
6.Ability to acquire knowledge of contemporary issues to assess societal, health and safety, legal and
cultural issues.
7.Ability to evaluate the impact of engineering solutions on individual as well as organization in a societal and
environmental context, and recognize sustainable development, and will be aware of emerging
technologies and current professional issues.
8.Capability to possess leadership and managerial skills, and understand and commit to professional ethics
and responsibilities.
9.Ability to demonstrate the team work and function effectively as an individual, with an ability to design,
develop, test and debug the project, and will be able to work with a multi-disciplinary team.
10.Ability to communicate effectively on engineering problems with the community, such as being able
to write effective reports and design documentation.
11.Flexibility to feel the recognition of the need for, and have the ability to engage in independent and life-
long learning by professional development and quality enhancement programs in context of
technological change.
12.A practice of engineering and management principles and apply these to one’s own work, as a member
and leader in a team, to manage projects and entrepreneurship.
Pandas
Q1. Create a Pandas Series named s1 and what will be the datatype of the elements in s1?
Q5. What will be the descriptive statistics (Summary stats) of the series s1?
Q6. What kind of plot is shown, and what does the height of the bar at 0 on the x-axis and tell us
about the data’s distribution?
Q7. How does the creation of s (a pandas Series) differ from the creation of a (a numpy array)?
Q10. Which program execution output presents a Pandas Series of integer values (marks) where
each value is identified by a unique person’s name?
Q13. Write a program to show the segment of ‘sales’ Series by using default indexing?
Q14. Write a program to show the result of adding 10 to every value in the ‘sales’ series?
Q15. Write a program to show a python dictionary where names are associated with Numerical
height values?
Q16. Write a program for creation and display of a Pandas DataFrame with multiple Columns,
including ‘Name’ , ‘Sex’ , ‘Height ’, ‘Weight ’, and ‘Salary’?
Q17. Write a Program to show a Pandas DataFrame where the original numerical row labels have
been replaced by the names from the ‘Name’ Column?
Q18. Write a program to visually represents the ‘Salary’ data from the df1 DataFrame as a bar chart?
Q19. Write a program to illustrate how to retrieve a single data point from a DataFrame using both
its numerical position and its corresponding row and column labels?
NUMPY
Q.1 How to create array in numpy library of python?
Q. 2 Write a program to create 1 Dimensional Array and find minimum and maximum element.
Q. 3 Write a program to create 1 Dimensional Array and find size, shape, dtype, ndim and data.
Q.4 Write a program to create 1 Dimensional array and find Statistical
Q.8 Write a program to create two 2-Dimensional array and perform Multiplication
operations on them
Matplotlib
Q.1 What is the simplest way to create a basic line plot with matplotlib?
Q. 2 How can you set the facecolor of a figure? Provide examples of different colors used.
Q. 3 How do you label the x-axis and y-axis of a plot? How do you set the color of individual
lines in a plot?
Q. 4How do you plot sine and cosine functions on the same graph?
Q.5 How do you set the x-ticks and y-ticks on a plot? What does ax.grid() do? How do you
add a label to a plotted line (e.g., 'square', 'cube')?
Car Price
(Linear Regression and Lasso Regression)
Diabetes Prediction (Logistic Regression)
House Price Prediction
(XGBoost for Regression)
Wine Quality Prediction
(Random Forest Classifier)