Why the code not works? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Why the code not works?

import numpy as np import scipy as sp import pandas as pd import matplotlib.pyplot as plt import seaborn as sb database = sb.load_dataset('tips') print(database) sb.jointplot(x='tip',y='total_bill',data='database') plt.show()

23rd Jul 2021, 2:06 AM
SHIVAM KUMAR
SHIVAM KUMAR - avatar
2 Answers
+ 2
sb.jointplot(x='tip', y='total_bill', data=database) Do not put the database in quotes. In this case, database is a variable that contains your data frame. Why are you importing so many modules, if you don't use them? https://code.sololearn.com/cn33rU66Tgmg/?ref=app
23rd Jul 2021, 3:02 AM
Tibor Santa
Tibor Santa - avatar
+ 1
Thnx bro. Actually I am in hurry so I post it with other modules which I need to work on.
24th Jul 2021, 5:16 PM
SHIVAM KUMAR
SHIVAM KUMAR - avatar