intra_rms calculates rms fit values for all states of an object over an atom selection relative to the indicated state. Coordinates are left unchanged. The rms values are returned as a python array.
cmd.intra_rms( string selection, int state)
from pymol import cmd rms = cmd.intra_rms("(name ca)",1)
See Rms for selection caveats for this group of commands.