# PairedZTest

PairedZTest[data]

tests whether the mean of the data is zero.

PairedZTest[{data1,data2}]

tests whether the means of data1 and data2 are equal.

PairedZTest[dspec,σ]

tests for zero or equal means assuming a population variance σ.

PairedZTest[dspec,σ,μ0]

tests the mean against μ0.

PairedZTest[dspec,σ,μ0,"property"]

returns the value of "property".

# Details and Options   • Given data1 and data2, PairedZTest performs a test on the paired differences of the two datasets.
• PairedZTest tests the null hypothesis against the alternative hypothesis :
•  data  {data1,data2}  • where μ is the population mean for data and μ12 is the mean of the paired differences of the two datasets .
• By default, a probability value or -value is returned.
• A small -value suggests that it is unlikely that is true.
• The data in dspec can be univariate {x1,x2,} or multivariate {{x1,y1,},{x2,y2,},}.
• The argument σ can be any positive real number or a positive definite matrix with dimension equal to the dimension of data.
• The argument μ0 can be a real number or a real vector with length equal to the dimension of the data.
• PairedZTest assumes that the data is normally distributed and that the variance is known and not estimated from the data.
• If variances or covariance matrices are not provided, PairedZTest treats the sample estimate as the known variance or covariance.
• PairedZTest[dspec,σ,μ0,"HypothesisTestData"] returns a HypothesisTestData object htd that can be used to extract additional test results and properties using the form htd["property"].
• PairedZTest[dspec,σ,μ0,"property"] can be used to directly give the value of "property".
• Properties related to the reporting of test results include:
•  "DegreesOfFreedom" the degrees of freedom of a test "PValue" list of -values "PValueTable" formatted table of -values "TestData" list of pairs of test statistics and -values "TestDataTable" formatted table of -values and test statistics "TestStatistic" list of test statistics "TestStatisticTable" formatted table of test statistics
• If a known variance σ is not provided, PairedZTest performs a -test assuming the sample variance is the known variance for univariate data and Hotelling's test assuming the sample covariance is the known covariance for multivariate data.
• Options include:
•  AlternativeHypothesis "Unequal" the inequality for the alternative hypothesis SignificanceLevel 0.05 cutoff for diagnostics and reporting VerifyTestAssumptions Automatic what assumptions to verify
• For tests of location, a cutoff is chosen such that is rejected if and only if . The value of used for the "TestConclusion" and "ShortTestConclusion" properties is controlled by the SignificanceLevel option. This value is also used in diagnostic tests of assumptions including tests for normality, equal variance, and symmetry. By default, is set to 0.05.
• Named settings for VerifyTestAssumptions in PairedZTest include:
•  "Normality" verify that all data is normally distributed

# Examples

open all close all

## Basic Examples(3)

Test whether the mean of a population is zero:

 In:= In:= Out= The full test table:

 In:= Out= Test whether the means of two dependent populations differ:

 In:= The mean of the differences:

 In:= Out= In:= Out= At the 0.05 level, the mean of the differenced data is not significantly different from 0:

 In:= Out= Compare the locations of dependent multivariate populations:

 In:= The mean of the differences:

 In:= Out= In:= Out= At the 0.05 level, the mean of the differenced data is not significantly different from 0:

 In:= Out= ## Neat Examples(1)

Introduced in 2010
(8.0)