Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- df2= df1.groupby(['Car_Type'])['price'].mean()
- df1.loc[df1['Car_Type']=='Land Rover','price'] = df2['Land Rover']
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement