In DataDynamic, one way to create your own variables is by calculating them from one or more of the variables already present in the list. The possibilities are almost endless, especially when using scripting, but for now we will concentrate on an example.


+ Creating a new variable (calculated variable)

A new variable can be created starting from selecting one or more existing ones or from scratch. To create a New 'calculated' variable, click on 'Add Variable' in the Edit toolbar, next fill in the formula in the 'Formula' field and click on 'Create'. 

See a more specific description of how 'Add new calculated variable' works here.


+ Recoding an existing variable into a new one


Recoding variables can entail rearranging the categories of categorical variables, for instance by combining several categories into one or, in the case of numerical questions, making categories out of numerical values. An example of this would be coding the variable age (as measured in years) into a variable age in categories (where the first category could be Under 18, etc.). 

See a more specific description of how 'Recoding' works here.


+ Open questions


Open questions are questions without pre-defined answer categories. Variables representing open questions have a text format. You can use a text variable in a table, but the multitude of different answers usually given to an open question produce a table difficult to read and not be spent. Therefore the text variables that contain open questions are often coded into categorical variables.

See a more specific description of how 'Code open questions' works here.



The new variable appears at the bottom of the variable list.


You can follow the steps described above by checking the video on our Youtube channel: