Next / Previous / Contents / Shipman's homepage

19.6. Taxon.abbr(): Is there a standard code?

Higher taxa will not have a code unless there one is defined in the alternate forms file. In any case, if there is a disambiguated code, it takes precedence over the canonical code. The method returns None if neither code contains a string.

nomcompile3
# - - -   T a x o n . a b b r

    def abbr ( self ):
        '''Is there a standard code for this taxon?
        '''
        #-- 1 --
        # [ if self.disamb is true ->
        #     return self.disamb
        #   else ->
        #     return self.canon ]
        return self.disamb or self.canon