We're trying to improve search results, and we're trying to determine if certain changes (adding a word to a synonym list, removing it from the query, etc) have a statistically significant improvement on the results for future searches.
We currently have data for past queries and their matching "correct" results. We also have tests to sample from those past queries, perform them again, and look at the percentage of "good matches". A good match being one for which the known correct result is within the top recommendations by the search engine.
For a concrete example: say we want to know if adding a synonym for show->display will improve results. We look through past queries and find all of those containing the word 'show', then we find the number of good matches. Then we add the synonym map, and test again for the same sample of queries.
The results let us know how many queries improved, how many got worse, how many stayed the same, total number of samples, and total number of good matches (before and after the test).
To get an idea of the numbers, we have about 260,000 past queries, and for most words there are less than 10,000 queries which contain those words (and thus we can test the entire sample).
For this example the results are:
Sample size containing 'show': 5250
Good matches (base): 3212
Good matches (test): 3208
Improved: 8
Got worse: 12
Total change: -4
The question is which test(s) would be the most helpful in determining if this change is likely to represent the change in future unknown queries? (Using a 95% confidence level)
Here's the things I've tried on R, and their results:
- Two sample T-test on both sets of data (represented by vectors of 1s and 0s) - not significant
- T-test on the difference of the sets - not significant
- Bootstrapping on the difference in mean of each set, and doing a T-test of that result - significant
- Bootstrapping each sample on their mean, then T-test two sample t-test of the results - significant
- Bootstrapping each sample on their mean, then t-test of the difference in the results - significant
- McNemar test - significant