PracticeVideosBlogFlashcards

5.3 Engineering Data Analysis II — Confidence Intervals, Hypothesis Testing & Regression

Key Takeaways

  • Use the z distribution when σ is known or n > 30; use the t distribution with (n − 1) degrees of freedom when σ is unknown and the sample is small.

  • A 95% confidence interval for a mean is x̄ ± 1.96·(σ/√n) when σ is known; the margin of error shrinks with √n, so quadrupling the sample halves the error.

  • Reject the null hypothesis when the p-value is less than the significance level α, or equivalently when the test statistic falls in the rejection region.

  • Type I error (α) is rejecting a true null hypothesis; Type II error (β) is failing to reject a false one. Test power equals 1 − β.

  • The least-squares slope is b = [nΣxy − ΣxΣy]/[nΣx² − (Σx)²], and the coefficient of determination r² gives the fraction of variation explained by the fitted line.

Last updated: August 2026

5.3 Engineering Data Analysis II — Confidence Intervals, Hypothesis Testing & Regression

The second half of the PRC Enhanced TOS Engineering Data Analysis topic moves from describing a data set to drawing defensible conclusions from it. These are the tools behind load-forecasting studies, meter-accuracy audits, insulation-test acceptance decisions and reliability benchmarking under the Philippine Distribution Code.


1. Sampling Distributions & the Central Limit Theorem

If repeated samples of size nn are drawn from a population with mean μ\mu and standard deviation σ\sigma, the sample means themselves form a distribution with

μxˉ=μσxˉ=σn\mu_{\bar{x}} = \mu \qquad\qquad \sigma_{\bar{x}} = \frac{\sigma}{\sqrt{n}}

The quantity σ/n\sigma/\sqrt{n} is the standard error of the mean. The Central Limit Theorem states that for sufficiently large nn (conventionally n≥30n \ge 30) the distribution of xˉ\bar{x} is approximately normal regardless of the shape of the parent population. This is why normal-based methods work on decidedly non-normal quantities such as outage durations.

Note the n\sqrt{n}: to halve the standard error you must quadruple the sample size.


2. Confidence Intervals

When σ\sigma is known (or n>30n > 30)

xˉ±zα/2σn\bar{x} \pm z_{\alpha/2} \frac{\sigma}{\sqrt{n}}

When σ\sigma is unknown and nn is small

xˉ±tα/2,  νsn,ν=n−1 degrees of freedom\bar{x} \pm t_{\alpha/2,\;\nu} \frac{s}{\sqrt{n}}, \qquad \nu = n - 1 \text{ degrees of freedom}
Confidence levelzα/2z_{\alpha/2}
90%90\%1.6451.645
95%95\%1.9601.960
98%98\%2.3262.326
99%99\%2.5762.576

The tt distribution is wider than the normal, converging to it as ν→∞\nu \to \infty. Choosing zz when the problem states "sample standard deviation" and nn is small is a graded error.


3. Hypothesis Testing

A hypothesis test compares a null hypothesis H0H_0 (the status quo — "the meters meet the accuracy class") against an alternative H1H_1.

Test statistic for a mean

z=xˉ−μ0σ/nt=xˉ−μ0s/nz = \frac{\bar{x} - \mu_0}{\sigma / \sqrt{n}} \qquad\qquad t = \frac{\bar{x} - \mu_0}{s / \sqrt{n}}

Decision rule

Reject H0H_0 when the test statistic falls in the rejection region, equivalently when p<αp < \alpha.

The two error types

H0H_0 actually trueH0H_0 actually false
Reject H0H_0Type I error, probability α\alphaCorrect decision, probability 1−β1-\beta (power)
Fail to reject H0H_0Correct decision, probability 1−α1-\alphaType II error, probability β\beta

In electrical acceptance testing, a Type I error rejects a good batch (producer's risk); a Type II error accepts a defective batch (consumer's risk). Reducing α\alpha without increasing nn necessarily increases β\beta.

One-tailed vs. two-tailed

"Is the mean different from 220 V?" is two-tailed. "Is the loss greater than 150 W?" is one-tailed, and the whole of α\alpha sits in one tail, so the critical value is smaller (1.645 rather than 1.96 at 95%).


4. Linear Regression & Correlation

The least-squares line y=a+bxy = a + bx minimises ∑(yi−y^i)2\sum (y_i - \hat{y}_i)^2:

b=n∑xy−∑x∑yn∑x2−(∑x)2a=yˉ−bxˉb = \frac{n\sum xy - \sum x \sum y}{n\sum x^{2} - \left(\sum x\right)^{2}} \qquad\qquad a = \bar{y} - b\bar{x}

The Pearson correlation coefficient measures linear association:

r=n∑xy−∑x∑y[n∑x2−(∑x)2][n∑y2−(∑y)2],−1≤r≤1r = \frac{n\sum xy - \sum x \sum y}{\sqrt{\left[n\sum x^{2} - (\sum x)^{2}\right]\left[n\sum y^{2} - (\sum y)^{2}\right]}}, \qquad -1 \le r \le 1

