Skip to content
Johannes Niediek edited this page Feb 16, 2022 · 5 revisions

Tutorial Part III

In this part of the tutorial we will finally work with real data recorded from the left hippocampus.

1. Download the data

Download the file CSC29.ncs.

2. Extract spikes and mask artifacts

First make sure to delete the local_options.py and local_options.pyc files if they are still around them from a previous part of the tutorial.

Similar to before, run

css-extract --files CSC29.ncs

to extract spikes. Then run

css-mask-artifacts --datafile CSC29/data_CSC29.h5

to mask artifacts before spike sorting.

For the curious
  • Run css-plot-rawsignal to create an overview plot of the raw signal.
  • Run css-plot-extracted --datafile CSC29/data_CSC29.h5 to create an overview plot of the extracted spikes before sorting.

Both plots are saved in the overview folder:

Plot of raw signal

Plot of extracted spikes

You can use the program css-overview-gui to visualize summary statistics of all channels, and to quickly display the overview plots.

Screenshot of overview-gui

3. Cluster the data

Just as before, run

css-simple-clustering --datafile CSC29/data_CSC29.h5

4. Check the results

4.1 Using overview plots

Run

css-plot-sorted --datafile CSC29/data_CSC29.h5 --label sort_pos_simple

to create an overview plot:

Plot of sorted spikes from CSC29

You can also display this plot within css-overview-gui. This is useful if you work with job files (not part of the tutorial).

Warning: The following part of the tutorial is currently (February 2022) under construction

The overview plot shows a few problems:

  • Units 3 and 8 are artifacts
  • Units 5 and 7 look quite similar and should maybe be merged.

We will now use the css-gui to fix these problems.

4.2 Using the graphical user interface

Open css-gui and load CSC29 (File, Open). Then find the artifacts in the pull down menu. To move a cluster to the group Artifacts, just click on it and press A.

If you wonder what the purpose of the button labeled Artifact is: It is used to mark an entire group as artifact. This is useful if your analysis scripts acknowledge the different types of groups: you can then run your analyses for example for all groups, for non-artifacts only, or for single units only.

If you would like to move an entire group to the artifacts group, use the Correlations tab and simply merge your group to the artifact group by selecting your group as Group 1 and Artifacts as Group 2.

Marking artifacts

To decide whether to merge units 5 and 7 or not, use the Tab Correlations: GUI with real data, 2

5. Outlook

Combinato offers many possibilities not discussed in the tutorial. Among these are

  • Splitting the clustering-combination procedure into individual programs for tuning
  • Working with job files created in css-overview-gui
  • Extracting or sorting only parts of data files, indicated by time ranges
  • Excluding time ranges from the sorting procedure (e.g. for known periods of contamination)
  • And many more. Also use --help as an option to all css-* programs!

6. Working with raster plots

One very handy feature of Combinato is that you can create raster plots on-line in css-gui. This looks like this:

One unit responds to the tie (both to the image and the written name in German): GUI with real data, 1

Another unit responds to the strawberry (but not to the written name): GUI with real data, 3

Feel free to contact me (jonied@posteo.de) for instructions on how to supply the stimulus material!

Congratulations! You mastered the Combinato tutorial.