ML_Assignment_4.pdf

pdf

School

Drexel University *

*We aren’t endorsed by this school

Course

613

Subject

Computer Science

Date

Feb 20, 2024

Type

pdf

Pages

1

Uploaded by CaptainMantisMaster961

Report
Machine Learning Assignment 4 - Linear Discrimenant Analysis Fall 2023 Solution: Write a script that: Implementation Details Meet Sakariya - 14473322 1 Linear Descriment Analysis (LDA) Classifier Precision: 0.8769497400346621 Recall: 0.8784722222222222 F-measure Score: 0.8777103209019947 Training Accuracy: 0.9103650586701434 Validation Accuracy: 0.9080234833659491 1 1. Seed the random number generate with zero prior to randomizing the data 1. Reads in the data. 2. Randomizes the data. 3. Selects the first 2/3 (round up) of the data for training and the remaining for validation. 4. Deterimines the optimal direction of projection for linear discriminant analysis. 5. Classifies each validation sample by projecting it and assinging it the class whose training post-projection mean it is closes to. 6. Computes the accuracy of the training and validation data and the precision, recall, and f- measure for the validation set. Your only task in this assignment is to implement, train and test a Linear Discriminant Classifier. Download the dataset spambase.data from Blackboard. As mentioned in the Datasets area, this dataset contains 4601 rows of data, each with 57 continuous valued features followed by a binary class label (0=not-spam, 1=spam). Your code should work on any dataset that lacks header infor- mation and has several comma-separated continuous-valued features followed by a class id 0,1.
Discover more documents: Sign up today!
Unlock a world of knowledge! Explore tailored content for a richer learning experience. Here's what you'll get:
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help