diff --git a/bootstrap-t.ipynb b/bootstrap-t.ipynb index 705859d..8f5b40c 100644 --- a/bootstrap-t.ipynb +++ b/bootstrap-t.ipynb @@ -46,7 +46,7 @@ }, { "cell_type": "code", - "execution_count": 84, + "execution_count": 86, "metadata": {}, "outputs": [], "source": [ @@ -147,7 +147,7 @@ }, { "cell_type": "code", - "execution_count": 85, + "execution_count": 87, "metadata": {}, "outputs": [ { @@ -162,34 +162,35 @@ } ], "source": [ - "x = dataset['Female height'].to_numpy()\n", - "shapiro_test = stats.shapiro(x)\n", + "ALPHA = 0.05\n", + "female_heights = dataset['Female height'].to_numpy()\n", + "shapiro_test = stats.shapiro(female_heights)\n", "\n", - "if shapiro_test.pvalue > 0.05:\n", + "if shapiro_test.pvalue > ALPHA:\n", " print(\"Female height: Dane mają rozkład normalny.\")\n", "else:\n", " print(\"Female height: Dane nie mają rozkładu normalnego.\")\n", "\n", - "x = dataset['Male height'].to_numpy()\n", - "shapiro_test = stats.shapiro(x)\n", + "male_heights = dataset['Male height'].to_numpy()\n", + "shapiro_test = stats.shapiro(male_heights)\n", "\n", - "if shapiro_test.pvalue > 0.05:\n", + "if shapiro_test.pvalue > ALPHA:\n", " print(\"Male height: Dane mają rozkład normalny.\")\n", "else:\n", " print(\"Male height: Dane nie mają rozkładu normalnego.\")\n", "\n", - "x = dataset['Weight before'].to_numpy()\n", - "shapiro_test = stats.shapiro(x)\n", + "weights_before = dataset['Weight before'].to_numpy()\n", + "shapiro_test = stats.shapiro(weights_before)\n", "\n", - "if shapiro_test.pvalue > 0.05:\n", + "if shapiro_test.pvalue > ALPHA:\n", " print(\"Weight before: Dane mają rozkład normalny.\")\n", "else:\n", " print(\"Weight before: Dane nie mają rozkładu normalnego.\")\n", "\n", - "x = dataset['Weight after'].to_numpy()\n", - "shapiro_test = stats.shapiro(x)\n", + "weights_after = dataset['Weight after'].to_numpy()\n", + "shapiro_test = stats.shapiro(weights_after)\n", "\n", - "if shapiro_test.pvalue > 0.05:\n", + "if shapiro_test.pvalue > ALPHA:\n", " print(\"Weight after: Dane mają rozkład normalny.\")\n", "else:\n", " print(\"Weight after: Dane nie mają rozkładu normalnego.\")\n",