Rates of convergence for radial basis functions and neural networks