class_docstr: Pygments Lexer for IDL (Interactive Data Language).
  
  .. versionadded:: 1.6
class_docstr_tok: ["Pygments","Lexer","for","IDL","(","Interactive","Data","Language",")",".","..","versionadded",":",":","1.6"]
docstr: endelse seems to be unique to IDL, endswitch is rare at least.
docstr_tok: ["endelse","seems","to","be","unique","to","IDL",",","endswitch","is","rare","at","least","."]
code: def analyse_text(text):
      """endelse seems to be unique to IDL, endswitch is rare at least."""
      result = 0
  
      if "endelse" in text:
          result += 0.2
      if "endswitch" in text:
          result += 0.01
  
      return result
  
imports: import re
  from pygments.lexer import RegexLexer, words, bygroups
  from pygments.token import Text, Comment, Operator, Keyword, Name, Number, String, Whitespace
label_desc: Use image node_id 1 for calling the IDLLexer obj's underlying member method code with example usage: obj.analyse_text(text) and returns: result