From: Jason Smith (
Date: Tue Jul 06 2021 - 10:28:03 CDT

Is this something you need to do often or a once off? As a once off, you could use a random number generator for e.g. resid or whatever you like, and use those as the selection criteria. tcl does have a generator, not sure if it's implemented in vmd, though.;!!DZ3fjg!qY2TRYCfZxacRgIlw3eovMSDGWNpJ2YcyLfsELNbfNSd3Gr0UWQNGWEEics44b4l5w$

rand<;!!DZ3fjg!qY2TRYCfZxacRgIlw3eovMSDGWNpJ2YcyLfsELNbfNSd3Gr0UWQNGWEEics44b4l5w$ >
Tclers wiki


Jason Smith
Post-Doctoral Fellow
Robert N. Young Lab, Simon Fraser University
8888 University Drive, Burnaby, BC, V5A-1S6

From: <> on behalf of fan li <>
Sent: Tuesday, 6 July 2021 3:23:48 AM
To: vmd-L
Subject: vmd-l: Randomly select molecules and delete them

Dear VMD users

I have a group of molecules with resname PRO, I would like to randomly select 30% of those molecules then delete them. Finally, I would like to write out the PDB and psf files. I do know how to select molecules by atomselection function, but I don't how to randomly select molecules.

Any help would be appreciated.

Thank you