I wrote this small function:
def sets():
set1 = random.sample(range(1, 50), 10)
set2 = random.sample(range(1, 50), 10)
return(set1,set2)
sets()
The output of this function looks like this:
([24, 29, 43, 42, 45, 28, 26, 3, 8, 21],
[22, 37, 38, 44, 25, 42, 29, 7, 35, 9])
I want to plot this in a two way Venn diagram. I know how to plot the NUMBERS of overlap between the sets using the matplotlib, i.e. using this exact code; however I want to plot the ACTUAL VALUES in the plot instead.
i.e. the overlap between the two should read: 29,42 as these are the two items in common, and not the number 2, to represent the number of numbers that overlap.
Would someone know how to do this?