Starting from:

$25

CSE 417T -hw3 -Solved

 Implement the functions in the two files. Remember to check in the final version ofyour code for these two files.

•    Read more about the “Cleveland” dataset we’ll be using here:ics.uci.edu/ml/datasets/Heart+Disease         https://archive.

•    Learn a logistic regression model on the data inabout the fact that the classes are 0/1 – you should convert them toclevelandtrain.csv1/ +1(be carefulso that everything we’ve done in class is still valid). Apply the model to classify the data (using a probability of 0.5 as the threshold) in clevelandtest.csv. In your writeup, report Ein as well as the classification error on both the training and test data when using three different bounds on the maximum number of iterations: ten thousand, one hundred thousand, and one million. What can you say about the generalization properties of the model?

•    Now train and test a logistic regression model using the inbuilt matlab function(learn about and use the “binomial” option, and check the label format). Compare theglmfit results with the best ones you achieved and also compare the time taken to achieve the results.

•    Now scale the features by subtracting the mean and dividing by the standard deviationfor each of the features in advance of calling the learning algorithm (you may find the matlab function zscore useful). Experiment with the learning rate ⌘ (you may want to start by trying different orders of magnitude), this time using a tolerance (how close to zero you need each element of the gradient to be in order to terminate) of 10 6. Report the results in terms of number of iterations until the algorithm terminates, and also the final Ein.




More products