Hypothesis testing when a nuisance parameter is present only under the alternative

SUMMARY We wish to test a simple hypothesis against a family of alternatives indexed by a one-dimensional parameter, 0. We use a test derived from the corresponding family of test statistics appropriate for the case when 0 is given. Davies (1977) introduced this problem when these test statistics had normal distributions. The present paper considers the case when their distribution is chi-squared. The results are applied to the detection of a discrete frequency component of unknown frequency in a time series. In addition quick methods for finding approximate significance probabilities are given for both the normal and chi-squared cases and applied to the two-phase regression problem in the normal case.