Opticka 2.16.1
Opticka is an experiment manager for behavioral research.
Loading...
Searching...
No Matches
plxReader Class Reference
Inheritance diagram for plxReader:

Public Member Functions

function plxReader (in varargin)
 Constructor.
 
function parse (in me)
 parse all data denovo and sync plx / behaviour / eyelink info
 
function reparse (in me)
 reparse only reparse eye data and spikes from the raw loaded structures
 
function parseEvents (in me)
 only parse the behavioural events and EDF, used by LFPAnalysis
 
function lazyParse (in me)
 only parse what needs parsing
 
function readLFPs (in me)
 read continuous LFP from PLX/PL2 file into a structure
 
function get isEDF (in me)
 get method to check if EDF file is present
 
function get isPL2 (in me)
 get method to check if this is a newer pl2 plexon file
 
function get trodality (in me)
 get method to check if the spike data was recorded using a tetrode
 
function getFieldTripSpikes (in me)
 generate a FieldTrip formatted spike structure
 
function integrateEyeData (in me)
 integrate the saccade information into the trial event data, somewhat complicated as not all EDF parsed trials are exactly matched to the plexon event markers.
 
function infoBox (in me, in info)
 make a GUI box with all the data information available, including a plot of all event markers, which is defered from being drawn until the axis is clicked on.
 
function deferDraw (in src, in ignoredArg)
 
function editComment (in src, in ignoredArg)
 
function generateInfo (in me)
 generate text info about loaded data
 
function exportToRawSpikes (in me, in var, in firstunit, in StartTrial, in EndTrial, in trialtime, in modtime, in cuttime)
 exportToRawSpikes for legacy spikes support
 
function syncData (in me, in inplx, in exclude)
 allows data from another plxReader object to be used, useful for example when you load LFP data in 1 plxReader and spikes in another but they are using the same behaviour files etc.
 
function drawEvents (in me, in h)
 drawEvents plot a timeline of all event data
 
function forwardPlot (in ignoredArg, in ignoredArg)
 
function backPlot (in ignoredArg, in ignoredArg)
 
function getFiles (in me, in force)
 get file names and directories for plexon, opticka and EDF files.
 
function optimiseSize (in me)
 remove the raw wave matrices etc to reduce memory
 
- Public Member Functions inherited from optickaCore
function optickaCore (in varargin)
 Class constructor.
 
function get fullName (in me)
 
function getALF (in me, in subject, in sessionPrefix, in lab, in create)
 
function findAttributes (in me, in attrName, in attrValue)
 
function findAttributesandType (in me, in attrName, in attrValue, in type)
 find properties of object with specific attributes, for example all properties whose GetAcccess attribute is public and type is logical.
 
function findPropertyDefault (in me, in propName)
 
function clone (in me)
 Use this syntax to make a deep copy of the object, i.e. OBJ_OUT has the same field values, but will not behave as a handle-copy of me anymore.
 
function checkSuperclasses (in List)
 
function editProperties (in me, in properties)
 method to modify a set of properties
 
function setProp (in me, in property, in value)
 method to fast change a particular value. This is useful for use in anonymous functions, like in the state machine.
 
function initialiseGlobals (in me, in doReset, in doOpen)
 
function initialiseSaveFile (in me)
 Initialise Save prefix.
 
function checkPaths (in me)
 checks the paths are valid
 

Static Public Member Functions

static function loadMat (in fn, in pn)
 load the opticka object mat file This needs to be static as it may load data called "me" which will conflict with the me object in the class.
 
- Static Public Member Functions inherited from optickaCore
static function makeArgs (in args)
 Converts cell args to structure array.
 
static function addDefaults (in args, in defs)
 add default options to arg input
 
static function hasKey (in in, in key)
 check if a struct / object has a propery / field
 
static function getKeys (in device)
 PTB Get key presses, stops key bouncing.
 

Public Attributes

Property file
 plx/pl2 file name
 
Property dir
 file directory
 
Property matfile
 the opticka experimental object mat filename
 
Property matdir
 the opticka file directory
 
Property edffile
 Eyelink edf file name (should be same directory as opticka file).
 
Property eventWindow
 use the event on/off markers if empty, or a timerange around the event otherwise
 
Property eventSearchWindow
 the window to check before/after trial end for a behavioural marker
 
Property startOffset
 used by legacy spikes to allow negative time offsets
 
Property saccadeRealign
 Use first saccade to realign time 0 for data?
 
