<jupyter_start><jupyter_text>Plotting the Data Use proper labeling of the plots using plot titles (including date of analysis) and axes labels.Save the plotted figures as .pngs.<jupyter_code>#Latitude vs. Temperature Plot
plt.scatter(weather_dictionary["Lat"], weather_dictionary["Max Temp"], facecolor = "lightblue", edgecolor = "black")
plt.title("City Latitude vs. Max Temperature (01/17/20)")
plt.xlabel("Latitude")
plt.ylabel("Maximum Temperature (F)")
plt.grid(linestyle='-', linewidth=1, alpha = 0.5)
# Save the plotted figure as .pngs
plt.savefig("Latitude vs Max Temperature.png")<jupyter_output><empty_output><jupyter_text>Observation- Latitude vs Max Temperature.png:As the latitude increases, temperature drops and the maximum temp. is found around 0 latitude.<jupyter_code>#Latitude vs. Humidity Plot
plt.scatter(weather_dataframe["Lat"], weather_dataframe["Humidity"], marker='o', s=30, edgecolors= "black")
plt.title("City Latitude vs Humidity")
plt.ylabel("Humidity Level (%)")
plt.xlabel("Latitude")
plt.grid()
plt.savefig("Latitude vs Humidity.png")<jupyter_output><empty_output><jupyter_text>Observation- Latitude vs Humidity:As the latitude gets higher,humidity gets higher too<jupyter_code>#Latitude vs. Cloudiness Plot
plt.scatter(weather_dataframe["Lat"], weather_dataframe["Cloudiness"], marker='o', s=30, edgecolors= "black")
plt.title("City Latitude vs Cloudiness")
plt.ylabel("Cloudiness Level (%)")
plt.xlabel("Latitude")
plt.grid()
# plt.show()
plt.savefig("Latitude vs Cloudiness.png")<jupyter_output><empty_output><jupyter_text>Observation- Latitude vs Cloudiness: Cloudiness is all over the latitude.<jupyter_code>#Latitude vs. Wind Speed Plot
plt.scatter(weather_dataframe["Lat"], weather_dataframe["Wind Speed"], marker='o', s=30, edgecolors= "black")
plt.title("City Latitude vs Wind Speed")
plt.ylabel("Wind Speed (mph)")
plt.xlabel("Latitude")
plt.grid()
plt.savefig("Latitude vs Wind Speed.png")<jupyter_output><empty_output><jupyter_text>Observation- Latitude vs Wind Speed:Wind Speed is present across the latitude<jupyter_code>#Linear Regression

# Create Northern and Southern Hemisphere DataFrames
northern_hemisphere = weather_dataframe.loc[weather_dataframe["Lat"] >= 0]
southern_hemisphere = weather_dataframe.loc[weather_dataframe["Lat"] < 0]
#Northern Hemisphere - Max Temp vs. Latitude Linear Regression

#Create a Scatter Plot for Lattitude vs Temperature of City
x_values = northern_hemisphere['Lat']
y_values = northern_hemisphere['Max Temp']
(slope, intercept, rvalue, pvalue, stderr) = linregress(x_values, y_values)
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"red")
plt.annotate(line_eq,(5,10),fontsize=15,color="red")
plt.ylim(0,100)
plt.xlim(0, 80)

plt.ylabel("Max. Temp")
plt.xlabel("Latitude")
plt.savefig("North Max Temp vs Latitude Regression.png")<jupyter_output><empty_output><jupyter_text>Observation: negative correlation between latitude and Max Temperature in Northern Hemisphere<jupyter_code>#Southern Hemisphere - Max Temp vs. Latitude Linear Regression

#Create a Scatter Plot for Lattitude vs Temperature of City (Southern Hemisphere)
x_values = southern_hemisphere['Lat']
y_values = southern_hemisphere['Max Temp']
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(6,10),fontsize=15,color="red")
plt.ylim(30, 100)
plt.xlim(-60, 0, 10)

plt.ylabel("Max. Temp")
plt.xlabel("Latitude")
plt.savefig("South Max Temp vs Latitude Regression.png")
#Northern Hemisphere - Humidity (%) vs. Latitude Linear Regression
x_values = northern_hemisphere['Lat']
y_values = northern_hemisphere['Humidity']
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(6,10),fontsize=15,color="red")
plt.ylabel("Humidity")
plt.xlabel("Latitude")
plt.savefig("North Humidity vs Latitude Linear Regression.png")<jupyter_output><empty_output><jupyter_text>Observation: Negative constant correlation<jupyter_code>#Southern Hemisphere - Humidity (%) vs. Latitude Linear Regression

x_values = southern_hemisphere['Lat']
y_values = southern_hemisphere['Humidity']
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(-25,10),fontsize=15,color="red")

plt.ylim(0, 100)

plt.ylabel("Humidity")
plt.xlabel("Latitude")
plt.savefig("South  Humidity vs Latitude Linear Regression.png")
#Northern Hemisphere - Cloudiness (%) vs. Latitude Linear Regression
x_values = northern_hemisphere['Lat']
y_values = northern_hemisphere['Cloudiness']
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(6,10),fontsize=15,color="red")
plt.ylabel("Cloudiness")
plt.xlabel("Latitude")
plt.savefig("North  Cloudiness vs Latitude Linear Regression.png")
#Southern Hemisphere - Cloudiness (%) vs. Latitude Linear Regression
x_values = southern_hemisphere['Lat']
y_values = southern_hemisphere['Cloudiness']
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(-25,10),fontsize=15,color="red")
plt.ylabel("Cloudiness")
plt.xlabel("Latitude")
plt.savefig("South  Cloudiness vs Latitude Linear Regression.png")
#Northern Hemisphere - Wind Speed (mph) vs. Latitude Linear Regression
x_values = northern_hemisphere['Lat']
y_values = northern_hemisphere['Wind Speed']
(slope, intercept, rvalue, pvalue, stderr) = linregress(x_values, y_values)
reg_values = x_values * slope + intercept
line_eq = "y = " + str(round(slope,2)) + "x + " + str(round(intercept,2))
plt.scatter(x_values,y_values)
plt.plot(x_values,reg_values,"r-")
plt.annotate(line_eq,(45,22),fontsize=15,color="red")
plt.ylabel("Cloudiness")
plt.xlabel("Latitude")
plt.savefig("North  Wind speed vs Latitude Linear Regression.png")<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.14352428393524283, 'fraction_numerical': 0.014165628891656288, 'mean_word_length': 7.837689133425035, 'pattern_counts': {'":': 0, '<': 30, '<?xml version=': 0, '>': 30, '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': '7', 'dir': 'jupyter-structured-clean-dedup', 'id': '7562', 'license': 'ADSL', 'n_tokens_mistral': 2431, 'n_tokens_neox': 2219, 'n_words': 468, 'path': 'WeatherPy/WeatherPy.ipynb', 'repo_name': 'mariaalzaga/python_api_challenge', 'size': '6424'}