Last active
          October 13, 2019 11:42 
        
      - 
      
 - 
        
Save MariaLavrovskaya/7b7d7c200d23c8a3513803c34609e90a to your computer and use it in GitHub Desktop.  
     airbnb_1
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | import pandas as pd | |
| from scipy import median | |
| from scipy.stats import mode | |
| data=pd.read_csv('AB_NYC_2019.csv') | |
| data.head() | |
| data.describe().T | |
| #Calculating the median for one of the rows | |
| reviews= data.loc[:,['number_of_reviews']] | |
| reviews.dropna() | |
| median(reviews) | |
| #Calculating the mode for one of the rows | |
| mode(reviews.values.T, axis=None) | |
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment