Now more generally, for any distribution P, and any function F whose statistics we're trying to estimate, we can approximate the expectation of the function F relative to the distribution P, in terms of this weighted average of the value F. On the sample. 