An algorithm for unsupervised discovery of sequential structure
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
+helper
misc_elm
.gitignore
COSYNE_slides.pdf
LICENSE
MackeviciusData.mat
README.md
SimpleWHPlot.m
WHPlot.m
demo.m
generate_data.m
seqNMF.m
synthetic_data_example.m
test_significance.m

README.md

seqNMF

Unsupervised discovery of temporal sequences in high-dimensional datasets, with applications to neuroscience

Emily Mackevicius and Andrew Bahle - FeeLab 🎶 🐦 2018

Description

SeqNMF is an algorithm which uses regularized convolutional non-negative matrix factorization to extract repeated sequential patterns from high-dimensional data. It has been validated using neural calcium imaging, spike data, and spectrograms, and allows the discovery of patterns directly from timeseries data without reference to external markers.

For more information see our preprint; COSYNE talk; tutorial video and materials; and Simons foundation article.

Usage

The main function is seqNMF.m and it can be called

[W,H,cost,loadings,power] = seqNMF(X,'K',K,'L',L,'lambda',0.01)

Where X is the data matrix, K and L are the factorization parameters and lambda is a parameter controling the strength of regularization.

Specifically seqNMF factorizes the NxT data matrix X into K factors. Factor exemplars are returned in the NxKxL tensor W. Factor timecourses are returned in the KxT matrix H

                                ----------    
                            L  /         /|
                              /         / |
    ----------------         /---------/  |          ----------------
    |              |         |         |  |          |              |
  N |      X       |   =   N |    W    |  /   (*)  K |      H       |           
    |              |         |         | /           |              |
    ----------------         /----------/            ----------------
           T                      K                         T

Demo

See the demo script, for a demonstration of the seqNMF algorithm on synthetic data and songbird imaging data. This demo also gives examples of how to cross validate, test for significance and select parameters.