Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
This method is to stop a record that was previously started by createRecord. This will set the end date time of the record to the current date time.
A record is linked to a session. So to close a record, you need to provide the session id.
The result is an object containing these fields:
This method is to update a record. You can update its title, description and its tags.
Your application cannot update a record that was created by another application.
The result is a record object.
Update the tags and the description.
This method is to ask Cortex to download the EEG/motion/CQ/detections data of a record from the EMOTIV cloud.
Suppose that the user has installed Cortex on 2 computers, named computer A and computer B. On computer A, the user creates a record, and Cortex uploads this record to the EMOTIV cloud.
Then, on computer B, Cortex automatically downloads the metadata of this record, ie its name, description, start time, end time, etc... So this record is visible when you call methods like or .
But Cortex doesn't automatically download the actual data of the record, ie the EEG, motion, CQ, the results of the detections, etc... So you cannot this record. To download the actual data, you must call the method "requestToDownloadRecordData".
Name | Type | Required | Description |
---|
The result is an object with 2 fields:
Name | Type | Description |
---|
Each object in the success array include these fields:
Name | Type | Description |
---|
Each object in the failure array include these fields:
This method is to configure the opt-out feature for the records. This feature lets you decide if the created by your application on the local machine are uploaded to the EMOTIV cloud or not.
If the opt-out is on (ie the parameter newOptOut is true) then the records created on this machine will not be uploaded to the cloud. If the opt-out is off (ie the parameter newOptOut is false) then the records created on this machine will be uploaded to the cloud.
Please note that changing the opt-out configuration has no effect on the records previously created on the local computer. It only affects the records created after the change. Changing the opt-out configuration is not retroactive.
The opt-out configuration is linked to your application. Changing the configuration only affects the records created by your application. This has no effect on the records created by other applications.
The opt-out configuration is also linked to the EmotivID of the user. The opt-out can be turned on or off for each EmotivID. It is off by default.
You can check the field localOnly of a to know if this record will stay on the local machine, or if it will be uploaded to the EMOTIV cloud.
Some don't let you change the opt-out configuration and force the opt-out to be always on or always off. See the possible configurations below for details.
This method was added in Cortex 2.2.1
The result is an object describing the current opt-out configuration. It includes these fields:
Here is an overview of the possible configurations:
This method is to export one or more records to EDF or CSV files.
You can export the raw EEG data, the motion data, the performance metrics and the band powers. The available data streams depend on the license of the record. You can check the field licenceScope in the to know which data streams are available.
By default, you can only export the records that were created by your application. If you want to export a record that was created by another application (e.g. or ) then you must provide the license id of this application in the parameter licenseIds.
In order to export a record created by , the current must be the owner of the LABS experiment.
You must before you can export it. If you want to export a record immediately after you stop it then you must wait for the before you try to export.
The format of the exported files is described in .
This method was added in Cortex 2.1.1 to all desktop versions of Cortex. It was added to iOS and Android in Cortex 2.7.0
The parameter streamTypes must contain one or more values, chosen from this list: "EEG", "MOTION", "PM", "BP". If the format is "EDF" then only "EEG" and "MOTION" are available.
Depending on the parameters format and version Cortex will create different files.
This format is identical to the one used in Cortex 1.x
1 EDF file for the EEG and CQ data
1 EDF file for the motion data
1 JSON file for the markers
1 CSV file for the markers if the parameter includeMarkerExtraInfos is true
Format EDFPLUS/BDFPLUS, no version (available since Cortex version 3.7.5)
1 EDF+/BDF+ file for the EEG, CQ and Motion data
1 JSON file for the markers
1 CSV file for the markers if the parameter includeMarkerExtraInfos is true
This format is identical to the one used in Cortex 1.x
1 CSV file for the EEG and CQ data
1 CSV file for the band powers
1 CSV file for the motion data
1 CSV file for the performance metrics
1 JSON file for the markers
1 CSV file for the markers if the parameter includeMarkerExtraInfos is true
This format is the new format of Cortex 2.x
1 CSV file for all the data streams (EEG, CQ, band powers, motion, PM)
1 JSON file for the markers
1 CSV file for the markers if the parameter includeMarkerExtraInfos is true
The result is an object that includes these fields:
In case of success, you get an object with these fields:
In case of failure, you get an object with these fields:
This method returns a list of records owned by the current user. By default, you only get the records created by your application. To query the records from another application, you must filter by the license id of this application.
Depending on the query, this method may return a lot of records. To avoid performance issues, you should always set an offset and a limit.
The query object can contain one or more of these fields:
The orderBy parameters is an array of objects, similar to the orderBy clause of a SQL request.
Each object must have a single attribute. The key of the attribute is the name of record's field you want to order by. The value of the attribute must be "ASC" or "DESC", to order is ascending or descending order.
For example, to order the records by their start date, in descending order, you must use the object {"startDatetime":"DESC"}
. To sort the records by title, in alphabetical order, you must use {"title":"ASC"}
.
You can order the records by these fields: title, description, startDatetime, modifiedDatetime, duration, subjectName, applicationId. The option to order by applicationId was added in Cortex 2.5.0
These parameters are to implement pagination. It useful if you want to display the records in a UI. You must order the results to use these parameters.
First you should call this method with an offset of zero, and a limit of X. In the response, check the value of count. If count is greater than the limit, then you should call this method again with an offset of X. And then with an offset of 2*X, 3*X... until you get all the records for your query.
The result is an object that includes these fields:
Get the 10 most recent records created by EmotivPRO.
Get some records using a keyword.
This method is to delete one or more records.
The records will be deleted from the local computer, but also from the EMOTIV account of the user in the cloud, and from any computer where the user is logged in.
Your application cannot delete a record that was created by another application.
Deleting a record is irreversible. There is no way to recover a deleted record.
The result is an object that includes these fields:
In case of success, you get an object with these fields:
In case of failure, you get an object with these fields:
Deleting two records, including one that has an invalid id.
After you opened a with a headset, you can create a record. A record is a permanent object to store data from an EMOTIV headset. You can associate a to a record. You can add one or more to a record.
Unlike a , a record is a permanent object. It is stored on the hard drive and then can be synchronized to the EMOTIV cloud. The configuration can let you decide if the records of a user are uploaded to the cloud or not.
First, you must with a headset. Then you call to start a new record. When the record is in progress, you can add to this record. You stop a record with .
The record is linked to the session, so if you close the session, or if your application is disconnected from the Cortex service, then Cortex will automatically close the record.
After you stop the record you can export its data to a CSV or EDF file using .
Name | Type | Description |
---|
Name
Type
Required
Description
cortexToken
string
yes
A token returned by authorize.
session
string
yes
The session id you provided when you called createRecord.
Name
Type
Description
record
object
sessionId
string
The session id linked to the record.
Name
Type
Required
Description
cortexToken
string
yes
A token returned by authorize.
record
string
yes
A record id returned by createRecord.
title
string
no
The new title of the record.
This parameter was added in Cortex 2.5.0
description
string
no
The new description of the record. Omit this parameter if you don't want to update the description.
tags
array of strings
no
The new tags of the record.Omit this parameter if you don't want to update the tags.
recordId |
| The id of a record that Cortex cannot download. |
code |
| The error code for this record. |
message |
| The error message for this record. |
optOutAvail | forceOptOut | currOptOut | Description |
true | false | Variable, false by default | By default, currOptOut is false and the records created by your application will be uploaded to the cloud. You can change the opt-out configuration for each EmotivID. |
true | true | Always true | The records will never be uploaded to the cloud. You cannot change the configuration. |
false | false | Always false | The records will always be uploaded to the cloud. You cannot change the configuration. |
false | true | Always false | The records will always be uploaded to the cloud. You cannot change the configuration. |
Stream | Description |
EEG | Export the raw EEG data, the contact quality of each EEG sensor, and the markers. The license scope of the record must contain the scope "eeg". |
MOTION | Export the motion data. |
PM | Export the results of the performance metric detection. If the license scope of the record contains the scope "pm" then Cortex will export the high resolution performance metrics, at 2 hertz. Otherwise Cortex will export the low resolution data, at 0.1 hertz. |
MC | Export the results of the mental command detection. |
FE | Export the results of the facial expression detection. |
BP | Export the band powers of each EEG sensor. |
Name | Type | Description |
success |
| For each record you successfully exported, this array contains an object that includes the record id. |
failure |
| For each record that couldn't be exported, this array contains an object that describes the error. |
Name | Type | Description |
recordId |
| The id of the record that was successfully exported. |
Name | Type | Description |
recordId |
| The id of the record that couldn't be exported. |
code |
| The error code. |
message |
| The error message. |
Name | Type | Description |
recordId |
| The id of the record that couldn't be deleted. |
code |
| The error code. |
message |
| The error message. |
cortexToken |
| yes |
recordIds |
| yes | A list of record ids. |
success |
| List of the records that Cortex will start to download. |
failure |
| List of the records that Cortex will not download. |
recordId |
| The id of a record that was added to the Cortex download queue. Cortex will now start the download. |
Name | Type | Required | Description |
cortexToken |
| yes |
status |
| yes | Must be "get" or "set". Use "get" to read the current configuration of the opt-out feature. Use "set" to turn the opt-out on or off. |
newOptOut |
| no | If the status is "set" then you must set this parameter to true or false, in order to turn the opt-out feature on or off. If the status is "get" then you should omit this parameter. |
Name | Type | Description |
optOutAvail |
|
forceOptOut |
|
currOptOut |
| The current configuration of the opt-out. If this value is true, then the records created by your application won't be uploaded to the cloud. If this value is false, then they will. |
message |
| A text message. |
Name | Type | Required | Description |
cortexToken |
| yes |
session |
| yes |
title |
| yes | The title of the record. Must be 200 characters or less. |
description |
| no | The description of the record. |
subjectName |
| no |
tags |
| no |
experimentId |
| no | An experiment id you can associate to this record. If you omit this parameter then the experimentId of the record will be zero. This parameter was added in Cortex 2.2.1 |
Name | Type | Description |
record |
|
sessionId |
| The id of the session this record is linked to. |
Name | Type | Required | Description |
cortexToken |
| yes |
recordIds |
| yes | An array of record ids. These are the ids of the records you want to export. |
folder |
| yes | The path of a local folder. Cortex will write the exported files in that folder. You must create this folder before you call this method. Cortex will return an error if the folder doesn't exist. On iOS, this parameter doesn't exist. Cortex exports the data to the "Documents" folder of the current application. |
streamTypes |
| yes | List of the data streams you want to export. |
format |
| yes | The format of the exported files. Must be "EDF", "EDFPLUS", "BDFPLUS" or "CSV". |
version |
| no | If the format is "EDF", then you must omit this parameter. If the format is "CSV", then this parameter must be "V1" or "V2". |
licenseIds |
| no | The default value is an empty list, which means that you can only export the records created by your application. You can provide the license ID of other applications in order to export the records created by these applications. This parameter was added in Cortex 2.6.3 |
includeDemographics |
| no | The default value is This parameter was added in Cortex 2.6.3 |
includeSurvey |
| no | The default value is This parameter was added in Cortex 2.6.3 From Cortex 3.5.0, survey data will be exported in a separate CSV file (along with JSON file). |
includeMarkerExtraInfos |
| no | The default value is This parameter was added in Cortex 2.6.3 |
includeDeprecatedPM |
| no | If The default value is |
Name | Type | Description |
uuid |
| The id of this record. |
ownerId |
| The id of the user this record belongs to. It is a GUID, it is not the EmotivID of the user. |
applicationId |
| The id of the application that created this record. |
applicationVersion |
| The version of the application that created this record. |
title |
| The title of this record. |
description |
| The description of this record. |
tags |
| The tags associated to this record. |
experimentId |
| The experiment id associated to this record. |
startDatetime |
| When this record was created. |
endDatetime |
| When this record was stopped. |
licenseId |
| The id of the license used by this record. |
licenseScope |
| List of the data streams the license has access to. The scope "eeg" gives access to the raw EEG data. The scope "pm" gives access to the 2 hertz performance metrics. |
subject |
|
localOnly |
| If true then this record will not be uploaded to the EMOTIV cloud. If false then it will be uploaded. |
headbandPosition |
| This field was added in Cortex 2.4 |
Name | Type | Description |
markers |
|
Name | Type | Required | Description |
cortexToken |
| yes |
query |
| yes | An object to filter the records. |
orderBy |
| yes | Specify how to sort the records. |
limit |
| no | The maximum number of records that this method should return. A limit of zero means no maximum. |
offset |
| no | The number of record that this method should skip before returning the result. If the limit is zero, then Cortex will ignore this parameter. |
includeMarkers |
| no | This parameter was added in Cortex 2.1 |
includeSyncStatusInfo |
| no | If The default value is This parameter was added in Cortex 2.6.3 |
Name | Type | Description |
licenseId |
| Set this parameter to filter the records by their license. |
applicationId |
| If you set the licenseId, then you can set this parameter to further filter the records by application. |
keyword |
| Set this parameter to filter the records by title, description, or subject name. |
startDatetime |
| An object with fields "from" and "to" to filter the records by their start date time. |
modifiedDatetime |
| An object with fields "from" and "to" to filter the records by their modification date time. |
duration |
| An object with fields "from" and "to" to filter the records by their duration. |
Name | Type | Description |
records |
|
count |
| The total number of records that match the query. |
limit |
| The limit you specified in the parameters. |
offset |
| The offset you specified in the parameters. |
Name | Type | Required | Description |
cortexToken |
| yes |
records |
| yes | An array of record ids. |
Name | Type | Description |
success |
| For each record you successfully deleted, this array contains an object that includes the record id. |
failure |
| For each record that couldn't be deleted, this array contains an object that describes the error. |
Name | Type | Description |
recordId |
| The id of the record that was successfully deleted. |
Name | Type | Required | Description |
cortexToken |
| yes |
recordIds |
| yes | A list of records id. |
A token returned by .
A token returned by .
If false then the opt-out is always off. The value of this field depends on the current . Some license force you to upload the records to the cloud.
If true (and optOutAvail is also true) then the opt-out is always on. The value of this field depends on the current . Some license don't let you upload the records to the cloud.
A token returned by .
A session id returned by .
The name of a subject created by . The subject is the person wearing the headset during the record. If you omit this field, then Cortex assumes that the is using the headset.
A list of tags you can associate to this record. You can use to search the records by tags.
A that represents the created record.
A token returned by .
If true
then the exported JSON file will include the demographic data of the user. It is only for the records created by .
If true
then the exported JSON file will include the survey data of the record. It is only for the records created by .
If true
then the markers of the records will be exported to a CSV file. This file is compatible with .
This object has a single field "subjectName". It is the subject name used to create this record. You can use to get more information about the subject. If the record was created without a subject name, then the field "subjectName" contains the EmotivID of the user.
If the headset is an EPOC X, then this field tells you the position of the headband of this headset during this record. Can be "back" or "top". If the headset is not an EPOC X, then this field is null. See for details.
A list of . The markers added to this record.
A token returned by .
If true
then the in the result will include the markers linked to each record. The default value is false
because a record may have a large number of markers.
An array of .
A token returned by .
A token returned by .