Statistics for Optimal stochastic signal design and detector randomization in the Neyman-Pearson framework