hyl0428 / ML-Assignments

0 stars 0 forks source link

Thanks! #1

Open coderschoolreview opened 5 years ago

coderschoolreview commented 5 years ago

Awesome good work :D

coderschoolreview commented 5 years ago

could be written in shorter form : sum(ecom['Job']=='Lawyer')

coderschoolreview commented 5 years ago

overall, all answer are correct. great work :D

coderschoolreview commented 5 years ago

Assignment 4:

Visualization:

Should've plot in different plot. Sample code:

# Distribution of length between 3 species: 
## list of species
ls = list(data.Species.unique())

plt.rcParams['figure.figsize'] = (20,5)
f,axes = plt.subplots(1,4)

i=0;
for v in ('SepalLengthCm','SepalWidthCm','PetalLengthCm','PetalWidthCm'):
    plt.sca(axes[i])
    axes[i].set_title(v)

    for s in ls:
        sns.distplot(data[data.Species==s][v],
                     hist=False,
                     label=s
                    )
    i+=1

plt.legend()
plt.show()
coderschoolreview commented 5 years ago

coderschoolreview commented 5 years ago

Model:

Linear Regression only work for binary classification (you only have 2 classes) In this case you have 3.

Ref: https://www.quora.com/Can-you-do-multiclass-classification-with-logistic-regression

coderschoolreview commented 5 years ago

hyl0428: Assignment 5

The goal of this assignment was to introduce you following concepts in Machine Learning:

Things you did well

Things to work on

Minor tips

coderschoolreview commented 5 years ago

Assignment 6

Goal of this Assignment

The goal of this assignment was to introduce you to following concepts:

You learn how to use PCA for dimension reduction, KMeans, and Hierarchical Clustering. Also you learn to visualize the result of both tenichque.

Things you did well:

To sum up:

Few minor tips

To create a range of integer, use range(low,high,step)

k_values = range(1,20)

To access first columns of pca_data, use pca_data.iloc[:,0] or pca_data['PC1']. pca_data[:,0] is wrong way of slicing a dataframe, hence the error.