Giter Site home page Giter Site logo

wave_clus's Introduction

Wave_clus 3

Wave_clus is a fast and unsupervised algorithm for spike detection and sorting that runs under Windows, Mac or Linux operating systems.

To install, download this repository into a folder. In MATLAB (R2009b or higher) go to Set Path and add the directory wave_clus with the subfolders to the MATLAB path.

How to use

There are two ways to use Wave_clus:

  1. To open the GUI, type wave_clus in the MATLAB command prompt.

  2. To use the batch functions, type Get_spikes('filename.ext'), where .ext is a file extension (eg. .mat), for the spike detection; this will save a file filename_spikes.mat in the current directory. Subsequently, run Do_clustering('filename_spikes.mat') to do the sorting. You can process multiple files at once or specific channels of multiple files.

Wave_clus can read raw data or already detected spikes generated with electrophysiology data acquisition systems (Blackrock, Neuralynx, Plexon, TDT, Intan, etc) or saved as matlab files (*.mat). It can also deal with tetrodes and high-density probes. See the Wiki page for Input Files for more details.

Either way, wave_clus generates a file times_filename.mat, with a variable cluster_class of two columns: the first column is the class of the spike and the second one is the spike time in ms.

Wave_clus is free (and therefore without any warranty) for any non-commercial applications. For any commercial application please contact Prof. Rodrigo Quian Quiroga.

Important links

Questions, problems and suggestions: issues section.

More instructions, details, FAQ and developer information: wiki.

References

How to cite

A novel and fully automatic spike sorting implementation with variable number of features. F. J. Chaure, H. G. Rey and R. Quian Quiroga. Journal of Neurophysiology; 2018. https://doi.org/10.1152/jn.00339.2018

@article{doi:10.1152/jn.00339.2018,
  title={A novel and fully automatic spike sorting implementation with variable number of features},
  author={Chaure, F. J. and Rey, H. G. and Quian Quiroga, R.},
  journal={Journal of Neurophysiology},
  year={2018},
  volume={120}, 
  number={4}, 
  pages={1859-1871}, 
  doi = {10.1152/jn.00339.2018},
}
For a non technical reference about spike sorting see:

Quick guide: Spike Sorting
Quian Quiroga, R.
Current Biology, Vol 22. R45–R46, 2012.

Spike Sorting
R. Quian Quiroga
Scholarpedia 2 (12): 3583. 2007

wave_clus's People

Contributors

ferchaure avatar happyfacade avatar kouichi-c-nakamura avatar tsieger avatar yguo29 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wave_clus's Issues

Sampling rate

Does anyone have any thoughts on the effect of sampling rate (20 vs 30 kHz) on the ability to sort spike recorded from single channel electrodes (i.e., no tetrode/polytrodes?)

Independent functions

Hi,
Would you have a separate version of the wavelet feature extraction and the superparamagnetic clustering I could use independently from the GUI.
I have a set of pre-detected and cut spikes and would really like to see how those methods perform compared to what we already use. (and it doesn’t very fit to use the full original recording)

I have looked a bit under the hood of your code and I think I could “disassemble” the parts I need, but if you already have them (and especially a description of the shape the inputs/outputs takes), it would be much simpler.

Thanks for your wonderful tool!
Best,
B

The way to discriminate (reject) pseudo (false) spike?

Hi, I am not sure if I can ask this type of question here though, I will try anyway.
Recently I am wondering which cluster to exclude from the further analysis.

For example in this case, I will take cluster 1, but I will reject cluster 2 and 3
because their shape don't look like spikes. Do you agree with my decision?
ideal

In another case, I will take cluster 1.
Then maybe I will reject cluster 2 because the spike shape on the 3rd channels doesn't have a negative peak, and the distribution of the magnitude of spike looks similar to that of cluster 1,
and cluster 2 has much fewer number of spikes... cluster 2 might be a part of cluster 1 population?
Further, I wonder if I should reject cluster 3 because the distribution of ISI has 2 peaks
and its spike shape doesn't look like a real spike??
wave_clus

