Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 51 additions & 14 deletions Solutions.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,13 @@
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "39c6f717",
"cell_type": "markdown",
"id": "eac7b071",
"metadata": {},
"outputs": [],
"source": []
"source": [
"H₀: the mean systolic blood pressure of the Honolulu sample is significantly different from the population mean\\\n",
"H₁: the mean systolic blood pressure of the Honolulu sample is not significantly different from the population mean"
]
},
{
"cell_type": "markdown",
Expand All @@ -49,12 +50,12 @@
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "b09ce149",
"cell_type": "markdown",
"id": "2abffa55",
"metadata": {},
"outputs": [],
"source": []
"source": [
"Not clear what to do here."
]
},
{
"cell_type": "markdown",
Expand All @@ -66,11 +67,47 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 2,
"id": "97f73e20",
"metadata": {},
"outputs": [],
"source": []
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Statistic is: 4.761904761904759\n"
]
}
],
"source": [
"sample_mean = 130.1\n",
"pop_mean = 120\n",
"sample_std = 21.21\n",
"n = 100\n",
"statistic = (130.1 - 120)/(21.21/(n**0.5))\n",
"print(\"Statistic is: \", statistic)"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "9f287f12",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Statistic is: 4.761904761904759\n"
]
}
],
"source": [
"import math\n",
"\n",
"statistic = (sample_mean - pop_mean)/(sample_std/math.sqrt(n))\n",
"print(\"Statistic is: \", statistic)"
]
},
{
"cell_type": "markdown",
Expand All @@ -97,7 +134,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.5"
"version": "3.8.8"
}
},
"nbformat": 4,
Expand Down