We prove in dimension d=1 a result similar to a classical paper by Soffer and Weinstein, Jour. Diff. Eq. 98 (1992), improving it by encompassing for pure power nonlinearities the whole range of exponents p>1. The proof is based on the virial inequality of Kowalczyk et al., J. Eur. Math. Soc. (JEMS) 24 (2022), with smoothing estimates as shown in Mizumachi J. Math. Kyoto Univ. 48 (2008).