In EpiData there are two operators that give results of divisions of integer numbers: DIV and MOD. DIV returns the integer division and MOD returns the remainder of the division:

- 15 DIV 10 is equal to 1, while 15 / 10 is equal to 1.5
- 20 DIV 7 is equal to 2

**15 MOD 10 is equal to 5**(because 15 - (15 DIV 10) equals 5 -- the remainder of the division is 5)**20 MOD 7 = 6****21 MOD 7 = 0**

The MOD operator can only be used with integer numbers as parameters:

Please note that numeric fields with a with larger than 4 characters is treated as a floating point number (with zero decimals) in EpiData. Imagine a field named FIELD1 which is a numeric field with 5 characters (defined as #####). And imagine another field called FIELD2 which is also numeric.

This last expression will assign the value 0 or 1 the the field FIELD2 no matter what number is entered in FIELD1.

You should be aware of a new option added in EpiData 1.3: Under Options | Advanced you can choose to see errormessages generated during handling of calculations in checkfiles. This option can help you in figuring out why a certain calculation in your checkfile doesn't work.