import seaborn as sns
import pandas as pd
import matplotlib.pyplot as plt
# Data for the table (updated with your data)
data = {
'Customer Segment': ['Consumer', 'Corporate', 'Home Office'],
'Historical Expected': [5000.0, 3000.0, 2000.0],
'Market Research Expected': [4000.0, 3500.0, 2500.0],
'Business Goals Expected': [5000.0, 3000.0, 2000.0]
}
# Create a DataFrame
df = pd.DataFrame(data)
# Set the style
sns.set(style="whitegrid")
# Create a heatmap with only the numeric data
plt.figure(figsize=(8, 4)) # Adjust the size as needed
heatmap = sns.heatmap(df.iloc[:, 1:], annot=True, fmt='g', cmap='coolwarm', cbar=False, linewidths=0.5)
# Customize the plot
heatmap.set_xticklabels(df.columns[1:], fontsize=12, fontweight='bold')
heatmap.set_yticklabels(df['Customer Segment'], fontsize=12, fontweight='bold')
plt.title("Expected Values for Customer Segments", fontsize=16)
# Show the plot
plt.tight_layout() # Ensure everything fits in the figure
plt.show()