Диаграмма рассеяния PathCollection
.Вы можете обновить пути к этой коллекции, указав путь MarkerStyle
.
import matplotlib.pyplot as plt
from matplotlib.markers import MarkerStyle
fig, ax = plt.subplots()
sc = ax.scatter([0,1,0,-1],[-1,0,1,0], marker="o")
def make_path(m):
ms = MarkerStyle(m)
return ms.get_path().transformed(ms.get_transform())
markers = ["v", ">", "^", "<"]
sc.set_paths([make_path(m) for m in markers])
plt.show()
