Nonparametric estimation of infinite order regression and its application to the risk-return tradeoff