Property channelReduction
 reduce the duplicate tetrode channels?
 
Property verbose
 verbose?
 
Property cellmap
 used for legacy cell channel mapping (SMRs only have 6 channels)
 
Property info
 general info formatted as cellstrings for display
 
Property eventList
 parsed event list from plexon strobed words/TTLs
 
Property tsList
 parsed timestamped spikes
 
Property meta
 general metadata (useful for legacy spikes analysis routines)
 
Property rE
 the experimental runExperiment object (loaded from the matfile)
 
Property eA
 the eyelink data parsed as an eyelinkAnalysis object (loaded from edffile)
 
Property pl2
 the raw pl2 structure if this is a plexon pl2 file
 
- Public Attributes inherited from optickaCore
Property name
 object name
 
Property comment
 comment
 
Property verbose
 verbose logging, subclasses must assign this. This is normally logical true/false
 
Property dateStamp
 clock() dateStamp set on construction
 
Property uuid
 universal ID
 
Property paths
 storage of various paths
 
Property fullName
 The fullName is the object name combined with its uuid and class name.
 

Protected Attributes

Property isPL2
 is this a PL2 file?
 
Property isEDF
 is an EDF eyelink file present?
 
Property trodality
 is trodal?
 
- Protected Attributes inherited from optickaCore
Property cloning
 are we cloning this from another object
 
Property mversion
 Matlab version number, this is transient so it is not saved.
 
Property sansFont
 sans font
 
Property monoFont
 monoFont
 
Property className
 class name
 
Property savePrefix
 save prefix generated from clock time
 
Property fullName_
 cached full name
 

Additional Inherited Members

- Protected Member Functions inherited from optickaCore
function parseArgs (in me, in args, in allowedProperties)
 Sets properties from a structure or normal arguments pairs, ignores invalid or non-allowed properties.
 
function addArgs (in me, in args)
 
function setPaths (in me)
 Sets properties from a structure or normal arguments pairs, ignores invalid or non-allowed properties.
 
function getFonts (in me)
 set paths for object
 
function toStructure (in me)
 Converts properties to a structure.
 
function getType (in me, in in)
 
function logOutput (in me, in in, in message, in override)
 Give a metaproperty return the likely property class.
 
function salutation (in me, in varargin)
 Prints messages dependent on verbosity.
 

Constructor & Destructor Documentation

◆ plxReader()

function plxReader::plxReader ( in  varargin)

Constructor.

Parameters
varargin
Returns

Member Function Documentation

◆ backPlot()

function plxReader::backPlot ( in  ignoredArg,
in  ignoredArg 
)

◆ deferDraw()

function plxReader::deferDraw ( in  src,
in  ignoredArg 
)

◆ drawEvents()

function plxReader::drawEvents ( in  me,
in  h 
)

drawEvents plot a timeline of all event data

Parameters
han existing axis handle, otherwise make new figure
Returns

◆ editComment()

function plxReader::editComment ( in  src,
in  ignoredArg 
)

◆ exportToRawSpikes()

function plxReader::exportToRawSpikes ( in  me,
in  var,
in  firstunit,
in  StartTrial,
in  EndTrial,
in  trialtime,
in  modtime,
in  cuttime 
)

exportToRawSpikes for legacy spikes support

Parameters

return x spike data structure for spikes.m to read.

◆ forwardPlot()

function plxReader::forwardPlot ( in  ignoredArg,
in  ignoredArg 
)

◆ generateInfo()

function plxReader::generateInfo ( in  me)

generate text info about loaded data

Parameters

return

◆ getFieldTripSpikes()

function plxReader::getFieldTripSpikes ( in  me)

generate a FieldTrip formatted spike structure

Parameters

return

◆ getFiles()

function plxReader::getFiles ( in  me,
in  force 
)

get file names and directories for plexon, opticka and EDF files.

Parameters
forceforce new files to be selected even if there are existing ones
Returns

◆ infoBox()

function plxReader::infoBox ( in  me,
in  info 
)

make a GUI box with all the data information available, including a plot of all event markers, which is defered from being drawn until the axis is clicked on.

Parameters
infoa cellstring info structure, optional
Returns

◆ integrateEyeData()

function plxReader::integrateEyeData ( in  me)

integrate the saccade information into the trial event data, somewhat complicated as not all EDF parsed trials are exactly matched to the plexon event markers.

Parameters

return

◆ isEDF()

function get plxReader::isEDF ( in  me)

get method to check if EDF file is present

Parameters

return

◆ isPL2()

function get plxReader::isPL2 ( in  me)

get method to check if this is a newer pl2 plexon file

Parameters

return

◆ lazyParse()

function plxReader::lazyParse ( in  me)

only parse what needs parsing

Parameters

return

◆ loadMat()

static function plxReader::loadMat ( in  fn,
in  pn 
)
static

load the opticka object mat file This needs to be static as it may load data called "me" which will conflict with the me object in the class.

Parameters

return

◆ optimiseSize()

function plxReader::optimiseSize ( in  me)

remove the raw wave matrices etc to reduce memory

Parameters

return

◆ parse()

function plxReader::parse ( in  me)

parse all data denovo and sync plx / behaviour / eyelink info

Parameters

return

◆ parseEvents()

function plxReader::parseEvents ( in  me)

only parse the behavioural events and EDF, used by LFPAnalysis

Parameters

return

◆ readLFPs()

function plxReader::readLFPs ( in  me)

read continuous LFP from PLX/PL2 file into a structure

Parameters

return

◆ reparse()

function plxReader::reparse ( in  me)

reparse only reparse eye data and spikes from the raw loaded structures

Parameters

return

◆ syncData()

function plxReader::syncData ( in  me,
in  inplx,
in  exclude 
)

allows data from another plxReader object to be used, useful for example when you load LFP data in 1 plxReader and spikes in another but they are using the same behaviour files etc.

Parameters
inplxanother plxReader instance for syncing to
excludea regex of properties to exclude from syncing
Returns

◆ trodality()

function get plxReader::trodality ( in  me)

get method to check if the spike data was recorded using a tetrode

Parameters

return

Member Data Documentation

◆ cellmap

Property plxReader::cellmap

used for legacy cell channel mapping (SMRs only have 6 channels)

◆ channelReduction

Property plxReader::channelReduction

reduce the duplicate tetrode channels?

◆ dir

Property plxReader::dir

file directory

◆ eA

Property plxReader::eA

the eyelink data parsed as an eyelinkAnalysis object (loaded from edffile)

◆ edffile

Property plxReader::edffile

Eyelink edf file name (should be same directory as opticka file).

◆ eventList

Property plxReader::eventList

parsed event list from plexon strobed words/TTLs

◆ eventSearchWindow

Property plxReader::eventSearchWindow

the window to check before/after trial end for a behavioural marker

◆ eventWindow

Property plxReader::eventWindow

use the event on/off markers if empty, or a timerange around the event otherwise

◆ file

Property plxReader::file

plx/pl2 file name

PLXREADER Reads in Plexon .plx and .pl2 files along with metadata and eyelink EDF files. Parses the trial event / behaviour structure. Integrates EDF events and raw X/Y data into trial LFP/spike structures. Converts into Fieldtrip and custom structures. The plexon files contain the neural data and the strobed words and TTLs. Each strobed word represents a 15bit trial number, and there are 8 additional TTL lines. The opticka mat file includes the experimental structure (stimulusSequence), the stimuli (metaStimulus) and all other parameters. The strobed word trial order can be linked to the opticka trial order to determine what stimuli were shown. The EDF file contains the eyelink data timestamped for each trial along with trial numbers and other trial information.

◆ info

Property plxReader::info

general info formatted as cellstrings for display

◆ isEDF

Property plxReader::isEDF
protected

is an EDF eyelink file present?

◆ isPL2

Property plxReader::isPL2
protected

is this a PL2 file?

◆ matdir

Property plxReader::matdir

the opticka file directory

◆ matfile

Property plxReader::matfile

the opticka experimental object mat filename

◆ meta

Property plxReader::meta

general metadata (useful for legacy spikes analysis routines)

◆ pl2

Property plxReader::pl2

the raw pl2 structure if this is a plexon pl2 file

◆ rE

Property plxReader::rE

the experimental runExperiment object (loaded from the matfile)

◆ saccadeRealign

Property plxReader::saccadeRealign

Use first saccade to realign time 0 for data?

◆ startOffset

Property plxReader::startOffset

used by legacy spikes to allow negative time offsets

◆ trodality

Property plxReader::trodality
protected

is trodal?

◆ tsList

Property plxReader::tsList

parsed timestamped spikes

◆ verbose

Property plxReader::verbose

verbose?


The documentation for this class was generated from the following file: