afam.asc_event

This module provides all supported ASCII event classes.

Module Contents

Classes

ASC_EVENT

A dataclass representing the basic framework of every ASCII event.

ASC_BUTTON

A dataclass used to store the data from a "BUTTON" line.

ASC_INPUT

A dataclass used to store the data from a "INPUT" line.

ASC_SBLINK

A dataclass used to store the data from a "SBLINK" line.

ASC_SSACC

A dataclass used to store the data from a "SSACC" line.

ASC_SFIX

A dataclass used to store the data from a "SFIX" line.

ASC_EBLINK

A dataclass used to store the data from a "EBLINK" line.

ASC_ESACC

A dataclass used to store the data from a "ESACC" line.

ASC_EFIX

A dataclass used to store the data from a "EFIX" line.

ASC_MSG

A dataclass used to store the data from a "MSG" line.

ASC_START

A dataclass used to store the data from a "START" line.

class afam.asc_event.ASC_EVENT[source]

A dataclass representing the basic framework of every ASCII event.

to_dict()[source]

Convert the ASC_EVENT class to a dictionary.

Returns

`self.__dict__` – Dictionary representing all attributes of the ASCII event

Return type

dict

Example

>>> event = ASC_EVENT()
>>> event.to_dict()
{}
class afam.asc_event.ASC_BUTTON[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “BUTTON” line. This line contains a button press or release event.

`t`

time of button press

Type

int

`b`

button number (1-8)

Type

int

`s`

button change (1=pressed, 0=released)

Type

int

t :int
b :int
s :int
class afam.asc_event.ASC_INPUT[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “INPUT” line. This line contains an input event.

`t`

time of input

Type

int

`p`

port number

Type

int

t :int
p :int

Bases: ASC_EVENT

A dataclass used to store the data from a “SBLINK” line. This line contains the start of a blink event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

eye :str
st :int
class afam.asc_event.ASC_SSACC[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “SSACC” line. This line contains the start of a saccade event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

eye :str
st :int
class afam.asc_event.ASC_SFIX[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “SFIX” line. This line contains the start of a fixation event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

eye :str
st :int

Bases: ASC_EVENT

A dataclass used to store the data from a “EBLINK” line. This line contains start and end time (actually the time of the last sample fully within the blink), plus summary data of a blink event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

`et`

end time

Type

int

`d`

duration

Type

int

eye :str
st :int
et :int
d :int
class afam.asc_event.ASC_ESACC[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “ESACC” line. This line contains start and end time (actually the time of the last sample fully within the saccade), plus summary data of a saccade event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

`et`

end time

Type

int

`d`

duration

Type

int

`sx`

start X position

Type

float

`sy`

start Y position

Type

float

`ex`

end X position

Type

float

`ey`

end Y position

Type

float

`ampl`

amplitude in degrees

Type

float

`pvel`

peak velocity, degr/sec

Type

float

`resx`

resolution (if events_have_resolution==1)

Type

float

`resy`

resolution (if events_have_resolution==1)

Type

float

eye :str
st :int
et :int
d :int
sx :float
sy :float
ex :float
ey :float
ampl :float
pvel :float
resx :float
resy :float
class afam.asc_event.ASC_EFIX[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “EFIX” line. This line contains start and end time (actually the time of the last sample fully within the fixation), plus summary data of a fixation event.

`eye`

eye (L-R)

Type

str

`st`

start time

Type

int

`et`

end time

Type

int

`d`

duration

Type

int

`x`

X position

Type

float

`y`

Y position

Type

float

`resx`

resolution (if events_have_resolution==1)

Type

float

`resy`

resolution (if events_have_resolution==1)

Type

float

eye :str
st :int
et :int
d :int
x :float
y :float
resx :float
resy :float
class afam.asc_event.ASC_MSG[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “MSG” line. This line contains token and start time, plus some summary data.

`t`

token (TRIALID, SYNCTIME, TRIAL_RESULT, INFO, etc.)

Type

str

`st`

start time

Type

int

`data`

information

Type

str

t :str
st :int
data :str
class afam.asc_event.ASC_START[source]

Bases: ASC_EVENT

A dataclass used to store the data from a “START” line. This line contains start time and some summary data.

`st`

start time

Type

int

`data`

information

Type

str

st :int
data :str