我需要将情节分成四个子图。请考虑以下代码:
import numpy as np
import matplotlib.pyplot as plt
MM= [[0, 1], [1, 0], [14, 15], [15, 14], [67, 68], [68, 67], [72,
73], [73, 72], [85, 86], [86, 85], [132, 133], [133, 132], [169, 170], [170,
169], [184, 185], [185, 184], [196, 197], [197, 196], [242, 243], [243, 242],
[269, 270], [270, 269], [274, 275], [275, 274], [297, 298], [298, 297], [341,
342], [342, 341], [378, 379], [379, 378], [387, 388], [388, 387], [390, 391],
[391, 390], [443, 444], [444, 443], [490, 491], [491, 490], [501, 502], [502,
501], [527, 528], [528, 527], [550, 551], [551, 550], [556, 557], [557, 556],
[583, 584], [584, 585], [584, 583], [585, 584], [594, 595], [595, 594], [601,
602], [602, 601], [711, 712], [712, 711]]
x,y = zip(*MM)
plt.scatter(x,y, s=0.8, c='purple', alpha=1)
plt.axhline(576, linewidth=0.3, color='blue', label='zorder=2', zorder=2)
plt.axvline(576, linewidth=0.3, color='blue', label='zorder=2', zorder=2)
plt.xlim(0, 820)
plt.ylim(0, 820)
plt.show()
代码生成此plot。我需要将这个情节分成四个子图,正好在情节内的紫色线条上。我想保持xticks和yticks间隔。新情节类似于plot。我需要将给定的图分割成子图,但不要将子图添加到Matplotlib different size subplots中的图形中。任何人都有任何想法?