Tutorial on how to import data form a Redcap project to a NiDB project
Gather the following information from Redcap administrator for API connection .
Redcap Server
Redcap API Token
Use 'Projects' menu in NiDB to get to the desired project's main page. From Data Transfer section of the links on the right, click "Global Redcap Settings" link.
Enter the Redcap server address and API token information and press "Update Connection Settings" button on the right as shown below.
Next steps to import the data correctly from redcap into NiDB is testing the connection, mapping each variable / field from redcap to NiDB and transferring the data. To test and established the connection with Redcap follow the following steps:
Go to the project page and click the "Import from Redcap" link as shown below.
Click on the "Connect To Redcap" button on the right. If the connection is successful, a table with the Redcap Project information as shown below will appear.
The Mapping / Transfer page will appear as shown below. This page is used to map variables or transfer data according to established mapping.
To start new or edit existing mapping Click on the "Edit Mapping" button on the left as shown in the above figure. A new page will appear as shown below.
Each Redcap form is required to map separately. Pick NiDB data type and "Redcap Form" from the drop-down list shown above.
Select a type of data that redcap form contains. NiDB handles this in three types of data, which are following:
Measures: Redcap forms storing cognitive measures and similar other measures are stored as this data form in NiDB
Vitals: Redcap forms that contains information of vitals like hearth rate, blood pressure, blood test results are stored as this form of data. Also any tests that need to be done multiple times in a day can be recorded as this form.
Drug / dose: If your project have information related to administrating drugs, this type of Redcap form is stored as Drugs / Dose in NiDB.
After choosing the Redcap "Form", a new section to map the variables from Redcap to NiDB will appear as shown in the figure below.
A variable mapping table has two sides: NiDB and Recap.
The NiDB variable side contains two columns. These columns will automatically filled with the same variable and instrument names based on the Redcap choices of the form and variables. However, one can change these names. These are the names that will be stored in NiDB for corresponding Redcap Form and variable names.
This side has seven columns. Following is the explanation of each column on Redcap side.
Event: A Redcap project can have multiple events. All the events will be listed in this column. Any number of events can be chosen from the list that is needed to map. In our example we chose only one event because the Redcap form selected tp map contain only data for that event.
Value: Pick the Redcap variable to map from a dropdown menu list.
Date: Pick the Redcap variable storing "date" information of the redcap form from a dropdown menu list.
Rater: Pick the Redcap variable storing "rater" information from a dropdown menu list.
Notes: Pick the Redcap variable storing "notes" information from a dropdown menu list.
Start / End Time: Pick the Redcap variable storing "start and end time" information form from a dropdown menu list.
Defining the correct type of field is very crucial for the mapping in NiDB. Especially time and date are very important to create reports based on the information stored in NiDB.
After defining one variable in a form, hit "Add" button on the right to add this mapping definition.
In case of any mistake, a mapping item can be deleted and later can be added again according to the above stated process.
After completing the mapping for a redcap form. Complete mapping the other redcap forms similarly.
Before the last step it is critical to recheck all the mapping information. It is important, because the integrity, and accuracy of data transfer is based on accurate mapping. So check, recheck and make sure!
After you have done with your recheck, you are ready to transfer the data from Redcap to NiDB.
Click on the "Transfer Data" button, the following screen will appear.
First select the NiDB instrument (mapped in the mapping step) to transfer the data for.
Select the redcap variable storing the NiDB unique id of the subjects. This is the variable that connects the records in the Redcap and NiDB.
Click the "Transfer" button to transfer data. This may take some time and the data transfer information will be displayed after data is transferred.
You can complete all the mapping for the Redcap forms to be exported at once and then transfer the data one by one OR you can transfer the data of one Redcap form mapped and then go to the next forms to map and transfer.
To transfer / synchronized the data, Just press the "Transfer" button on the right The data will be transferred / synchronized for the selected NiDB instrument.
You need to transfer the data for each mapped instrument separately by selecting them one by one.
Reports on data can be generated by using the "Analysis Builder" tool, selection from a project's main page from "Tools" section on the right.
Tutorial on how to create a report using Redcap data
Data that we imported from a Redcap project into a NiDB project can be used to create reports. These reports can be generated based on Redcap data or combining it with the data available in NiDB. The later is covered in the tutorial on Analysis Builder. The following is an example of creating a report based on the data imported from Redcap.
The following are the steps to create a report based on data imported form redcap.
From a project's main page click Analysis Builder. The above interface is used to produce reports in Analysis Builder.
Select the variables to generate the report.
As we are generating report based on the data that is imported from Redcap, the following variables cudit1, cudit2, cudit_3... are selected which were mapped as an example in the tutorial Importing Data from Redcap Project.
There are various setting that can be set to generate a report, more details on this in in the Tutorial on Analysis Builder. After the appropriate setting is selected, Press Update Summary button.
The report similar to the one shown in the figure below will be displayed.
Select the output format as .csv if the data is needed to store in a csv file format.
A complex report with more parameters involve can also be created. An Example of such report is available in the tutorial about Analysis Builder.
Tutorial on how to import subjects form Redcap
NiDB supports to import subjects from an existing Redcap database. This is especially a very helpful option when a large number of subjects required to be created in NiDB, and information on these subjects is available in Redcap. This option can be used for any existing NiDB project, or a newly created project as a part of new or extended study. This option can save a lot of time and effort making the process efficient and accurate.
Following are the steps to import subjects from a Redcap project.
Subjects can be imported from redcap into a NiDB project. Click Redcap Subject Import from Data Transfer section on the main page of the project as shown below:
Fill the following information for API connection to Redcap
Redcap Server: Name of the redcap server
Redcap Token: An API token provided by Redcap administrator.
Redcap Event: The name of the redcap event that stores the subject's information.
Provide the following redcap field names.
Record ID (Required): Actual Redcap field name for Redcap record id.
Alternate ID (Optional): Name of the redcap field holding subject id other than record id, if any:
First Name (Required): Redcap field name containing the first name information. This is not the actual first name of a subject.
Last Name (Required): Field name containing the last name information in Redcap. This is not the actual last name of a subject.
Birthdate (Required): Redcap field name storing the date of birth information for the subjects.
Sex (Required): Redcap field name that stores the sex of the subjects. For this field, codes stored in Redcap representing the subject's sex should be provided here. The codes for male (M), and female(F) are required. Codes for Other (O) and undefined (U) can also be defined if used in the Redcap project. A suggestive coding scheme 1 for male (M), 2 for female (F), 3 for other (O) and 4 for undefined (U) is also displayed for help.
After providing the required information regarding the Redcap fields click Subjects Information button.
If all the above information is correct, then the list of the subjects from redcap will be shown as follows:
There can be four types of subjects in the list. Those are:
Ready to Import: are the one those are in redcap and can be imported.
Found in an other project: these are present in another project under inthe NiDB database. They can also be imported, but need to be selected to get import.
Processing: these are already in the process of being imported and cannot be selected to import.
Already exist in the project: these already exist in the current project and cannot be duplicated.
After selecting the desired subjects to import, click Import Selected Subjects to start the import process.
In the enrollments section, select the project you want to enroll in, and click Enroll. The subject will now be enrolled in the project. Permissions within NiDB are determined by the project, which is in theory associated with an IRB approved protocol. If a subject is not enrolled in a project, the default is to have no permissions to view or edit the subject. Now that the subject is part of a project, you will have permissions to edit the subject's details. Once enrolled, you can edit the enrollment details and create studies.
Tutorials regarding Redcap
Followings are three sections about Importing data and subjects from Redcap and creating reports using the data that is imported from Redcap.
Once the connection is tested, click on thebutton to start the mapping and /or transfer data process.
Go to the following Mapping / Transfer page by clicking on thebutton from the mapping page or connection page.
Choose the recap event that holds the subject identification information.
Next, select the Redcap variable storing the redcap unique id.