Skip to content

ntueeboyz/DBSCAN-and-t-SNE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DBSCAN-and-t-SNE

In here, I used the MNIST data to demostrate tSNE and DBSCAN algorithms.

The main function imports the MNIST csv file and reduces the high dimensionality to 2-D. Then plots the t-SNE figure with labels and the t-SNE figure with DBSCAN clustering.

The file includes two functions, DR_Plot and DR_Plot_black.

DR_plot: Input sample labels, n x 2 embedded array, and the "filename" you want to save. The output would be the scatter figure with color label depending on samples.

DR_plot_black: Input sample n x 2 embedded array, and the "filename" you want to save. The output would be the scatter figure.

To import the MNIST csv file and output with the data matrix and sample labels.

Result

t-SNE with sample labels

Image description

t-SNE clustered by DBSCAN

Image description

About

An instance shows the clustering and classification of multi-dimensional data

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages