{ "cells": [ { "cell_type": "markdown", "id": "503cb687", "metadata": {}, "source": [ "# Hands-on session 2: Advanced Neo\n", "\n", "These exercises build on concepts introduced in Tutorial 2\n", "\n", "## Preparation: Download public ephys dataset\n", "On Linux you can download the compiled nix file via the command below. On other systems, please download the file manually from [here](https://gin.g-node.org/NeuralEnsemble/neo_elephant_teaching/raw/master/reach_to_grasp_material/i140703-001.nix) and save it in the same folder as this notebook. This is the same file as already used in Tutorial 2." ] }, { "cell_type": "code", "execution_count": null, "id": "5fa6ae14", "metadata": {}, "outputs": [], "source": [ "!wget -O reach_to_grasp_material/i140703-001.nix https://gin.g-node.org/NeuralEnsemble/neo_elephant_teaching/raw/master/reach_to_grasp_material/i140703-001.nix" ] }, { "cell_type": "markdown", "id": "4d1cd9a4", "metadata": {}, "source": [ "### SpikeTrain visualization\n", "1. Load the data `i140703-001.nix` file using the `neo.io.NixIO` into a neo Block.\n", "3. Here we will only investigate data measured between 2 second - 12 seconds of the datasets. Create a new neo Segment that only contains data of that time range.\n", "2. Select all SpikeTrains that are marked as single unit activity and have `unit_id` 1. How many of those SpikeTrains exist in the dataset?\n", "\n", "4. Plot the spike times in a raster plot. Use the `connector_aligned_id` as vertical offset for each Spiketrain avoid overlapping spike markers.\n", "5. Add vertical lines to indicate event times labeled as `TS-ON`, `SR`, `OT` and `RW-ON`.\n", "\n", "### Your solution" ] }, { "cell_type": "code", "execution_count": null, "id": "99906dba", "metadata": {}, "outputs": [], "source": [] }, { "cell_type": "markdown", "id": "544d74f6", "metadata": {}, "source": [ "## Bonus Exercise\n", "Did you bring your own data? Visualize your own data. Note that it might be useful to load the data in lazy mode to spare your memory." ] }, { "cell_type": "code", "execution_count": null, "id": "24b21014", "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.7" } }, "nbformat": 4, "nbformat_minor": 5 }