# # 极轴上的散点图

import numpy as np
import matplotlib.pyplot as plt

# Fixing random state for reproducibility
np.random.seed(19680801)

# Compute areas and colors
N = 150
r = 2 * np.random.rand(N)
theta = 2 * np.pi * np.random.rand(N)
area = 200 * r**2
colors = theta

fig = plt.figure()
c = ax.scatter(theta, r, c=colors, s=area, cmap='hsv', alpha=0.75)


## # 极轴上的散点图，具有偏移原点

fig = plt.figure()
c = ax.scatter(theta, r, c=colors, s=area, cmap='hsv', alpha=0.75)

ax.set_rorigin(-2.5)
ax.set_theta_zero_location('W', offset=10)


## # 极轴上的散点图局限于扇区

fig = plt.figure()
c = ax.scatter(theta, r, c=colors, s=area, cmap='hsv', alpha=0.75)

ax.set_thetamin(45)
ax.set_thetamax(135)

plt.show()


### # 参考

import matplotlib
matplotlib.axes.Axes.scatter
matplotlib.pyplot.scatter
matplotlib.projections.polar
matplotlib.projections.polar.PolarAxes.set_rorigin
matplotlib.projections.polar.PolarAxes.set_theta_zero_location
matplotlib.projections.polar.PolarAxes.set_thetamin
matplotlib.projections.polar.PolarAxes.set_thetamax