Mathematical Calculation Formula

Modified on Sun, 16 Mar at 3:16 PM

You can use dynamic variables to perform mathematical calculations automatically. Follow these steps to set up a formula-based dynamic variable:


Note: to calculate a difference between 2 dates, follow these instructions: Calculate Time Differences (eg. Formula for the Age)


Step 1: Create a Numeric Variable

Your variable must be of numeric type to apply a formula.


Step 2: Access the Formula Editor

  • Click on the "Edit Formula" button at the top right.
  • When asked "Which kind of dynamics?", select "Formula (mathematical formula between numeric variables)".


Step 3: Assign Numeric Values (If Needed)

If your calculation involves scores based on list or Yes/No questions, you must assign numeric values to these variables first.


Step 4: Define the Formula

  • Click the blue "Change the Formula" button.
  • Select the "Number of variables or constants" needed. If you select too few, you will need to go back and restart the process. You can select more than needed without issue.
  • Click "Create My Formula" to proceed.


Step 5: Build Your Formula

  • A sequence of fields will appear where you can construct your formula.
  • You can use + , - , * , / operators and parentheses ( ) for structuring calculations.
  • Insert numeric variables from the CRF or add numerical constants as needed.
  • Once the formula is complete, click "Create Formula".


Step 6: Review Calculated Values

  • On the right, values for patients with all necessary data will appear in blue.
  • If any required values are missing, a message will indicate that the calculation is impossible for affected patients.


Step 7: Activate the Dynamic Calculation

  • Click the orange message at the top right: "Activate My Dynamics".
  • Check "I understand", then choose: Retrospective Mode (Applies the calculation to all patients in the study) ± Safe Mode (Also applies to all patients but does not overwrite existing manually entered values).
  • Click "Activate My Dynamics" to finalize.


Step 8: Make the Variable Non-Editable (Optional but Recommended)

For formula-based dynamic variables, it is recommended to uncheck "Is Editable" so calculations run automatically without manual changes.


Your dynamic variable is now set up, and you can verify results in patient records.



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article