spheregroup¶
- pydl.pydlutils.spheregroup.spheregroup(ra, dec, linklength, chunksize=None)[source]¶
Perform friends-of-friends grouping given ra/dec coordinates.
- Parameters
- ra, dec
numpy.ndarray
Arrays of coordinates to group in decimal degrees.
- linklength
float
Linking length for the groups in decimal degrees.
- chunksize
float
, optional Break up the sphere into chunks of this size in decimal degrees.
- ra, dec
- Returns
tuple
A tuple containing the group number of each object, the multiplicity of each group, the first member of each group, and the next member of the group for each object.
- Raises
PydlutilsException
If the array of coordinates only contains one point.
Notes
It is important that
chunksize
>= 4 *linklength
. This is enforced.Warning
Behavior at the poles is not well tested.