How can I do a random selection of nodes or elements in a slice? such as with equal distance but random