-
Notifications
You must be signed in to change notification settings - Fork 3
nigeLab_Block
"Building-Block" for managing data from single recordings.
Utility |
||||
|---|---|---|---|---|
| Get (Completion) Status | Link Data | Set (Completion) Status | Update Parameters |
Creates "building-Block" for managing data from single recordings.
- Associated defaults are stored in
nigelObj.Pars.Block(at each hierarchical level)- Defaults can be configured in
~/+nigeLab/+defaults/Block.m-
Critically, all name parsing is configured here. Incorrect parsing configuration is the most-common source of errors in constructing/initializing a
Block. - There are substantial comments and examples in the code comments, look there for more information.
-
Critically, all name parsing is configured here. Incorrect parsing configuration is the most-common source of errors in constructing/initializing a
- Other
+defaultsmay influence the Block constructor:-
~/+nigeLab/+defaults/Animal.m(sinceBlockis constructed duringAnimalconstructor) -
~/+nigeLab/+defaults/Tank.m(sinceBlockis constructed duringTankconstructor) -
~/+nigeLab/+defaults/Video.m(sinceVidStreamsflags can affectBlock.initduring automated parsing/association of Videos and Video-related Streams with theBlock) -
~/+nigeLab/+defaults/Queue.m(depending on flags set for parallel or remote processing in combination with specifications ofMatlabinstallation on your local machine)
-
- Defaults can be configured in
% Get second Block from third Animal of the Tank
animalIndex = 3;
blockIndex = 2;
blockObj = tankObj{animalIndex,blockIndex};% Construct a Block using two UI prompts:
% 1) Input block file
% 2) Output (Animal) folder that contains the Block
blockObj = nigeLab.Block();
blockObj = nigeLab.Block([]);% Construct a Block, specifying save location, but select the file from UI
saveLoc = fullfile('savepath','experimentName','tankName','animalName');
blockObj = nigeLab.Block([],saveLoc);% Construct a Block, skipping the UI
% Note that if a file path produces parsing errors,
% a UI may pop up to request the correct path.
inputFile = fullfile('inpath','tankName','animalName','blockName.rhd'); % Intan RHD
inputFile = fullfile('inpath','tankName','animalName','blockName.rhs'); % Intan RHS
inputFile = fullfile('inpath','tankName','animalName','blockName','blockName.sev'); % TDT
inputFile = fullfile('inpath','tankName','blockName','blockName.sev'); % TDT - also works
saveLoc = fullfile('savepath','experimentName','tankName','animalName');
blockObj = nigeLab.Block(inputFile,saveLoc);Cluster (SPC, K-Means) spikes based on extracted waveform features (PCs, Wavelet Coefficients)
- Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
- The following
.Fieldsmust have atruevalue for.Status:-
Raw(doRawExtraction)- Required (indirectly)
-
Filt(doUnitFilter)- Required (indirectly)
-
CAR(doReReference)- Required (indirectly)
-
Spikes(doSD)- Required (indirectly)
-
SpikeFeatures(doSD)- Required directly
- These requirements can be changed in
~/+nigeLab/+defaults/doActions.m
-
- Associated defaults are in
blockObj.Pars.AutoClustering- Defaults can be configured in
~/+nigeLab/+defaults/AutoClustering.m - For specific clustering algorithms, such as K-Means or SPC, some configurations are located in ``~/+nigeLab/+defaults/+AutoClustering/[methodname].m`
- Defaults can be configured in
blockObj = tankObj{1,2}; % second Block of first Animal in Tank
doAutoClustering(blockObj); % does auto-clustering and saves to diskfiles
linkToData(blockObj); % connect clusters to blockObj in Matlab
% linkToData(blockObj,'Clusters','Sorted'); % should also work, potentially fasterWIP: Synchronize neural data with behavioral events
WIP: Perform automated detection of events determined by
.Videosor.Streams
WIP: Extract Header for use with
.scoreVideomethod
Decimate raw signal to facilitate frequency-domain analyses
- Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
- The following
.Fieldsto have atruevalue for.Status:-
Raw(doRawExtraction)- Required (directly)
- These requirements can be changed in
~/+nigeLab/+defaults/doActions.m
-
- Associated defaults are in
blockObj.Pars.LFP- Defaults can be configured in
~/+nigeLab/+defaults/LFP.m
- Defaults can be configured in
blockObj = tankObj{2,:}; % All Blocks from the second Animal of the Tank
doLFPExtraction(blockObj); % extracts LFP and saves to diskfiles
linkToData(blockObj); % connect clusters to blockObj in Matlab
% linkToData(blockObj,'LFP'); % should also work, potentially fasterExtract "raw" recorded amplifier and digital stream signals from recording binaries
- Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
- Does not require any other fields to be completed before running (by default)
- This requirement can be changed in
~/+nigeLab/+defaults/doActions.m
- This requirement can be changed in
- Associated defaults are somewhat disperse; there are not any explicit
+defaultselements corresponding to theRawfield per se; however, the main thing is that parsing parameters must be set up in several places. SeeBlock Constructorfor more details.- Defaults can be configured in
~/+nigeLab/+defaults/Raw.m
- Defaults can be configured in
animalObj = tankObj{1}; % Returns 1st Animal in Tank
blockObj = animalObj{[2,5]}; % Returns 2nd and 5th block of 1st Animal in Tank
doRawExtraction(blockObj); % extracts Raw data and saves to diskfiles for both Blocks
linkToData(blockObj); % connect raw data to blockObj in Matlab
% linkToData(blockObj,'Raw','DigIO','AnalogIO','Stim','Time',); % should also workApply "virtual" common-average subtraction to each probe separately
-
Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
-
The following
.Fieldsmust have atruevalue for.Status:-
Raw(doRawExtraction)- Required (indirectly)
-
Filt(doUnitFilter)- Required (directly)
- These requirements can be changed in
~/+nigeLab/+defaults/doActions.m
-
-
There are currently no associated
+defaultsfor the.CARfield.
animalObj = tankObj{[1:3]}; % Returns first three Animals in Tank
blockObj = animalObj{:,[2,5]}; % Returns 2nd and 5th block of each Animal in animalObj array (first 3 animals of Tank)
doReReference(blockObj); % extracts Raw data and saves to diskfiles for both Blocks
linkToData(blockObj); % connect raw data to blockObj in Matlab
% linkToData(blockObj,'CAR',); % should also workDetect spikes in the extracellular field potentials and associate compressed sample features
-
Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
-
The following
.Fieldsmust have atruevalue for.Status:-
Raw(doRawExtraction)- Required (indirectly)
-
Filt(doUnitFilter)- Required (indirectly)
-
CAR(doReReference)- Required (directly)
- These requirements can be changed in
~/+nigeLab/+defaults/doActions.m
-
-
Associated defaults are in
blockObj.Pars.SD- Note that these parameters are somewhat confusing due to being associated with a much older version of
nigeLab, but will be ported to a less-confusing naming convention at some point.
- Note that these parameters are somewhat confusing due to being associated with a much older version of
blockObj = tankObj{:,:}; % Return all blocks from the Tank
linkToData(blockObj); % connect clusters to blockObj in Matlab
% linkToData(blockObj,'Spikes','SpikeFeatures'); % should also work, potentially fasterApply "spike-unit" bandpass filter to recorded extracellular field potentials
- Overloads superclass method inherited from
nigeLab.nigelObj- Superclass just iterates on "connected"
nigeLab.TankandnigeLab.Animalobjects.
- Superclass just iterates on "connected"
- The following
.Fieldsto have atruevalue for.Status:-
Raw(doRawExtraction)- Required (directly)
- These requirements can be changed in
~/+nigeLab/+defaults/doActions.m
-
- Associated defaults are in
blockObj.Pars.Filt- Defaults can be configured in
~/+nigeLab/+defaults/Filt.m
- Defaults can be configured in
blockObj = tankObj{:,2}; % Second block from all animals in Tank
doUnitFilter(blockObj); % extracts LFP and saves to diskfiles
linkToData(blockObj); % connect clusters to blockObj in Matlab
% linkToData(blockObj,'Filt'); % should also work, potentially fasterWIP: Get basic video-related information prior to performing manual video curation
WIP: Synchronize videos with neurophysiological data record
WIP: Curate and append metadata to individual "trials" or video frames
Return the completion status of a given
.Field
- superclass method inherited from
nigeLab.nigelObj
Connect the data saved on the disk to the hierarchical structure
- superclass method inherited from
nigeLab.nigelObj
Update the completion status of a specific
.Field
- superclass method inherited from
nigeLab.nigelObj
Update some or all of the sub-fields of
.Pars
- superclass method inherited from
nigeLab.nigelObj
