Floaters are a bit different because they are behind the lens. It's more comparable with dust on the sensor in an SLR (or dust in the sensor cavity)
That is also more noticeable with lower aperture but for a different reason. With a low aperture the light comes more from a single direction so the shadow from the dust particles is more defined. The same happens with the floaters. The reason you only see them when looking at the sky is because they're pretty transparent and you need a bright detailless surface to see the low contrast they provide.
But it's very different from scratches on a lens surface because those are in front of the optics.