We study the structure of
analytic measured groupoids as defined by Mackey. It has been observed by Ramsay
that an arbitrary groupoid can be thought of as an equivalence relation on its unit
space together with a field of isotropy subgroups.
We construct a cohomology theory for equivalence relations with coefficients
in a field of abelian groups, and show that two possible definitions using
strict cochains or almost everywhere cochains coincide, and show how using
this to reconstruct a groupoid from an equivalence relation and a field of
groups.