Python Forum
Pandas dataframe indexing
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pandas dataframe indexing
#1
I am new to python and have decided to take a self-paced free course. i attempting to generate a scatter plot for "price" vs "area" in the state of "Rio Grande do Sul" in the dataframe shown in the attached photo. My code just returns a ton of errors, kindly assist.

Here's my code shown below:
plt.scatter(df_south.groupby("state" == "Rio Grande do Sul")["price_usd"], df_south.groupby("state" == "Rio Grande do Sul")["area_m2"])

Attached Files

Thumbnail(s)
   
Reply
#2
Pls post your code using python tags, and your error using the error tags
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How can I convert specific rows from excel to pandas dataframe? mcva 1 1,795 Apr-20-2020, 09:14 AM
Last Post: pyzyx3qwerty
  Histogram using pandas dataframe not showing proper output ift38375 1 2,184 Jul-04-2019, 10:43 PM
Last Post: scidam
  pandas dataframe next rows value metalray 2 10,138 Mar-06-2017, 11:31 AM
Last Post: metalray
  pandas dataframe group by count index metalray 5 10,267 Mar-01-2017, 09:14 AM
Last Post: metalray
  pandas dataframe.replace regex metalray 3 24,622 Feb-24-2017, 12:58 PM
Last Post: zivoni
  pandas dataframe substracting columns: key error metalray 2 7,023 Feb-24-2017, 07:59 AM
Last Post: metalray

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020