Next, this is the 3rd case. I will take cluster 2 especially because the second channel shows clear spike shape, but I will reject cluster 3 because its wave form seems like noise.
But the problem is cluster one. In channel 3, there is a big "spike?" but
ISI distribution looks zigzag. So should I reject it too?
zigzag

Setting new parameters does not affect the current session

When setting new parameters using the Set parameters button, the new parameters do not take immediate effect, but apparently take effect after new data loading.
It would be nice if some parameters, e.g. the parameters controlling the "force membership" feature (e.g. par.template_sdnum) or plotting parameters (e.g. par.to_plot_std or par.max_spikes_plot) could be set on the fly, such that the user could immediately see their effects for the clusters identified currently, without a need to reload the signal and re-apply operations leading to the given clusters.

amplitude of spikes

Hi,

I was using wave_clus to sort the spikes, and divided the recording time as firing rate.
It was very helpful, thank you very much.

Recently I was trying to quantify the amplitude of spikes.
Do you know have any idea how to do that?
Is there a matrix that indicates the amplitude so that I can use max-min maybe?

Thanks!

Batch Files & Plotting

Is there an option or a place to edit the batch file Do_clustering so that all of the clusters are plotted and saved to file automatically, without using the GUI?

Spike Formatting

Hi,

I am interested in using your spike clustering software for my research on weekly electric fish, but I am having a difficult time formatting my data in a way the program can read. I have spikes already in MATLAB, but I keep getting an error stating that fewer than 15 spikes have been detected when I try to load the data into the gui interface. I have 214 spikes. I saw in the powerpoint that there was an example file (test1_spikes.mat) to format the data, but I could not find this file. Could you please tell me how I can format my data to be read by the program?

Thanks!

'Manual' cluster selection is not intuitive

It is great to have a way of manually selecting spikes. However, I found the behaviour counter-intuitive.

The 'Manual' function currently selects spikes whose maximum or minimum over given selected x-range resides inside the given rectangle (drawn manually).

IMHO, a more intuitive way of selecting spikes would be to select spikes that pass through the rectangle.

For example, the current implementation does not enable to select well-defined spikes coinciding with the red rectangle, because both the maxima and minima of most of the spikes over the selected x-range are outside the rectangle:

manual_issue

Error importing .nse file

Hi

I recorded spike data saved as .nse. The import works with FieldTrip but not wave_clus. How can I fix this issue? Should I import with FieldTrip instead and reformat to a wave_clus compatible .mat file (if yes, how should it be structured)? The full MATLAB error message is at the end (using GUI). You can download an example file from here:
https://www.dropbox.com/s/yt9wgqpr4r07o6j/sPHL1.nse (12MB)
As reference: When using FieldTrip
spike = ft_read_spike('sPHL1.nse','spikeformat','neuralynx_nse');
shows that 110380 spikes are detected in that channel.

Thanks a lot for help!
Matthias

I use the latest wave_clus download from GitHub and Matlab 2016b.


Error using nse_wc_reader
Too many input arguments.

Error in readInData (line 97)
obj.file_reader = eval([ext(2:end) '_wc_reader(obj.par,obj.par.filename)']);

Error in wave_clus>load_data_button_Callback (line 160)
data_handler = readInData(handles.par);

Error in gui_mainfcn (line 95)
feval(varargin{:});

Error in wave_clus (line 63)
gui_mainfcn(gui_State, varargin{:});

Error while evaluating UIControl Callback

Loading data problem

Firstly, thanks for providing this great toolbox!!!

Basicly I want to do some spike detection and sorting work. But I have some problem on the begining stage.

Wave_clus didn't find a sampling rate in file. It will use the set in set_parameters.m
Error using wave_clus>load_data_button_Callback (line 221)
Less than 15 spikes detected

Error in gui_mainfcn (line 95)
feval(varargin{:});

Error in wave_clus (line 63)
gui_mainfcn(gui_State, varargin{:});

I guess this is the problem of my input .mat file. I read the introduction pdf and I am kind of confused that I must provide the spike times? So I need provide the result of spike detection into the mat file then I can use the toolbox? Cause right now I only have the single channel data in mat file.

Sorry I am new guy in this field so maybe I asked many silly questions. Any help will be appreciated!

Files load as read only for plotting

Hi,
I am recording data using a BlackRock system then converting single channel files using parse_data_NSx.m. Sometimes this works and allows me to open the files in wave_clus. However I have now started getting an error which comes up as 'Segment read only for plotting' which means the data I open can't be edited. Each time I open a file using load in wave_clus, no matter how I set and save the parameters it opens the same way and can't be changed. Once this happens any data file opens in the same way.
Thanks in advance!

Batch processing of Do_clustering

When I perform Do_clustering for each single plytrode, the procesing seems successfully completed
as follows.

Do_clustering(1);
0 of 1 'times' files finished.
Computations Done. Creating figures...
1
Do_clustering(2);
1 of 1 'times' files finished.
Computations Done. Creating figures...
1
Do_clustering(3);
1 of 1 'times' files finished.
Computations Done. Creating figures...
1
Do_clustering(4);
0 of 1 'times' files finished.
Computations Done. Creating figures...
1
Do_clustering(4);
0 of 1 'times' files finished.
Computations Done. Creating figures...

1

But when I am try to do the same in batch mode,
some warning came up. Do you know why?

Do_clustering(1:4);
Warning: File not found or permission denied
In run_cluster at 105
In Do_clustering>do_clustering_single at 419
In Do_clustering>(parfor body) at 131
In parallel_function>make_general_channel/channel_general at 922
In remoteParallelFunction at 28
0 of 4 'times' files finished.
Warning: File 'data_polytrode2.dg_01.lab' not found.
In run_cluster at 8
In Do_clustering>do_clustering_single at 419
In Do_clustering>(parfor body) at 131
In parallel_function>make_general_channel/channel_general at 922
In remoteParallelFunction at 28
Warning: File 'data_polytrode2.dg_01' not found.
In run_cluster at 9
In Do_clustering>do_clustering_single at 419
In Do_clustering>(parfor body) at 131
In parallel_function>make_general_channel/channel_general at 922
In remoteParallelFunction at 28
0 of 4 'times' files finished.
0 of 4 'times' files finished.
Warning: File 'data_polytrode1.dg_01.lab' not found.
In run_cluster at 8
In Do_clustering>do_clustering_single at 419
In Do_clustering>(parfor body) at 131
In parallel_function>make_general_channel/channel_general at 922
In remoteParallelFunction at 28
Warning: File 'data_polytrode1.dg_01' not found.
In run_cluster at 9
In Do_clustering>do_clustering_single at 419
In Do_clustering>(parfor body) at 131
In parallel_function>make_general_channel/channel_general at 922
In remoteParallelFunction at 28
0 of 4 'times' files finished.
Computations Done. Creating figures...
1 2 3 4

Batch files

I am not really understanding the batch files option. I am recording with a multi-electrode array and would like to run spike detection on all of my electrode with a set SD for the entire array. The voltage data from each electrode is saved in a .mat file with a variable known as "data." I'd like to run spike detect on the .mat files saved in the directory. Can this be done with the batch files and how?

Reproducibility of results

Hello and thanks a lot for this software!

I was wondering if there is a way to make the results from Wave_clus reproducible, in the sense that, when the program runs on the same file, with the same parameters, the two times_* output files are identical.

I tried to fix par.randomseed to a number(not zero of course) and also rng before calling the program, still the results after clustering are slightly different. As far as I understand the only randomness should be in the clustering algorithm and perhaps setting par.randomseed doesn't work because the program uses an external .exe file?

Any possible solution to this?
Thanks in advance.

Cannot load data

Hi,
I have some data pre-detected, and I put these data into one mat file containing index and spikes, but when I load the file, error occurs saying Subscripted assignment dimension mismatch..I tried several times, and I found that if I set the waveform length to maybe 64 points, this error does not occur, but my data has 320 points per waveform, what can I do?

loading simulated data

Hi,
when I load any of simulated data, Matlab gives me this error:
Unable to read file 'data_wc.dg_01.lab': no such file or directory.
and I can't do further processing, any suggestion?
thanks

About simulate dataset

Hi!
I am sorry to ask this question here. From your webpage you still provide the similated dataset to help us to understand the wave_clus tool. But I cannot understand the structure of simulated data. For example, after loading mat. file, the spike_times providing in ground_truth can not be consistent with the peak value of raw data. So I am asking the spike_times providing in ground_truth represent the index of raw data or other else??

Thanks for your help....

batch processing output spike feature instead of spike shape

Hi,

Now the batch processing is working perfect fine.
The output screen shot like picture is very helpful.
However, I was wondering if it can show the spike feature instead of spike shape, just like I can switch it in the GUI. (the first figure, on top of the temperature figure)

Thanks a lot!

Plot polytrode button unresponsive

Hi all, the "Plot polytrode" button doesn't work (or at least if I click it does nothing). Maybe I'm using a wrong configuration? I can not figure it out because I have no clue on what I can get with it...

Problems using TDT

Hi, I'm a new user trying to analyze my data with wave_clus.

