halotools.utils.broadcast_host_halo_property(table, halo_property_key, delete_possibly_existing_column=False)[source] [edit on github]

Calculate a property of the host of a group system and broadcast that property to all group members, e.g., calculate host halo mass.

Parameters: table : Astropy Table Table storing the halo catalog. halo_property_key : string Name of the column to be broadcasted to all halo members delete_possibly_existing_column : bool, optional If set to False, add_halo_hostid will raise an Exception if the input table already contains a halo_hostid column. If True, the column will be deleted if it exists, and no action will be taken if it does not exist. Default is False.

Notes

This function is primarily for use with Halotools-formatted halo tables. In particular, this function assumes that the table has a halo_id and halo_hostid column.

Examples

>>> from halotools.sim_manager import FakeSim
>>> halocat = FakeSim()

The halo_table now has a column called halo_spin_host_halo.