JL igdZddZedk(r;ddlmZddlmZgdZeejdeejyy) z. A utility for displaying lexical dispersion. c F ddlm}tt |Dcic]\}}|r|j n||}}}gg} } t|D]O\} } |r| j n| } |j | }|.| j| | j|Q|ddd}|j\} }|j| | ddt|dz c|j_ |j_ |jd|jt!t#t||d |j%dt||j'||j)d |S#t$r}td|d}~wwxYwcc}}w) a Generate a lexical dispersion plot. :param text: The source text :type text: list(str) or iter(str) :param words: The target words :type words: list of str :param ignore_case: flag to set if case should be ignored when searching text :type ignore_case: bool :return: a matplotlib Axes object that may still be modified before plotting :rtype: Axes NzRThe plot function requires matplotlib to be installed. See https://matplotlib.org/|x)axisC0)colorz Word Offset)matplotlib.pyplotpyplot ImportError enumeratereversedcasefoldgetappendsubplotsplotlendataLimx0x1 autoscale set_ytickslistrangeset_ylim set_title set_xlabel)textwords ignore_casetitleplteywordword2yxsysrtoken_axs Z/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/nltk/draw/dispersion.pydispersion_plotr/ sz'!%1 At' D!3FBdO5$/ U JJu  = IIaL IIaL  $B$KE CLLNEArGGBC#$c$i!m BJJM2::=LLcLMM$uSZ()5M=KKCJLLMM- I9  *   sFF F FF__main__rN) gutenberg)ElinorMarianneEdward Willoughbyzausten-sense.txt)FzLexical Dispersion Plot) __doc__r/__name__r r r$ nltk.corpusr1r!showr.r<sK ,^ z#% :EOIOO$67? CHHJr;