The data module

The data module contains the Data class.

Such a class inherits from all other classes defined in the package and as such it provides a convenient container of all the algorithms implemented in Dadapy.

class data.Data(coordinates=None, distances=None, maxk=None, verbose=False, njobs=2, working_memory=1024)[source]

Data class.

return_ids_kstar_binomial(initial_id=None, n_iter=5, Dthr=23.92812698, r=0.5)[source]

Return the id estimates of the binomial algorithm coupled with the kstar estimation of the scale.

Parameters:
  • initial_id (float) – initial estimate of the id default uses 2NN

  • n_iter (int) – number of iteration

  • Dthr (float) – threshold value for the kstar test

  • r (float) – parameter of binomial estimator, 0 < r < 1

Returns:

ids, ids_err, kstars, log_likelihoods

return_ids_kstar_gride(initial_id=None, n_iter=5, Dthr=23.92812698, d0=0.001, d1=1000, eps=1e-07)[source]

Return the id estimates of the Gride algorithm coupled with the kstar estimation of the scale.

Parameters:
  • initial_id – initial estimate of the id default uses 2NN

  • n_iter – number of iteration

  • Dthr – threshold value for the kstar test

  • d0 – minimum id value

  • d1 – maximum id value

  • eps – threshold for the convergence of the Gride algorithm

Returns:

ids, ids_err, kstars, log_likelihoods