File Exchange

image thumbnail


version 1.4 (306 KB) by

Toolbox for automated sorting of cellular calcium signals from optical imaging data.



This toolbox includes routines for using principal component analysis (PCA) and independent component analysis (ICA) to extract cellular signals from imaging data sets. A full description and validation of the method is provided in the paper, "Automated Analysis of Cellular Signals from Large-Scale Calcium Imaging Data," Neuron, 63:747 (2009):

Comments and Ratings (8)

Eran Mukamel

Dear Phanindra - You can find sample code that will illustrate the appropriate parameters here:

The processing time depends on the size of your data set. The majority of computation time is in the PCA dimensional reduction pre-processing; subsequent cell sorting is relatively fast.

I need to image segment a tiff calcium image data.I am unable to correctly specify the parameters smwidth and thresh? Can u please tell me what are the typical values? Also how much time does it take to run the whole code till segmentation?

What does movm and movtm mean?

Eran Mukamel

Hi Alex - The CellSortPCA function requires a TIFF image stack.

What file input is necessary for CellSortPCA to work?


Sheng (view profile)


The associated publication in Neuron 63, 747–760 makes this look promising. However, getting this to run based on the instructions provided in the supplementary publication is very trying for those with less than a mastery of Matlab.

Rob Campbell

Rob Campbell (view profile)

These functions are well presented and a lot of care has gone into the code. Well worth a look. However, I have had trouble getting this to work reliably with my data since it has tendency to identify noise as the signal.



June 2016: Fixed an inconsistency in CellsortPCA between create_tcov and
creat_xcov. In the current version, both methods agree with the previous
version of create_tcov.


Fixed a bug affecting performance in recent versions of MATLAB.


Fixed a minor typo in documentation for CellsortICA - EAM 11/24/09

MATLAB Release
MATLAB 7.7 (R2008b)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Win prizes and improve your MATLAB skills

Play today