Optimal sampling for parameters estimation