I'm having trouble from the start. I have a few questions about the problems.

  1. It seems that wave_clus only supports data with 1 channel, but my data has more! So I tried to use the parse_data_tdt function, but it won't work due to the availability of memory. Is there a solution to this because in the future I'll be analyzing a much bigger data than this.

  2. As 1 didn't work, I tried splitting up data into channels in ASCII format. But wave_clus acquires only .mat files, so I'm trying to convert it to an appropriate format. In the introduction, it says that it should be in a vector named data (this is where I don't get, what does this mean?)

  3. Also I tried using Raw_data_reader for TDT files but I don't get what input I should write for the function. (The function , tdtch_wc_reader(par, raw_filename), what should I put in par?)

I would be glad to have help on these problems!

sorting error

I am sorting some spikes using Wave_Clus and came across an error. I ‘fixed’ cluster 1 and then tried to force into clusters 2 and 3 as on the screenshot below and got:
Could you please help.
todor

Index exceeds matrix dimensions.

Error in plot_spikes (line 178)
oclass = clustering_results(ind(1),4); % get original
class

Error in wave_clus>force_button_Callback (line 1163)
plot_spikes(handles);

Error in gui_mainfcn (line 95)
feval(varargin{:});

Error in wave_clus (line 61)
gui_mainfcn(gui_State, varargin{:});

Error while evaluating UIControl Callback.

std smaller than default bug ..

Hi there,

when setting std_min smaller than default I sometimes run into the following error:
Do you have any idea why this happens ?

Subscripted assignment dimension mismatch.

Error in plot_spikes (line 216)
clustering_results(:,2) = classes;

Error in wave_clus>load_data_button_Callback (line 331)
plot_spikes(handles); %This function edit userdata

Error in gui_mainfcn (line 95)
feval(varargin{:});

Error in wave_clus (line 63)
gui_mainfcn(gui_State, varargin{:});

Error while evaluating UIControl Callback

batch processing

Hi,

  1. I was reading the batch processing comments, it says:

'all', in this case the functions will process all the
% supported files in the folder (except .mat files).

Does that mean the batch processing could'd do .mat files?
All my data are stored in .mat files.

  1. In the: Get_spikes([1:8 33:56],'parallel',true,'par',param); from the example you gave,
    what is [1:8 33:56]?

Thanks a lot!

Problem with Polytrode Data

I'm trying to use wave_clus to do some polytrode sorting. However, I'm running into some problems, and was wondering if I could get some help on the issue. Some background first:

-We're using an 8 shank polytrode, with a total of 64 sites. I've been trying to sort all the channels on a single shank (8 channels total).

  • I'm first separating the data into a series of mat files, with one mat file containing all the raw, unsorted data per channel.
  • Then, I create an ASCII formatted text file which has all the file names in it, as an index for wave clus, as per the instruction sheet.
  • I then run Get_spikes_pol(1) and Do_clustering(1) in MATLAB, which gets the final output of times_polytrode1.mat.

After this, I try to visualize the data by loading it into the wave_clus GUI. The data loads in fine, but when I press the "Plot polytrode" button, firstly, the new window that pops up only shows one channel (see attachment "polytrode window"). Simultaneously, I get an error in matlab (see attachment "matlab error"). I've also attached a screenshot of the wave_clus window before I press "plot polytrode" (see attachment "waveclus window"). Lastly, I have attached the text file 'polytrode1.txt'.

Any clue what's going on?

polytrode1.txt
waveclus window
matlab error
polytrode window

GUI of wave-clus does not produce new figures after I loaded new times_polytrode.

I have used wave clus in batch mode for many months, and it has worked very well so far.
Recently I clicked "save" on the GUI of wave_clus by mistake (saved as matlab figure file)
, since then the initial screen of GUI always contains the data which I saved by mistake.
But it still worked if I loaded a new data.

However today after my 1st analysis,
even I loaded new data on GUI, it didn't make new figure anymore
(the figure which I saved by mistake persisted, so initial image of GUI does not change).

Do you have an idea to fix this symptom?
Error message is like this;


Index exceeds matrix dimensions.

Error in wave_clus>load_data_button_Callback (line 242)
clu_aux(:,ipermut+2) = clu(:,(1:length(ipermut))+2);

Error in gui_mainfcn (line 96)
feval(varargin{:});

Error in wave_clus (line 63)
gui_mainfcn(gui_State, varargin{:});

Error while evaluating uicontrol Callback

Do_clustering Batch Files

I have a .txt file containing the filenames:
nless_spikes.mat
test_spikes.mat

When using Do_clustering('File.txt'), I keep getting this error message regardless of what I do:
Error using readInData (line 124)
Reference to non-existent field 'ref_ms'.

This value is par.ref_ms is present in set_parameters. Are they loaded automatically or do I need to load them prior to batch clustering?
Thank you for your help!

Batch files Get_spikes & Do_clustering

Hello,

I meet some difficulties with the spikes sorting. I have used the GUI but I want to use the method on my signal without it. The format of ma data is like... a vector (1*N), N being the length of my signal (.mat).
I use Get_spikes() and Do_clustering() and I don't understand the format of the input... Do I need to put only a vector ? Because in the beginning of the code, it is written :

% input must be:
% A .txt file with the names of the files to use.
% A matlab cell with the names of the files to use.
% A vector with channel numbers. In this case the function will proccess all the
% supported files (except .mat files) located in the folder with those
% channel numbers (e.g., CSC1.Ncs or NSX4.NC5)
% 'all', in this case the functions will process all the
% supported files in the folder (except .mat files).
% optional argument 'par' and the next input must be a struct with some of
% the detecction parameters. All the parameters included in the structure
% par will overwrite the parameters loaded from set_parameters()
% optional argument 'parallel' : true for use parallel computing

Thanks

wave_clus: GUI temperature setting

Hello,

I have a more general question about using the wave_clus temperature setting on the GUI.

I am having a hard time understanding how the temperature works. My plan was to play with my data on the GUI to get the right temp. and see if the spikes I have in the selected cluster detects the spikes that are outside of my noisy periods (I have a lot of noisy periods). When I'm happy I want to do a batch processing.

Now the problem is when I want to do batch processing, where do I go and look at the temperature I used so that I can apply it to all my data?

Thank you in advance for your help.

Seb

Error unsolved for some signal

Good morning,

I use Get_spikes() and Do_clustering() functions and it works perfectly for some signals. However, it does not work for some microelectrode signals I have. The path is correct but I don't know how to fix the following problem :


Deletion requires an existing variable.

Error in amp_detect (line 115)
index(aux)=[];

Error in Get_spikes>get_spikes_single (line 176)
[new_spikes, aux_th, new_index] = amp_detect(x, par);

Error in Get_spikes (line 126)
get_spikes_single(filename, par_input);


Could you help me ?

Thanks.

Spike time (ms) after Do_clustering

Hello,

I am new to wave_clus and I was wondering if any of you could be of help.

I have recordings done by Neuralynx so I have a folder with .ncs files (e.g. CSC01.ncs). I used the following code to run the 'Get_spikes' and 'Do_clustering' m-files. As a proof that I have spikes detected, I wanted to get the time at which the detected spikes occurred and wanted to overlay them over my raw traces. I went to 'times_CSC01.mat' file that is saved already --> then opened 'cluster_class', where I got the clusters and the 'spike times' in millisecond (i.e. cluster_class (: , 2).

The problem happens here as I keep getting values (time-stamps) larger than what is recorded as the last data in my original trace. Example: Last data point in raw file = 22, 063, 615 time-frames ; first spike recorded using wave_clus occurs at = 119, 108, 528 time-frame.

N.B: 1 time-frame = sampling rate * 1 second

I made sure that the par.sr is set as 16000, which is the sampling rate recorded. Is there anything that I'm not doing right? I can't seem to bypass this issue.

Any help would be greatly appreciated.

Thanks,

Seb

polytrodes1.txt issue

Hi. I'm trying to process my data using Get_spike_pol function.

In the instruction, it says to make a textfile named polytrodes1.txt with .mat files to concatenate.

I wonder where this textfile should be located for the matlab function to work.

Where should I put it?

Run wave_clus

Is there anyway I run wave_clus without GUI, i.e., I want to give wave_clus my data and set of parameters (e.g., temperature, min cluster size, threshold and so on ) and then get the clustered data as output.
Also how can I have the shape of each cluster that has been clustered as an out-put.
Thanks

Loading data to GUI from Matlab script

Hello,

I am trying to automatize my code as much as possible, however, from time to time I will need to change the temperature when running in batch mode. What is the best way to automatically load a given 'times_.....mat' file to the GUI so when it opens (by just adding wave_clus() in a line of my script) there is no need to click on Load and search for the file?

Thank you,
Enrique

Wave_clus not running in Ubuntu 14.04 LTS

Hi,

I'm trying to run wave_clus in Ubuntu 14.04 with Matlab R2012a and it looks like that it can't run the spc after calculating spike features.

I'm getting the following error:

/bin/bash: /.../cluster_linux64.exe: Permission denied

Error using load
Unable to read file data_wc.dg_01.lab: No such file or directory.

Error in run_cluster (line 107)
clu = load([fname '.dg_01.lab']);

Error in wave_clus>load_data_button_Callback (line 233)
[clu,tree] = run_cluster(handles.par);

Error in gui_mainfcn (line 96)
feval(varargin{:});

Error in wave_clus (line 63)
gui_mainfcn(gui_State, varargin{:});

Error while evaluating uicontrol Callback

I've looked through run_cluster in debug mode and it can't run this cluster_linux64.exe. This is happening even when I run MATLAB as super user.

Any ideas to fix this?
Regards,
Eliezyer

error nan and inf not allowed.

Hi Fernando, I am trying to load a data.mat file using your latests Wave_clus version and get the following message. I've checked the file and it doesn't contain any inf or NaNs. In fact the file sorted with a previous version of Wave_clus ( wave_clus_2.0wb). I wonder if I've messed up the parameter file?..
capture
Thanks a lot!
Todor

TDT tank or NEX files to open

Hi

I’m acquiring multichannel recordings with TDT devices and I obtain a TDT Tank. I want to use wave_clus for spike sorting. I read in the Wave_clus pdf that there is possible to open this tank but when I try to do it, I have this message:

parse_data_tdt('C:\Users\Mariano\Desktop\1_tirar\1a');
Maximum possible array: 3965 MB (4.157e+009 bytes) *
Memory available for all arrays: 3965 MB (4.157e+009 bytes) *
Memory used by MATLAB: 442 MB (4.632e+008 bytes)
Physical Memory (RAM): 8071 MB (8.463e+009 bytes)

  • Limited by System Memory (physical + swap file) available.
    ??? Error using ==> parse_data_tdt at 46
    Error opening block

I have another possibility exporting the tank as Neuronexus file and then open it in Matlab with a routine (http://www.neuroexplorer.com/downloadspage/). In the second case, I can see the information but I don’t know how to use it in order to run wave_clus.

Could you help me? I can send a tank and a neuronexus file if it’s necessary.
Best
Mariano

Current questions to be cleared before I can use Wave_Clus

Question about" set-parameters.m" #1
line37; par.stdmin = 5; % minimum threshold for detection
line38; par.stdmax = 50; % maximum threshold for detection

What is the numerical unit for those parameters above? Micro volt?

Question about" set-parameters.m" #2
line55; par.inputs = 10; % number of inputs to the clustering
line56; par.scales = 4; % number of scales for the wavelet decomposition

I don't know what they are, but usually I don't need to change those values?

Question about" set-parameters.m" #3
line22; par.min_clus = 60; % minimum size of a cluster (default 60)
Does it mean that Wave_Clus need at least 60 spikes for clustering?

In the manual, page 3, iv) Clustering, you say that
"the optimal temperature is set as the largest temperature for which
a cluster with at least min_clus members appears.".

To understand this sentence, I would like to know the definition of par.min_clus precisely.

Question about GUI #1
When I clicked "Plot all projections", Cluster window which appeared looks a little strange
as is seen in this attachement file.
plot_all_projection_strange
Basically, each cluster look too small so it is a little difficult to see how each cluster sperad.
But if I click "magnifier" icon, and next click on some clusters,

the cluster group dissapeared. Why does it happen?

Question about Output file of Get_spikes_pol(1), "spikes".
The structure of the variable "spikes" is "X x Y double".
To the column direction (from the top to the bottom), each spike information is aligning, right?
To the row direction (from the left to the right), amplitude changes around the spike are shown
maybe in Volt? If not, what is the numerical unit of this information?

Further, in my case, there are 120 colums. Does it mean that it contains 120 data points?
How can I define the number of datapoints?
In the manual, page 2, ii) Spike detection, you say that
"For each spike, w_pre datapoints before and w-post datapoints after the spike peak are stored.".
In my case, w_pre datapoints=10, and w-post datapoints=20 (sampling rate is 10kHz),
so I expected that number of spike data points will be 30, but the result was 120.
Do you know why?

Then, is it possible to see which column represents the voltage corresponds to the "spike"

with the time stamp?

Question about Output file of Do_clustering_pol(1), "ipermut".

What is the meaning of those two digits integer?

Question about Output file of Do_clustering_pol(1), "inspk".
The structure of the variable "inspk" is "X x Y double", so it looks similar to "spikes",
but in my case, the number of columns in "inspk" is 40 whereas that in "spikes" is 120.
What does "inspk" describe? Is it just a short version of "spikes" (in Volt)?
Or is the collection of numbers on the same row assigned to the set of variable

which describes the feature of the spike shapes?

Those above are my current questions to be cleared
before I can use Wave_Clus for our experiment.
I hope I can hear from you.

Sincerely,
M

Wave_clus on Mac

I noticed that Wave_clus uses a bunch on .exe files (ClusterXX.exe) for the clustering part. There is a file named 'cluster_mac.exe' which I suppose is to use with Mac but the .exe file type can only run in windows OS and not Mac. I am a bit confused about this, how can I get wave_clus run on Mac?

overlapping spikes

Hi -

Is the algorithm designed to accommodate overlapping spikes?
I attached a picture showing an extracellular recording and the identified clusters. (There's a shoulder cluster associated with the short spikes, but that's another matter.) Having trouble when the tall and short spikes overlap.

2nd figure is the wave_clus output. Colors corresponding to those in first figure.

spikes and clusters
wave_clus output

Thank you!
john
[email protected]

Issue with manual selection

Our lab has been using WaveClus for some time, and we love it! But I'm having an issue trying to use the manual selection tool. Maybe I'm missing something simple, but I can't get it to work. I don't see any references in the documentation -- what am I missing? I've tried all the different tools I can find, but cannot draw a rectangle and get it to form a new cluster. I don't get any error messages, but nothing happens. (There are definitely extrema inside the area I'm trying to outline.)

What am I missing here? Can you maybe provide a step-by-step of how this tool should be used?

Thanks!

Chaning the temprature range

I loaded CSC4 data and I want to change the temperature range from 0-20. I do it by setting the parameters
par.mintemp = 0.00;
par.maxtemp = 20;
par.tempstep = 1;

and once I load the data and I try to set the temperature on Temperature-Cluster size plot, it gives me an error and doesn't allow me to set the temperature.

I would appreciate it if you can help me

troubles importing spikes and index

Hello, we would like to import into wave_clus the waveforms of our already detected spikes. Each waveform has a length of 3200 microseconds, so the file I load to wave_clus has a matrix named spikes with N by 32 dimensions (where N is number of waveforms for a single electrode). The file also includes index as a vector with the timestamps for each spike and sr as our sampling rate (10000 Hz). When I run it, I get this error message. My colleague is also getting an error message while using the spikes file in the sample data.

wave_clus_error

load example data with error

Hi,

Thank you for this code, it is everthing I was looking for.
I was loading the example data C_Easy1_noise01_short.mat, it came with the error said
"Wave_clus didn't find a sampling rate in file. It will use the set in set_parameters.m
Reference to non-existent field 'FileInfo'."

The sampling rate was set as 30kHz as you can see.
screen shot 2017-09-21 at 5 55 57 pm

SPC processing of detected polytrode spikes

Hi,
Thank you for your great work!
I was wondering if there is a possibility to cluster detected spike waveforms from the tetrodes using SPC algorithm? I have been reading here on how to deal with polytrode's raw data using Get_spikes_poly, which however involves detection procedure by wave_clus. But my experiment requires separate detection. Is there a shortcut of how to proceed directly to SPC with the polytrode spike waveforms? Currently it works for me using one channel at a time (providing a .mat with 2D spike array and 1D timestamps array as described in the manual), but would really like to be able to do it for four channels.
Thank you in advance!

Reject button does not refresh GUI

It seems that pressing the Reject button merges the corresponding cluster with the garbage spikes (i.e. the cluster 0) internally, but does not refresh the GUI: the cluster 0 seems to stay intact.

The evidence that Reject-ing merges internally can be demonstrated by the fact that forcing cluster assignment (using the Force button) and then going back (pressing the Force button once again) results in spikes of the rejected cluster being merged with cluster 0 correctly.

(To reproduce, e.g. use the C_Easy1_noise01.mat data having the par.stdmin set to 4. Cluster 4 emerges and it does not get merged with cluster 0 using the Reject button).

spike alignment question

I've just realized I've mistakenly processed a small batch of data with incorrectly specified w_pre and w_post parameters. While the spike peaks are at sample point 15, I mistakenly set w_pre to 12 (sample rate = 24 kHz). I am wondering, however, if this would actually result in having a drastic effect on the output of the algorithm if my alignment window (interpolation on) is set to 10 sample points. I would think that the end resulting aligned waveforms would still be normalized toward the 15th sample point given the size of my alignment window. Is my intuition correct, or am I missing something?

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.