tropea_clustering.plot_smooth.plot_pop_fractions

tropea_clustering.plot_smooth.plot_pop_fractions(title, list_of_pop, tra)[source]

Plot, for every time resolution, the populations of the clusters.

Parameters:
  • title (pathlib.Path) – The path of the .png file the figure will be saved as.

  • list_of_pop (list[list[float]]) – For every delta_t, this is the list of the populations of all the states (the first one is the unclassified data points).

  • tra (ndarray of shape (delta_t_values, 3)) – tra[j][0] must contain the j-th value used as delta_t; tra[j][1] must contain the corresponding number of states; tra[j][2] must contain the corresponding unclassified fraction.

Example

Here’s an example of the output:

Example Image

For each time resolution analysed, the bars show the fraction of data points classified in each cluster. Clusters are ordered according to the value of their Gaussian’s mean; the bottom cluster is always the unclassified data points.