<jupyter_start><jupyter_text>Task 5 ( Analysis) Relation between the **Price and Minimum Nights** .In this part we are going to plot a boxplot to see how the price effects the duration of a person's stay at the AirBnB.<jupyter_code>import pandas as pd
import numpy as np
import seaborn as sns
import matplotlib.pyplot as plt
import os
import sys
module_path = os.path.abspath(os.path.join('..'))
if module_path not in sys.path:
    sys.path.append(module_path)
from Scripts import project_functions
df=project_functions.load_and_process('../../Data/raw/listings.csv')
df
sns.boxplot(x = 'minimum_nights', y = 'price', data = df) 
sns.set(rc={'figure.figsize':(15.7,12.27)})<jupyter_output><empty_output><jupyter_text>According to the trend , With increase in the stay of duration the number of people willing to pay greater price decreases. Most of the people who stay for a short period of time often pay more money as compared to people who prefer to stay for longer periods. The price range of 40000 and above could only be seen in the cases where people are spending less nights at the BnB with a few exceptions. Relation between **Price** and **The type of Room** .<jupyter_code>df.boxplot(column='price', by='room_type')<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.08917197452229299, 'fraction_numerical': 0.010350318471337579, 'mean_word_length': 5.2227722772277225, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '356048', 'license': 'MIT', 'n_tokens_mistral': 393, 'n_tokens_neox': 379, 'n_words': 159, 'path': 'Analysis/Submitted/.ipynb_checkpoints/Task5-checkpoint.ipynb', 'repo_name': 'data301-2020-winter2/course-project-group_1025', 'size': '1256'}