# Examples for integration estimator

suppose I'm interested in estimating $$C=\int_{a}^{b}g(x)dx$$, where $$a$$ and $$b$$ are known, and $$g(x)=E(Y|X=x)$$ is an unknown function of $$x$$. The data I have is $$\{Y_{i},X_{i}\}_{i=1}^{n}$$, then a natural estimator for $$C$$ could be obtained as follows:

First, obtain a nonparametric estimate for $$g(x)$$: for example, the local constant estimator $$\widehat{g}(x)=\frac{\sum_{i=1}^{n}Y_{i}k(\frac{X_{i}-x}{h})}{\sum_{i=1}^{n}k(\frac{X_{i}-x}{h})}$$ (we can also use local polynomial estimate).

Second, we do numerical integration over $$[a,b]$$ using $$\widehat{g}(x)$$ and get the estimate: $$\widehat{C}=\frac{1}{M}\sum_{m=0}^{M}\widehat{g}(x_{m})$$ with $$\{x_{0},...,x_{M}\}$$ be an equally distanced grid from $$a$$ to $$b$$ satisfying $$x_{0}=a$$ and $$x_{M}=b$$.

Are there any existing estimators like this or in the same spirit? Examples, papers or book chapters are welcome. Thanks!