abundance_matching_f¶
-
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 indict1
Parameters: dict1 : python dictionary or
numpy.ndarray
Dictionary or array of 1st property.
- Keys :
var
: 1st variable to be analyseddens
: Density array corresponding tovar
elements.Only if
dens
== True.
dict2 : python dictionary
dictionary or array of the 2nd property.
- Keys :
var
: 2nd variable to be analyzeddens
: Density array corresponding tovar
elements.Given if
dens
== True.
volume1 : float
Corresponding volume to
dict1
.reverse :
bool
, optionalDetermines the relation between
var1
andvar2
.dens1_opt :
bool
, optionalReturns: var1_ab :
numpy.ndarray
Array of elements matching those of
dict1
, after matching withdict2
.