Summary. Consider a sequence of, say, 10 to 20 vector observations in threedimensional space. It is suspected that a few subsets of consecutive observations are made up of collinear points. The purpose of this paper is to construct a statistically based algorithm to find such linear segments and to assess their accuracy. A similar assessment is made for coplanar sets of points. This algorithm is applied here to palaeomagnetic data and is claimed to be superior to previous methods of palaeomagnetic analysis in terms of completeness and balance of analysis, treatment of measurement errors and other sources of scatter, criteria for identification of linear and planar sets of points, and statistical rigour. Stability spectra, with statistically based confidence limits, are obtained as a by-product. 1 Palaeomagnetic analysis: background to the geometrical problem The natural remanent magnetization (NRM) in rocks is known in general to have originated in one or more relatively short time intervals during their formation and subsequent history, i.e. during rock-forming or metamorphic events during which NRM is frozen-in (stabilized) by falling temperature, grain growth etc. The NRM acquired during each such event is a single vector magnetization parallel to the then-prevailing geomagnetic field and is called a -component of NRM’. Rocks which have suffered more than one event of this kind are therefore liable to carry ‘multi-component NRM’. In the laboratory these components can be identified by demagnetizing the rock step-by-step, usually by thermal, alternating field or chemical demagnetization (which involves the analysis of the distribution of blocking rzmperature, coercivity and chemical leaching respectively). Resistance to these treatments is called ‘stability’ of remanence, and the range of treatment over which a particular component is removed is called the stability range of the component. The various discrete