Foundations Of Cognitive Science

Thermometer Code

Thermometer coding is one approach to representing information that is to be presented to an artificial neural network. Thermometer coding is usually used to represent a quantitative variable. Imagine some variable of this type that varies in value from 0 to 10. To thermometer code this variable, one would turn on a sequence of input units, where the length of the sequence would equal the encoded value. For instance, to represent a value of "2" the first two input units would be activated; to represent a value of "8", the first eight input units would be activated, and so on. It is called a thermometer code, because the input units resemble a thermometer placed on its side, with the "height" of the "mercury" in the thermometer representing the value of the input variable. Dawson and Zimmerman (2003) used a thermometer code to represent distances when a network was trained on the Piagetian balance scale task.


  1. Dawson, M. R. W., & Zimmerman, C. (2003). Interpreting the internal structure of a connectionist model of the balance scale task. Brain & Mind, 4, 129-149.
(Added March 2010)