Простая таблица, кажется, имеет больше смысла, чем диаграмма Венна:
import scipy, pylab
names = ['Alice', 'Bob', 'Carol', 'David']
interests = [['Football', 'Swimming'], ['Swimming', 'Jooga', 'Jogging'],
['Cycling', 'Football'], ['Football', 'Tennis', 'Cycling']]
allinterests = list(set(reduce(lambda x,y:x+y, interests)))
X = scipy.zeros((len(interests), len(allinterests)))
for i, indinterests in enumerate(interests):
for x in indinterests:
X[i, allinterests.index(x)] = 1
pylab.matshow(X, interpolation='nearest', cmap=pylab.cm.gray_r)
pylab.show()
pylab.yticks(range(len(names)), names)
pylab.ylim([len(names)-0.5, -0.5])
pylab.xticks(range(len(allinterests)), allinterests)
pylab.savefig('interests.png')