Nonparametric Estimation of Distributional Functionals and Applications.