An exact computation of the persistent Betti numbers of a submanifold $X$ of a Euclidean space is possible only in a theoretical setting. In practical situations, only a finite sample of $X$ is available. We show that, under suitable density conditions, it is possible to estimate the multidimensional persistent Betti numbers of $X$ from the ones of a union of balls centered on the sample points; this even yields the exact value in restricted areas of the domain. Using these inequalities we improve a previous lower bound for the natural pseudodistance to assess dissimilarity between the shapes of two objects from a sampling of them. Similar inequalities are proved for the multidimensional persistent Betti numbers of the ball union and the one of a combinatorial description of it.