A normative inference approach for optimal sample sizes in decisions from experience