The coefficient of determination r2r^{2} is the proportion of the variation in yy explained by the regression on xx. An r=0.9r = 0.9 means r2=0.81r^{2} = 0.81, so 81% of the variation is explained — not 90%.

Correlation is not causation, and rr measures only linear association: a perfect parabola can have r≈0r \approx 0.


5. Designed Experiments & Statistical Process Control

TermMeaning in electrical practice
Factor / levelControlled input (e.g. conductor temperature) and its settings
ResponseMeasured output (e.g. measured ampacity)
ReplicationRepeating runs to estimate pure experimental error
RandomisationOrdering runs randomly to neutralise lurking variables
BlockingGrouping similar units to remove a known nuisance source
ANOVAPartitioning total variation into between-treatment and within-treatment components; the FF ratio tests treatment significance
Xˉ\bar{X}–R control chartPlots subgroup means and ranges against ±3σ\pm 3\sigma control limits to detect process drift

Control limits are not specification limits: control limits describe what the process actually does, while specification limits state what the customer requires.


Solved Board Exam Examples

Example 1: Confidence Interval on Feeder Voltage

Thirty-six voltage readings on a distribution feeder average 228.4 V with a known population standard deviation of 3.6 V. Construct the 95% confidence interval for the true mean voltage.

Solution. With σ\sigma known and n=36n = 36, use z0.025=1.96z_{0.025} = 1.96:

ME=1.96×3.636=1.96×0.60=1.176 V\text{ME} = 1.96 \times \frac{3.6}{\sqrt{36}} = 1.96 \times 0.60 = 1.176 \text{ V} 228.4±1.176  ⟹  227.22 V≤μ≤229.58 V228.4 \pm 1.176 \implies \boxed{227.22 \text{ V} \le \mu \le 229.58 \text{ V}}

The whole interval lies inside the ±10%\pm 10\% service-voltage band, so the feeder is compliant.

Example 2: Hypothesis Test on Transformer Efficiency

A manufacturer claims a mean efficiency of at least 98.5%. Sixteen units average 98.2% with a sample standard deviation of 0.4%. Test the claim at α=0.05\alpha = 0.05.

Solution. H0:μ≥98.5%H_0: \mu \ge 98.5\% against H1:μ<98.5%H_1: \mu < 98.5\% (one-tailed, left). With σ\sigma unknown and n=16n = 16, use tt with ν=15\nu = 15:

t=98.2−98.50.4/16=−0.30.1=−3.00t = \frac{98.2 - 98.5}{0.4/\sqrt{16}} = \frac{-0.3}{0.1} = -3.00

The one-tailed critical value is t0.05,15=−1.753t_{0.05,15} = -1.753. Since −3.00<−1.753-3.00 < -1.753, reject H0H_0: at the 5% level the evidence contradicts the manufacturer's efficiency claim.

Example 3: Least-Squares Load Growth

Peak demand over four years is: year 1, 12.0 MW; year 2, 12.9 MW; year 3, 13.6 MW; year 4, 14.7 MW. Fit a least-squares line and forecast year 6.

Solution. With n=4n = 4: ∑x=10\sum x = 10, ∑y=53.2\sum y = 53.2, ∑xy=138.3\sum xy = 138.3, ∑x2=30\sum x^2 = 30.

b=4(138.3)−(10)(53.2)4(30)−(10)2=553.2−532120−100=21.220=1.06 MW/yrb = \frac{4(138.3) - (10)(53.2)}{4(30) - (10)^{2}} = \frac{553.2 - 532}{120 - 100} = \frac{21.2}{20} = 1.06 \text{ MW/yr} a=53.24−1.06(104)=13.30−2.65=10.65 MWa = \frac{53.2}{4} - 1.06\left(\frac{10}{4}\right) = 13.30 - 2.65 = 10.65 \text{ MW} y^(6)=10.65+1.06(6)=17.01 MW\hat{y}(6) = 10.65 + 1.06(6) = \boxed{17.01 \text{ MW}}
Loading diagram...
Choosing Between z and t, Estimation and Testing
Test Your Knowledge

A sample of 25 insulation resistance readings has an unknown population standard deviation. Which statistic and how many degrees of freedom should be used to build the confidence interval?

A

z statistic; degrees of freedom do not apply

B

t statistic with 25 degrees of freedom

C

z statistic with 24 degrees of freedom

D

t statistic with 24 degrees of freedom

Test Your Knowledge

An acceptance test wrongly rejects a batch of circuit breakers that actually meets specification. Which error has occurred?

A

Type II error, probability β

B

Systematic bias, probability 1 - β

C

Sampling error, probability 1 - α

D

Type I error, probability α

Test Your Knowledge

A regression of demand on ambient temperature yields a correlation coefficient r = 0.80. What percentage of the variation in demand is explained by the fitted line?

A

80%

B

89%

C

20%

D

64%

Sections you finish are checked off in the contents.