face2face.statistics.check_distribution.search_best_fit_distribution¶
-
face2face.statistics.check_distribution.
search_best_fit_distribution
(data, xmin=None, xmax=None, extend_data=None, discret=False, approximation_method=None, distance_measurement_method='D', sigma_threshold=None, parameter_range=None, termination_condition=1)¶ Searches the best fitting distribution
Creates a fit object and compares every distribution for the given data set to find the best fitting one.
- Parameters
data (list) – A list of all the $delta t$ values for the analysed interaction duration.
xmin (float, default: None) – Set xmin to localize the part of the data set that you want to analyze.
xmax (float, default: None) – Set xmax to localize the port of the data set that you you want to analyze.
extend_data (int, default: None) – Can be used to extend the data set with random generated data points.
discret (bool, default: False) – Must be set if data set is discrete, because discrete versions of probability distributions are calculated differently.
approximation_method (str, int) – Different approximation methods for discrete data sets. Possible values: “round”, “xmax” or an integer.
distance_measurement_method (str, default: “D”.) – Changes the measurement method to calculated the minimized distance between the empirical data and the distribution. Possible Values: “D”,”V”,”Asquare”.
sigma_threshold (float, default: None) – Can be set to add a constraint for the maximum sigma.
parameter_range (dict, default: None) – Can be set to limit multiple parameters for the distributions.
termination_condition (int, default: 1) – If the function get_best_fit_distribution does not find best fit, because the remaining two are too similar you can set it on 2, to get the two best fitting distributions.
- Returns
Fit (Fit Object) – Contains the created Fit Object to use it for plotting as PDF, CDF or CCDF.
tupel_list (list) – Contains tupels with the comparison of every distribution that is included in the package.
best_fit (list) – Contains the best fitting distributions as strings. Amount of best fitting distributions depends on the termination_condition parameter.