cosmo_utils.mock_catalogues.abundance_matching.abundance_matching_f(dict1, dict2, volume1=1.0, volume2=1.0, reverse=True, dens1_opt=False)[source] [edit on github]

Abundance matching based on 2 quantities. It assigns values from dict2 to elements in dict1


dict1 : python dictionary or numpy.ndarray

Dictionary or array of 1st property.

Keys :
  • var : 1st variable to be analysed

  • dens : Density array corresponding to var elements.

    Only if dens == True.

dict2 : python dictionary

dictionary or array of the 2nd property.

Keys :
  • var : 2nd variable to be analyzed

  • dens : Density array corresponding to var elements.

    Given if dens == True.

volume1 : float

Corresponding volume to dict1.

reverse : bool, optional

Determines the relation between var1 and var2.

dens1_opt : bool, optional

If True, density must be calculated.

Options :
  • True : Density is already provided as key for dict1.
  • False : Density must be calculated.

var1_ab : numpy.ndarray

Array of elements matching those of dict1, after matching with dict2.