Pie Chart

Database Technology Usage

Dark theme donut showing database market share

Output
Database Technology Usage
Python
import matplotlib.pyplot as plt
import numpy as np

fig, ax = plt.subplots(figsize=(10, 6), facecolor='#0a0a0f')
ax.set_facecolor('#0a0a0f')

databases = ['PostgreSQL', 'MySQL', 'MongoDB', 'Redis', 'SQLite', 'Others']
usage = [28, 25, 20, 12, 10, 5]
colors = ['#336791', '#4479a1', '#4db33d', '#dc382d', '#003b57', '#6b7280']

wedges, texts, autotexts = ax.pie(usage, labels=databases, autopct='%1.0f%%',
                                   colors=colors, startangle=90,
                                   wedgeprops={'width': 0.55, 'edgecolor': '#0a0a0f', 'linewidth': 2})

for text in texts:
    text.set_color('white')
    text.set_fontsize(10)
for autotext in autotexts:
    autotext.set_color('white')
    autotext.set_fontweight('bold')

centre_circle = plt.Circle((0, 0), 0.35, fc='#0a0a0f')
ax.add_patch(centre_circle)
ax.text(0, 0, 'DB\n2024', ha='center', va='center', fontsize=12, fontweight='bold', color='white')

ax.set_title('Database Technology Usage', fontsize=16, fontweight='bold', color='white', pad=20)
plt.tight_layout()
Library

Matplotlib

Category

Basic Charts

Did this help you?

Support PyLucid to keep it free & growing

Support