I've got a bunch of plots to make with large numbers of points in them. When I try to do it with matplotlib it takes hours, which isn't convenient. What alternative approaches exist?
The relevant bit of my code is as follows, where the number of points for each feature could easily be 100,000:
marker = 'o' s = 10 patches = [] import matplotlib.patches as mpatches for feature, color in zip(features, colors): for point, value in zip(tsne, df[feature].values): try: plt.scatter(point[0], point[1], alpha=value, facecolor=color, marker=marker, s=s, label=feature) except: pass patches.append(mpatches.Rectangle((0, 0), 1, 1, fc=color)) plt.legend(patches, features, prop={'size': 15}, loc='center left', bbox_to_anchor=(1, 0.5)) plt.show();