<jupyter_start><jupyter_text>More advanced<jupyter_code>z = y / 4.0

plt.figure(figsize=(12, 7))
plt.plot(x, y, label="high")
plt.plot(x, z, label="low")

plt.ylim(-6, 7)

plt.annotate(r'$\pi sin(x) + \pi cos(\pi x) + \pi sin(x + \pi )$',
            xy=(2, 5), xycoords='data',
            xytext=(+3, +5.5), textcoords='data', fontsize=15,
            arrowprops=dict(arrowstyle="->",connectionstyle="arc3,rad=.2"),
            )

plt.plot([0, 10], [0, 0], color='grey', linestyle='-.')
plt.plot([2, 2],[0, 10], color='blue', linewidth=1, linestyle="--");
plt.figure(figsize=(12, 7))
plt.hist(np.random.randn(1000));
plt.figure(figsize=(12, 7))
plt.boxplot(np.random.randn(50));
import sklearn.datasets as d
iris = d.load_iris()

print(iris.DESCR)
plt.figure(figsize=(12, 7))
plt.boxplot(iris.data)

plt.xticks(range(1, len(iris.data[0]) + 1), ['sepal length', 'sepal width', 'petal length', 'petal width'] )
plt.ylim(-1, 9)
import seaborn as sns
sns.distplot(np.random.randn(1000));
crashes = sns.load_dataset('car_crashes')
crashes.head()
sns.jointplot(x='alcohol', y='total', kind="reg", data=crashes);
iris = sns.load_dataset("iris")
iris.head()
sns.FacetGrid(iris, hue="species", size=5) \
  .map(plt.scatter, "sepal_length", "sepal_width") \
  .add_legend();
sns.swarmplot(x="species", y="petal_length", data=iris);
import pandas as pd
melt_iris = pd.melt(iris, "species", var_name="measurement")
fig, ax = plt.subplots()
fig.set_size_inches(14, 7)
sns.boxplot(x="measurement", y="value", hue="species", data=melt_iris);
fig, ax = plt.subplots()
fig.set_size_inches(14, 10)
sns.swarmplot(x="measurement", y="value", hue="species", data=melt_iris);<jupyter_output><empty_output>
StarcoderdataJupyterStructuredCleanDedup