## Computer Data Types

The computer has different types of data, each with different properties:

**Integer**--whole or counting numbers. Since the computer
stores in binary, it is easier to store integers compared to
floats, and they take less storage.
**Float** (or floating point or real number)--numbers
with a decimal point. These are
actually stored with a mantissa and exponent, and will never be
exact: 2 will be 1.99999999 or 2.00000001. (√2)² will
often not be 2.
**String or character**--just text, can include numbers.
In GIS you cannot do arithmetic on strings.

When a vector data database is created, each field will have a specific type which limits
what you can do with the database. For instance, if your enter "14495 feet" as the elevation
for Mount Whitney, the computer will store it as a string, because you cannot
mix the number with its units. You cannot do
arithmetic with that data, or color it by elevation since the computer cannot
compare "14495 feet" and "13298 feet". One solution is
to put the units in the field name--this could be ELEV_FT. The other
option is to force the user to look up the units in the metadata that should
accompany the database.

Raster data sets also have types; the values in the grids can be stored as
integers or floats. This determines the precision of the values, and the
required storage.

*Last revision 7/22/2015*