Advertisement
elena1234

take the mean of the first 100 rows in Python

May 11th, 2022
835
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.19 KB | None | 0 0
  1. '''
  2. # One possible way of doing this is:
  3. pd.Series.mean(df[df.RIDAGEYR > 60].loc[range(0,100), 'BPXSY1'])
  4. # Current version of python will include this warning, older versions will not
  5. '''
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement