Skip to content

Instantly share code, notes, and snippets.

@PranjalDureja0002
Created March 15, 2021 09:30
Show Gist options
  • Save PranjalDureja0002/c457976de76e84e8c689eb15d975771a to your computer and use it in GitHub Desktop.
Save PranjalDureja0002/c457976de76e84e8c689eb15d975771a to your computer and use it in GitHub Desktop.
data
age_count = inpatient_data['Age'].value_counts().to_dict()
inpatient_data['Age_Count']=inpatient_data['Age'].map(age_count)
sns.violinplot(x='PotentialFraud',y='Age', data=inpatient_data,width=0.5)
plt.xlabel('potential fraud')
plt.ylabel('Age_of_patients')
plt.title('Age_of_patients vs frauds')
sns.violinplot(x='PotentialFraud',y='Gender', data=inpatient_data,width=0.5)
plt.xlabel('potential fraud')
plt.ylabel('Gender_of_patients')
plt.title('Gender_of_patients vs frauds')
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment