Project data

Updated at February 10th, 2021

Data for a project is stored in its data tab. There are three different data types you can store information as. Data that is in rows and columns are added as data tables, executable files are stored as new processes, and documents that are not in CSV or SAV format can be added as new documents. 

New data table

Data displayed in rows and columns are added as data tables in Protobi. 

To create a new data table press the blue "New data table" button. You will be prompted to name the table, and upload a CSV or SAV file. Next to Admin within the table you can make it the project's primary file.

Most projects will have a data table named "main" by default. Initially, the table houses the file that you first uploaded when you created the project. Uploading a new file into an existing data table will overwrite the old file.

New process

Executable files are stored as new processes in Protobi. To create a new process press the green "New process" button. Press "Edit/run" and enter your code.

As an example we used a simple code that retrieves only complete responses from the survey data. 

JSON code for above example

var rows = data["main"]

rows = rows.filter(function(row) { return row.status == 'complete'})

return rows;

Note: A data process only runs when you press "Edit/run," and manually run the code in the process pre-calculate. Whereas any code in the Pre-calculate tab of Project settings runs on the latest file every time you open the project. Read more on the difference here

New document

The grey "New document" button lets you upload files of any format. It can be used like a Dropbox for storing images used in your survey, PPTX template files etc. 

When you create a project, please include the survey questionnaire as a document. We find it can be useful to organize all of a project's documents in one central place. 

All users with admin access to the project can view and download these documents.

Download data

You can download data from any of the three different data types. Notice for processes and data tables you can download the file in different formats. New documents can only be downloaded in its original format (seen above). 

Was this article helpful?