# Crispness index

The *Crispness Index* (*C*) provides a means of
quantifying the crispness, or fuzziness, of a membership probability
(MP) image. MP images describe the probability of each grid cell
belonging to some feature or class. MP images contain values ranging
from 0 to 1.

The index, as described by Lindsay (2006), is the ratio between
the sum of the squared differences (from the image mean) in the
MP image divided by the sum of the squared differences for the
Boolean case in which the total probability, summed for the image,
is arranged crisply.

*C* is closely related to a family of relative variation
coefficients that measure variation in an MP image relative to
the maximum possible variation (i.e. when the total probability
is arranged such that grid cells contain only 1s or 0s). Notice
that 0 < *C* < 1 and a low *C* value indicates a nearly
uniform spatial distribution of any probability value, and
*C* = 1 indicates a crisp spatial probability distribution,
containing only 1s and 0s.

## References

Lindsay, JB (2006) Sensitivity of channel mapping techniques to
uncertainty in digital elevation data, International Journal of
Geographic Information Science, 20(6): 669-692.

## See Also:

## Scripting:

The following is an example of a Python script that uses this tool:

```
wd = pluginHost.getWorkingDirectory()
```

inputFile = wd + "input.dep"

args = [inputFile]

pluginHost.runPlugin("CrispnessIndex", args, False)

This is a Groovy script also using this tool:

```
def wd = pluginHost.getWorkingDirectory()
```

def inputFile = wd + "input.dep"

String[] args = [inputFile]

pluginHost.runPlugin("CrispnessIndex", args, false)

## Credits:

- John Lindsay (2012) email: jlindsay@uoguelph.ca