Hiding subsets based on size or degreeΒΆ

This illustrates the use of min_subset_size, max_subset_size, min_degree or max_degree.

  • ../_images/sphx_glr_plot_hide_001.png
  • ../_images/sphx_glr_plot_hide_002.png
  • ../_images/sphx_glr_plot_hide_003.png
  • ../_images/sphx_glr_plot_hide_004.png
  • ../_images/sphx_glr_plot_hide_005.png
from matplotlib import pyplot as plt
from upsetplot import generate_counts, plot

example = generate_counts()

plot(example, show_counts=True)
plt.suptitle('Nothing hidden')
plt.show()

plot(example, show_counts=True, min_subset_size=100)
plt.suptitle('Small subsets hidden')
plt.show()

plot(example, show_counts=True, max_subset_size=500)
plt.suptitle('Large subsets hidden')
plt.show()

plot(example, show_counts=True, min_degree=2)
plt.suptitle('Degree <2 hidden')
plt.show()

plot(example, show_counts=True, max_degree=2)
plt.suptitle('Degree >2 hidden')
plt.show()

Total running time of the script: ( 0 minutes 1.155 seconds)

Gallery generated by Sphinx-Gallery