Say I have a continuous function $f$ defined on a compact interval $I$ on the real line. As is well-known, I could approximate $f$ arbitrarily well by polynomials.

Given $R>0$, how well can we approximate $f$ as a linear combination of functions of the form $x^r$, where $r$ lies in $\lbrack 0,R\rbrack$? If $f$ is analytic, can we express $f$ as an integral $\int_0^R x^r d\mu(r)$?