We describe new tests, of general application, for deciding whether two proteins or DNA sequences are significantly homologous, in cases where the relationship is neither evidently true nor evidently false. Ralston and Bishop's comparison of the c-myc oncogene with the adenovirus E1a protein is discussed as an example. When the comparison matrix test is used to establish a homology between two sequences it is necessary that the number of high scores exceeds the expected mean level for random sequences by a statistically significant margin. The mean level itself is found from the double matching probability distribution. In examples where the number of high scores is larger than expected, but the highest score is not in itself exceptional, the variance of the numbers of scores expected for unrelated sequences is an important factor. We have analysed these variances by several methods. A simple binomial distribution gives only a rather inaccurate and low first estimate, but we derive a more rigorous and accurate statistical treatment, to take account of the correlations between scores in different parts of the comparison matrix. The theory is exact for random DNA or protein sequences with fluctuating compositions, selected by random draws from an infinite pool. In the more realistic situation, where sequences of fixed composition are formed by random permutations of the original sets, the deviations are smaller, and have been analysed by computer simulation. We find that although the relationship proposed by Ralston & Bishop, between the c-myc oncogene and adenovirus E1a proteins, appears to be significant in the binomial approximation, it is not supported by the full analysis. We conclude that, in general, great care is needed to establish any weak homology on the basis of comparisons that include no truly exceptional high scores, but merely have an enhanced number of scores at the upper end of the expected distribution.