Thanks everyone for the advice! editing my original question here:
Say that I have a dataset and my column 'operator has 4 different values. Then, I want to create 4 different scatterplots visualizing the distribution of each of those values (one scatterplot for AB, other for BC and so on):
data = {'Operator':['AB','BC','DE','FG','AB','AB','DE','BC','BC','BC','BC'],
'delay': [22000,25000,27000,35000, 4567, 1893,15373,987,354,1,15]}
data = pd.DataFrame(data)
I've trying to run a for loop based on some examples online because the idea is to iterate through the column. But I am not able to make it work, an example of what I did:
op = data[['Operator', 'delay']]
plt.figure(figsize=(15,10))
for i in op:
plt.subplot(2,2,i[0]+1)
sns.histplot(i[1], hue = 'Operator', data = op)
Thanks for your help! please let me know if this is not clear.