Refining label and size.

This commit is contained in:
Julien Palard 2021-10-23 18:25:17 +02:00
parent 5e1de08481
commit 037e766729
Signed by: mdk
GPG Key ID: 0EFC1AC1006886F8
2 changed files with 4 additions and 2 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

After

Width:  |  Height:  |  Size: 53 KiB

View File

@ -116,10 +116,12 @@ def plot_main():
mean_date(row["start_date"], row["end_date"])
)
by_version[row["python_version"]][1].append(row["download_count"])
plt.figure(figsize=(16, 8))
plt.figure(figsize=(10, 10 * 2 / 3))
for version, (x, y) in by_version.items():
if version is None:
continue
if len(x) <= 2:
plt.plot(x, y)
plt.plot(x, y, label=version)
continue
smooth_x = np.linspace(date2num(min(x)), date2num(max(x)), 200)
spline = make_interp_spline([date2num(d) for d in x], y, k=2)