document.write( "Question 1165668: Pregnant women (within month 4) who were being followed-up by a nutritionist had
\n" );
document.write( "weights (kg) equal to: 59, 66, 69, 65, 70, 55, 59, 82, 61, 74.
\n" );
document.write( "(a) Calculate the:
\n" );
document.write( "(i) mean? (4 marks)
\n" );
document.write( "(ii) median? (4 marks)
\n" );
document.write( "(iii) standard deviation (7 marks)
\n" );
document.write( "(b) Calculate the skewness of the distribution of these weights? (3 marks)
\n" );
document.write( "(c) Calculate the coefficient of variation \n" );
document.write( "
Algebra.Com's Answer #852948 by CPhill(2138) You can put this solution on YOUR website! ```python?code_reference&code_event_index=2 \n" ); document.write( "import numpy as np \n" ); document.write( "from scipy.stats import skew\r \n" ); document.write( "\n" ); document.write( "# Data (weights in kg) \n" ); document.write( "weights = np.array([59, 66, 69, 65, 70, 55, 59, 82, 61, 74]) \n" ); document.write( "n = len(weights)\r \n" ); document.write( "\n" ); document.write( "# (a) (i) Mean \n" ); document.write( "mean_weight = np.mean(weights)\r \n" ); document.write( "\n" ); document.write( "# (a) (ii) Median \n" ); document.write( "median_weight = np.median(weights)\r \n" ); document.write( "\n" ); document.write( "# (a) (iii) Standard Deviation (Sample, using n-1 denominator) \n" ); document.write( "std_dev = np.std(weights, ddof=1)\r \n" ); document.write( "\n" ); document.write( "# (b) Skewness (Sample skewness using default unbiased calculation) \n" ); document.write( "skewness = skew(weights, bias=False)\r \n" ); document.write( "\n" ); document.write( "# (c) Coefficient of Variation (CV) \n" ); document.write( "cv = (std_dev / mean_weight) * 100\r \n" ); document.write( "\n" ); document.write( "print(f\"Number of observations (n): {n}\") \n" ); document.write( "print(f\"Mean (x_bar): {mean_weight}\") \n" ); document.write( "print(f\"Median (M): {median_weight}\") \n" ); document.write( "print(f\"Standard Deviation (s): {std_dev}\") \n" ); document.write( "print(f\"Skewness: {skewness}\") \n" ); document.write( "print(f\"Coefficient of Variation (CV): {cv}\")\r \n" ); document.write( "\n" ); document.write( "```\r \n" ); document.write( "\n" ); document.write( "```text?code_stdout&code_event_index=2 \n" ); document.write( "Number of observations (n): 10 \n" ); document.write( "Mean (x_bar): 66.0 \n" ); document.write( "Median (M): 65.5 \n" ); document.write( "Standard Deviation (s): 8.096638534327413 \n" ); document.write( "Skewness: 0.6688274664021394 \n" ); document.write( "Coefficient of Variation (CV): 12.267634142920322\r \n" ); document.write( "\n" ); document.write( "```\r \n" ); document.write( "\n" ); document.write( "Here are the calculated descriptive statistics for the weights of the pregnant women:\r \n" ); document.write( "\n" ); document.write( "The raw data is: $59, 66, 69, 65, 70, 55, 59, 82, 61, 74$. \n" ); document.write( "The sample size is $n=10$.\r \n" ); document.write( "\n" ); document.write( "-----\r \n" ); document.write( "\n" ); document.write( "## (a) Central Tendency and Dispersion\r \n" ); document.write( "\n" ); document.write( "### (i) Mean ($\bar{x}$)\r \n" ); document.write( "\n" ); document.write( "The mean is the average weight, calculated as the sum of all weights divided by the number of observations. \n" ); document.write( "$$\bar{x} = \frac{\sum x}{n} = \frac{660}{10}$$ \n" ); document.write( "$$\mathbf{\text{Mean} = 66.0 \text{ kg}}$$\r \n" ); document.write( "\n" ); document.write( "### (ii) Median ($M$)\r \n" ); document.write( "\n" ); document.write( "The median is the middle value of the data when sorted. \n" ); document.write( "Sorted data: $55, 59, 59, 61, \mathbf{65, 66}, 69, 70, 74, 82$ \n" ); document.write( "Since $n$ is even (10), the median is the average of the two middle values (the 5th and 6th values): \n" ); document.write( "$$M = \frac{65 + 66}{2}$$ \n" ); document.write( "$$\mathbf{\text{Median} = 65.5 \text{ kg}}$$\r \n" ); document.write( "\n" ); document.write( "### (iii) Standard Deviation ($s$)\r \n" ); document.write( "\n" ); document.write( "The standard deviation measures the spread of the data around the mean. We calculate the **sample standard deviation** (using $n-1$ in the denominator). \n" ); document.write( "$$\mathbf{\text{Standard Deviation } (s) \approx 8.097 \text{ kg}}$$\r \n" ); document.write( "\n" ); document.write( "-----\r \n" ); document.write( "\n" ); document.write( "## (b) Skewness of the Distribution\r \n" ); document.write( "\n" ); document.write( "Skewness measures the asymmetry of the probability distribution. \n" ); document.write( "$$\mathbf{\text{Skewness} \approx 0.669}$$\r \n" ); document.write( "\n" ); document.write( "**Interpretation:** Since the skewness value is **positive** ($0.669 > 0$), the distribution of weights is **positively (right) skewed**. This means the tail of the distribution is longer on the right side, suggesting there are a few relatively higher weights pulling the mean above the median ($66.0 > 65.5$).\r \n" ); document.write( "\n" ); document.write( "-----\r \n" ); document.write( "\n" ); document.write( "## (c) Coefficient of Variation\r \n" ); document.write( "\n" ); document.write( "The Coefficient of Variation (CV) expresses the standard deviation as a percentage of the mean, providing a measure of relative variability. \n" ); document.write( "$$\text{CV} = \frac{s}{\bar{x}} \times 100\%$$ \n" ); document.write( "$$\text{CV} = \frac{8.0966}{66.0} \times 100\%$$ \n" ); document.write( "$$\mathbf{\text{Coefficient of Variation } (\text{CV}) \approx 12.27\%}$$\r \n" ); document.write( "\n" ); document.write( "**Interpretation:** The weights have a relative variability of about **$12.27\%$** with respect to the mean weight. \n" ); document.write( " |