Use Python blocks!
Something like that:
if (count_atoms nt) == 0
then cmd.delete("nt")
if cmd.count_atoms("nt") == 0: \
cmd.delete("nt")
Note the explicit use of "continuation" lines via backslashes. This ensures
that PyMOL hands over both lines to the Python interpret
Use Python blocks!
> Something like that:
> if (count_atoms nt) == 0
> then cmd.delete("nt")
if cmd.count_atoms("nt") == 0: \
cmd.delete("nt")
Note the explicit use of "continuation" lines via backslashes. This ensures
that PyMOL hands over both lines to the Python interpreter