Code Monkey home page Code Monkey logo

cellsorter's Introduction

CellSorter

Classification using UMAP and k-means

This small MATLAB utility sorts cells into different clusters by their waveforms. It performs dimensionality reduction on averaged waveform snippets, and clusters using a k-means algorithm.

Installing

You can clone or download this repository and add it to your MATLAB path. It requires the mtools repository, and optionally requires RatCatcher, and CMBHOME for use with the RatCatcher data pipeline.

Usage

A CellSorter object can be instantiated the normal way:

cs = CellSorter;

You can dimensionally reduce data using the dimred function.

Y = cs.dimred(X);

The data, X, should be an M x N matrix, where M is the number of observations, and N is the number of features.

You can cluster the dimensionally-reduced data using the kcluster function.

labels = cs.kcluster(Y);

If you are using the RatCatcher data pipeline, you can use the supplied batch function for the CellSorter protocol. This will automatically gather waveform snippets from specified CMBHOME Session objects.

Properties

CellSorter contains several properties:

sset

This property contains a struct generated by the statset built-in function. It contains general properties for clustering algorithms (in this case, k-means).

nClusters

This property counts the number of desired clusters to be found. This is the 'k' in k-means.

nDims

This property counts the number of desired dimensions for dimensionality reduction. It is generally advisable to keep this set to the default of 2.

verbosity

A logical flag -- verbosity = true means CellSorter will output more informational text.

algorithm

Which dimensionality-reduction algorithm to use? CellSorter supports pca, t-SNE, FIt-SNE, and UMAP. For fast-Fourier transform-accelerated interpolation-based t-SNE, you will need the FIt-SNE package. For uniform manifold approximation and projection, you will need the UMAP MATLAB wrapper.

cellsorter's People

Contributors

alec-hoyland avatar hdannenb avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.