
    6Dh4                     V   S SK r 1 Skr\R                  \SS15      r1 Skr\ R                  " SS5      r\ R                  " SS	5      r\ R                  " S
S5      r	S r
                  SS jrS rSS jr SS jrS rS rS r SS jrS r SS jrS rSS jrSS jrS rg)    N>   geomappolarscenemapboxternaryxydomain>   r   r   r   r   	SubplotXYxaxisyaxisSubplotDomainxy
SubplotRefsubplot_typelayout_keystrace_kwargsc                  P    [          V s0 s H  o S_M     nn SUS'   SUS'   U$ s  sn f )Nr   r   r   )_single_subplot_types)r   max_subplot_idss     B/var/www/html/env/lib/python3.13/site-packages/plotly/_subplots.py_get_initial_max_subplot_idsr   #   s:    ;PQ;P<Q;POQ OG OG Rs   #c                   ^ SSK Jn  SU;   nUR                  SU
5      n
UR                  SU	5      n	U(       a#  [        SR	                  [        U5      5      5      e[        U [        5      (       a  U S::  a+  [        SR	                  [        U 5      [        U 5      S95      e[        T[        5      (       a  TS::  a+  [        SR	                  [        T5      [        T5      S95      eUS	:X  a  S
nS
nO6US:X  a  S
nSnO+[        SR	                  [        U5      [        U5      S95      eS nUc8  [        U 5       VVs/ s H  n[        T5       Vs/ s H  n0 PM     snPM!     nnnO[        U[
        [        45      (       a^  U(       aW  [        S U 5       5      (       a@  [        U5      U :X  a1  [        U4S jU 5       5      (       a  [        S U 5       5      (       d-  [        SR	                  U T[        U5      [        U5      S95      eU H3  nU H*  nU(       d  M  UR                  SS5      (       d  M%  SUS'   M,     M5     [        SSS
S
SSSSS9nU" SUU5        SnU HV  nU HM  nUb  U=(       d    US   nU(       d  M  US   S:w  d  M(  US   (       d  M4  [        SR	                  US   S95      e   MX     Ub  USL a  / nO][        U[
        [        45      (       a  [        S U 5       5      (       d+  [        S R	                  [        U5      [        U5      S95      eU(       aH  U H*  nU(       d  M  UR                  SS5      (       d  M%  SUS'   M,     [        S!SSS"SS"S#9nU" S$UU5        / S%Qn S&n!UU ;  a/  Un"[        U!R	                  S'U [        U"5      [        U"5      S(95      eUU ;  a/  Un"[        U!R	                  S)U [        U"5      [        U"5      S(95      eS* n#Uc  U(       a  S+T-  nOS,T-  nU#" TUS-S.S/5        Uc  Ub  S0U -  nOS1U -  nU#" XS2S3S35        Uc	  S4/U -  T-  nU(       a  S5n$OU(       a  S6n$OS7n$U	c  U$UTS
-
  -  -
  T-  /T-  n%O[        U	[
        [        45      (       aO  [        U	5      T:X  a@  [!        [#        U	5      5      n&/ n%U	 H#  n'U%R%                  U$UTS
-
  -  -
  U'U&-  -  5        M%     O,[        S8R	                  T[        U	5      [        U	5      S995      eU
c  S7XpS
-
  -  -
  U -  /U -  n(O[        U
[
        [        45      (       ao  [        U
5      U :X  a`  [!        [#        U
5      5      n&/ n(U
 H"  n)U(R%                  S7XpS
-
  -  -
  U)U&-  -  5        M$     US:  a  U(       d  [        ['        U(5      5      n(O,[        S:R	                  U [        U
5      [        U
5      S;95      eU(       aF  [        U[
        [        45      (       d+  [        S<R	                  [        U5      [        U5      S95      eU(       aF  [        U[
        [        45      (       d+  [        S=R	                  [        U5      [        U5      S95      eUR)                  5       n*[        T5      SSU2   n+[        U 5      SSU2   n,U, VVs/ s H<  nU+ Vs/ s H+  n[#        U%SU 5      UU-  -   [#        U(SU 5      UU-  -   4PM-     snPM>     n-nn[        U 5       V.s/ s H  n.[        T5       V.s/ s H  n.SPM     sn.PM!     n/n.[        U 5       VVs/ s H  n[        T5       Vs/ s H  nSPM     snPM!     n0nn/ n1[+        5       n2[-        U5       GH  u  nn3[-        U35       GH  u  nnUc  M  UUS>   -   S
-
  n4UUS?   -   S
-
  n5U4T:  a  [/        S@5      eU5U :  a  [/        SA5      eU-U   U   S   USB   -   n6U-U   U4   S   U%U4   -   USC   -
  n7U6U7/n8US:  a)  U-U   U   S
   USD   -   n9U-U5   U   S
   U(U5   -   USE   -
  n:O+U-U5   U   S
   USD   -   n9U-U   U   S
   U(SU-
     -   USE   -
  n:U9S:  a  U9SF:  a  Sn9O[/        SG5      eU9S7:  a  U9SH:  a  S7n9O[/        SG5      eU:S:  a  U:SF:  a  Sn:O[/        SI5      eU:S7:  a  U:SH:  a  S7n:O[/        SI5      eU9U:/n;U1R%                  U85        U1R%                  U;5        U8U;/U/U   U'   US   n<US   n=[1        U*U<U=U8U;U25      n>U>U0U   U'   GM     GM     [3        U*U0USJUU5        [3        U*U0USKUU5        U(       a%  [        [        U5      5       Vs/ s H  nSPM     snOSn?U(       Ga.  [-        U5       GH  u  n@nUSL   S   S
-
  nUSL   S
   S
-
  nSUs=::  a  U :  d  O  [/        SM5      eSUs=::  a  T:  d  O  [/        SN5      eU-U   U   S   USB   U%U   -  -   n6USO   S":X  a  U-U   U   S   U%U   -   n7OU6USO   U%U   -  -   n7U6U7/n8U-U   U   S
   USD   U(SU-
     -  -   n9USP   S":X  a  U-U   U   S
   U(SU-
     -   n:OU9USP   U(SU-
     -  -   n:U9U:/n;U1R%                  U85        U1R%                  U;5        US   n<[1        U*U<SU8U;U25      n>U>U?W@'   GM!     [5        UU0UU?U,5      nA[7        UU15      nBUBU*SQ'   U(       a  / nCUS:  a5  [        T5       H%  nU/S   U   nDUD(       d  M  WCR9                  WD5        M'     O4[        T5       H%  nU/S   U   nDUD(       d  M  WCR9                  WD5        M'     [7        UWC5      nEU*SQ==   [        UE5      -  ss'   U(       aW  / nC[        U 5       H%  nU/U   S   nDUD(       d  M  WCR9                  WD5        M'     [7        UWCSRSS9nEU*SQ==   [        UE5      -  ss'   U(       a)  SU$4ST/nC[7        U/UCSUSVSW9nEU*SQ==   [        UE5      -  ss'   U(       a'  STST/nC[7        U/UCSXSYSW9nEU*SQ==   [        UE5      -  ss'   U(       a  [;        WA5        Uc  UR=                  5       nUR?                  U*5        U0UR@                  SZ'   WAUR@                  S['   U$ s  snf s  snnf s  snf s  snnf s  sn.f s  sn.f s  snf s  snnf s  snf )\a|(  
Return an instance of plotly.graph_objs.Figure with predefined subplots
configured in 'layout'.

Parameters
----------
rows: int (default 1)
    Number of rows in the subplot grid. Must be greater than zero.

cols: int (default 1)
    Number of columns in the subplot grid. Must be greater than zero.

shared_xaxes: boolean or str (default False)
    Assign shared (linked) x-axes for 2D cartesian subplots

      - True or 'columns': Share axes among subplots in the same column
      - 'rows': Share axes among subplots in the same row
      - 'all': Share axes across all subplots in the grid.

shared_yaxes: boolean or str (default False)
    Assign shared (linked) y-axes for 2D cartesian subplots

      - 'columns': Share axes among subplots in the same column
      - True or 'rows': Share axes among subplots in the same row
      - 'all': Share axes across all subplots in the grid.

start_cell: 'bottom-left' or 'top-left' (default 'top-left')
    Choose the starting cell in the subplot grid used to set the
    domains_grid of the subplots.

      - 'top-left': Subplots are numbered with (1, 1) in the top
                    left corner
      - 'bottom-left': Subplots are numbererd with (1, 1) in the bottom
                       left corner

print_grid: boolean (default True):
    If True, prints a string representation of the plot grid.  Grid may
    also be printed using the `Figure.print_grid()` method on the
    resulting figure.

horizontal_spacing: float (default 0.2 / cols)
    Space between subplot columns in normalized plot coordinates. Must be
    a float between 0 and 1.

    Applies to all columns (use 'specs' subplot-dependents spacing)

vertical_spacing: float (default 0.3 / rows)
    Space between subplot rows in normalized plot coordinates. Must be
    a float between 0 and 1.

    Applies to all rows (use 'specs' subplot-dependents spacing)

subplot_titles: list of str or None (default None)
    Title of each subplot as a list in row-major ordering.

    Empty strings ("") can be included in the list if no subplot title
    is desired in that space so that the titles are properly indexed.

specs: list of lists of dict or None (default None)
    Per subplot specifications of subplot type, row/column spanning, and
    spacing.

    ex1: specs=[[{}, {}], [{'colspan': 2}, None]]

    ex2: specs=[[{'rowspan': 2}, {}], [None, {}]]

    - Indices of the outer list correspond to subplot grid rows
      starting from the top, if start_cell='top-left',
      or bottom, if start_cell='bottom-left'.
      The number of rows in 'specs' must be equal to 'rows'.

    - Indices of the inner lists correspond to subplot grid columns
      starting from the left. The number of columns in 'specs'
      must be equal to 'cols'.

    - Each item in the 'specs' list corresponds to one subplot
      in a subplot grid. (N.B. The subplot grid has exactly 'rows'
      times 'cols' cells.)

    - Use None for a blank a subplot cell (or to move past a col/row span).

    - Note that specs[0][0] has the specs of the 'start_cell' subplot.

    - Each item in 'specs' is a dictionary.
        The available keys are:
        * type (string, default 'xy'): Subplot type. One of
            - 'xy': 2D Cartesian subplot type for scatter, bar, etc.
            - 'scene': 3D Cartesian subplot for scatter3d, cone, etc.
            - 'polar': Polar subplot for scatterpolar, barpolar, etc.
            - 'ternary': Ternary subplot for scatterternary
            - 'map': Map subplot for scattermap, choroplethmap and densitymap
            - 'mapbox': Mapbox subplot for scattermapbox, choroplethmapbox and densitymapbox
            - 'domain': Subplot type for traces that are individually
                        positioned. pie, parcoords, parcats, etc.
            - trace type: A trace type which will be used to determine
                          the appropriate subplot type for that trace

        * secondary_y (bool, default False): If True, create a secondary
            y-axis positioned on the right side of the subplot. Only valid
            if type='xy'.
        * colspan (int, default 1): number of subplot columns
            for this subplot to span.
        * rowspan (int, default 1): number of subplot rows
            for this subplot to span.
        * l (float, default 0.0): padding left of cell
        * r (float, default 0.0): padding right of cell
        * t (float, default 0.0): padding right of cell
        * b (float, default 0.0): padding bottom of cell

    - Note: Use 'horizontal_spacing' and 'vertical_spacing' to adjust
      the spacing in between the subplots.

insets: list of dict or None (default None):
    Inset specifications.  Insets are subplots that overlay grid subplots

    - Each item in 'insets' is a dictionary.
        The available keys are:

        * cell (tuple, default=(1,1)): (row, col) index of the
            subplot cell to overlay inset axes onto.
        * type (string, default 'xy'): Subplot type
        * l (float, default=0.0): padding left of inset
              in fraction of cell width
        * w (float or 'to_end', default='to_end') inset width
              in fraction of cell width ('to_end': to cell right edge)
        * b (float, default=0.0): padding bottom of inset
              in fraction of cell height
        * h (float or 'to_end', default='to_end') inset height
              in fraction of cell height ('to_end': to cell top edge)

column_widths: list of numbers or None (default None)
    list of length `cols` of the relative widths of each column of subplots.
    Values are normalized internally and used to distribute overall width
    of the figure (excluding padding) among the columns.

    For backward compatibility, may also be specified using the
    `column_width` keyword argument.

row_heights: list of numbers or None (default None)
    list of length `rows` of the relative heights of each row of subplots.
    If start_cell='top-left' then row heights are applied top to bottom.
    Otherwise, if start_cell='bottom-left' then row heights are applied
    bottom to top.

    For backward compatibility, may also be specified using the
    `row_width` kwarg. If specified as `row_width`, then the width values
    are applied from bottom to top regardless of the value of start_cell.
    This matches the legacy behavior of the `row_width` argument.

column_titles: list of str or None (default None)
    list of length `cols` of titles to place above the top subplot in
    each column.

row_titles: list of str or None (default None)
    list of length `rows` of titles to place on the right side of each
    row of subplots. If start_cell='top-left' then row titles are
    applied top to bottom. Otherwise, if start_cell='bottom-left' then
    row titles are applied bottom to top.

x_title: str or None (default None)
    Title to place below the bottom row of subplots,
    centered horizontally

y_title: str or None (default None)
    Title to place to the left of the left column of subplots,
    centered vertically

figure: go.Figure or None (default None)
    If None, a new go.Figure instance will be created and its axes will be
    populated with those corresponding to the requested subplot geometry and
    this new figure will be returned.
    If a go.Figure instance, the axes will be added to the
    layout of this figure and this figure will be returned. If the figure
    already contains axes, they will be overwritten.

Examples
--------

Example 1:

>>> # Stack two subplots vertically, and add a scatter trace to each
>>> from plotly.subplots import make_subplots
>>> import plotly.graph_objects as go
>>> fig = make_subplots(rows=2)

This is the format of your plot grid:
[ (1,1) xaxis1,yaxis1 ]
[ (2,1) xaxis2,yaxis2 ]

>>> fig.add_scatter(y=[2, 1, 3], row=1, col=1) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_scatter(y=[1, 3, 2], row=2, col=1) # doctest: +ELLIPSIS
Figure(...)

or see Figure.append_trace

Example 2:

>>> # Stack a scatter plot
>>> fig = make_subplots(rows=2, shared_xaxes=True)

This is the format of your plot grid:
[ (1,1) xaxis1,yaxis1 ]
[ (2,1) xaxis2,yaxis2 ]

>>> fig.add_scatter(y=[2, 1, 3], row=1, col=1) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_scatter(y=[1, 3, 2], row=2, col=1) # doctest: +ELLIPSIS
Figure(...)

Example 3:

>>> # irregular subplot layout (more examples below under 'specs')
>>> fig = make_subplots(rows=2, cols=2,
...                     specs=[[{}, {}],
...                     [{'colspan': 2}, None]])

This is the format of your plot grid:
[ (1,1) xaxis1,yaxis1 ]  [ (1,2) xaxis2,yaxis2 ]
[ (2,1) xaxis3,yaxis3           -              ]

>>> fig.add_trace(go.Scatter(x=[1,2,3], y=[2,1,2]), row=1, col=1) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_trace(go.Scatter(x=[1,2,3], y=[2,1,2]), row=1, col=2) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_trace(go.Scatter(x=[1,2,3], y=[2,1,2]), row=2, col=1) # doctest: +ELLIPSIS
Figure(...)

Example 4:

>>> # insets
>>> fig = make_subplots(insets=[{'cell': (1,1), 'l': 0.7, 'b': 0.3}])

This is the format of your plot grid:
[ (1,1) xaxis1,yaxis1 ]

With insets:
[ xaxis2,yaxis2 ] over [ (1,1) xaxis1,yaxis1 ]

>>> fig.add_scatter(x=[1,2,3], y=[2,1,1]) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_scatter(x=[1,2,3], y=[2,1,2], xaxis='x2', yaxis='y2') # doctest: +ELLIPSIS
Figure(...)

Example 5:

>>> # include subplot titles
>>> fig = make_subplots(rows=2, subplot_titles=('Plot 1','Plot 2'))

This is the format of your plot grid:
[ (1,1) x1,y1 ]
[ (2,1) x2,y2 ]

>>> fig.add_scatter(x=[1,2,3], y=[2,1,2], row=1, col=1) # doctest: +ELLIPSIS
Figure(...)
>>> fig.add_bar(x=[1,2,3], y=[2,1,2], row=2, col=1) # doctest: +ELLIPSIS
Figure(...)

Example 6:

Subplot with mixed subplot types

>>> fig = make_subplots(rows=2, cols=2,
...                     specs=[[{'type': 'xy'},    {'type': 'polar'}],
...                            [{'type': 'scene'}, {'type': 'ternary'}]])

>>> fig.add_traces(
...     [go.Scatter(y=[2, 3, 1]),
...      go.Scatterpolar(r=[1, 3, 2], theta=[0, 45, 90]),
...      go.Scatter3d(x=[1, 2, 1], y=[2, 3, 1], z=[0, 3, 5]),
...      go.Scatterternary(a=[0.1, 0.2, 0.1],
...                        b=[0.2, 0.3, 0.1],
...                        c=[0.7, 0.5, 0.8])],
...     rows=[1, 1, 2, 2],
...     cols=[1, 2, 1, 2]) # doctest: +ELLIPSIS
Figure(...)
r   N	row_widthcolumn_widthz6make_subplots() got unexpected keyword argument(s): {}zl
The 'rows' argument to make_subplots must be an int greater than 0.
    Received value of type {typ}: {val})typvalzl
The 'cols' argument to make_subplots must be an int greater than 0.
    Received value of type {typ}: {val}zbottom-left   top-leftz~
The 'start_cell` argument to make_subplots must be one of ['bottom-left', 'top-left']
    Received value of type {typ}: {val}c                    ^  U 4S jnU HP  n[        U[        [        45      (       a  U H  nU" XR5        M     M1  [        U[        5      (       d  MH  U" XB5        MR     g )Nc                 j  > U c  g [        U [        5      (       d,  [        SR                  T[	        U 5      [        U 5      S95      eU  H=  nX!;  d  M
  [        SR                  [        U5      T[        [        U5      5      S95      e   UR                  5        H  u  p#U R                  X#5        M     g )Nzy
Elements of the '{name}' argument to make_subplots must be dictionaries or None.
    Received value of type {typ}: {val})namer    r!   zx
Invalid key specified in an element of the '{name}' argument to make_subplots: {k}
    Valid keys include: {valid_keys})kr'   
valid_keys)	
isinstancedict
ValueErrorformattypereprlistitems
setdefault)itemdefaultsr(   vr'   s       r   _checks<make_subplots.<locals>._check_keys_and_fill.<locals>._checks  s    |dD)) + ,26!tDztDz ,2 ,	  $$( )/"1gDT$x.=Q )/ )	   !(% )    )r*   r0   tupler+   )r'   argr4   r6   arg_iarg_iis   `     r   _check_keys_and_fill+make_subplots.<locals>._check_keys_and_fill  sL    	&4 E%$//#FF- $E4((( r8   c              3   N   #    U  H  n[        U[        [        45      v   M     g 7fN)r*   r0   r9   .0rows     r   	<genexpr> make_subplots.<locals>.<genexpr>  s     @%3
3u..%s   #%c              3   @   >#    U  H  n[        U5      T:H  v   M     g 7fr@   len)rB   rC   colss     r   rD   rE     s     2ESCD Es   c              3   F   #    U  H  n[        S  U 5       5      v   M     g7f)c              3   V   #    U  H  oS L =(       d    [        U[        5      v   M!     g 7fr@   r*   r+   rB   r5   s     r   rD   *make_subplots.<locals>.<genexpr>.<genexpr>  s!     BcI4At!44cs   ')N)allrA   s     r   rD   rE     s     TesBcBBBes   !z
The 'specs' argument to make_subplots must be a 2D list of dictionaries with dimensions ({rows} x {cols}).
    Received value of type {typ}: {val})rowsrI   r    r!   is_3dr   r.   r	   F        )r.   secondary_ycolspanrowspanlrbtspecsrS   z
The 'secondary_y' spec property is not supported for subplot of type '{s_typ}'
     'secondary_y' is only supported for subplots of type 'xy'
)s_typc              3   B   #    U  H  n[        U[        5      v   M     g 7fr@   rL   rM   s     r   rD   rE     s     1Vv!*Q2E2Evs   zo
The 'insets' argument to make_subplots must be a list of dictionaries.
    Received value of type {typ}: {val})r"   r"   to_end)cellr.   rV   wrX   hinsets)NTFrP   columnsrO   zi
The {arg} argument to make_subplots must be one of: {valid_vals}
    Received value of type {typ}: {val}shared_xaxes)r:   
valid_valsr    r!   shared_yaxesc           
          US:  d  US:  a  [        U< S35      eU S::  a  g S[        U S-
  5      -  nX:  a  [        SR                  UUUUU S95      eg )Nr   r"   z! spacing must be between 0 and 1.      ?z{name} spacing cannot be greater than (1 / ({dimvarname} - 1)) = {max_spacing:f}.
The resulting plot would have {dimsize} {dimname} ({dimvarname}={dimsize}).)
dimvarnamer'   dimnamemax_spacingdimsize)r,   floatr-   )rk   spacingr'   rh   ri   rj   s         r   _check_hv_spacing(make_subplots.<locals>._check_hv_spacing  sy    Q;'A+dLMMa<E'A+.. OOUv)# +# PV P	 	 !r8   g?g?
HorizontalrI   rb   g      ?g333333?VerticalrP    gGz?g\(\?rg   z
The 'column_widths' argument to make_subplots must be a list of numbers of length {cols}.
    Received value of type {typ}: {val}rI   r    r!   z
The 'row_heights' argument to make_subplots must be a list of numbers of length {rows}.
    Received value of type {typ}: {val}rP   r    r!   zl
The column_titles argument to make_subplots must be a list or tuple
    Received value of type {typ}: {val}zi
The row_titles argument to make_subplots must be a list or tuple
    Received value of type {typ}: {val}rT   rU   z8Some 'colspan' value is too large for this subplot grid.z8Some 'rowspan' value is too large for this subplot grid.rV   rW   rX   rY   g{GzzaA combination of the 'b' values, heights, and number of subplots too large for this subplot grid.g)\(?zaA combination of the 't' values, heights, and number of subplots too large for this subplot grid.r   r   r^   zHSome 'cell' row value is out of range. Note: the starting cell is (1, 1)zHSome 'cell' col value is out of range. Note: the starting cell is (1, 1)r_   r`   annotationsright)
title_edge)r   r"   bottom   )rw   offsetleft(   	_grid_ref	_grid_str)!plotly.graph_objs
graph_objspop	TypeErrorr-   r0   r*   intr,   r.   r/   ranger9   rO   rH   r+   rl   sumappendreversedLayoutr   	enumerate	Exception_init_subplot_configure_shared_axes_build_grid_str _build_subplot_title_annotationsextendprintFigureupdate_layout__dict__)FrP   rI   rc   re   
start_cell
print_gridhorizontal_spacingvertical_spacingsubplot_titlescolumn_widthsrow_heightsrZ   ra   column_titles
row_titlesx_titley_titlefigurekwargsgouse_legacy_row_heights_ordercol_dirrow_dirr=   rW   crC   specspec_defaultshas_secondary_yinsetinset_defaultsvalid_shared_valsshared_err_msgr!   rn   	max_widthwidthscum_sumr_   heightsr`   layoutcol_seqrow_seqgrid_domains_gridgrid_reflist_of_domainsr   spec_row	c_spanned	r_spannedx_sx_ex_domainy_sy_ey_domainr   rS   subplot_refs
insets_refi_insetgrid_strplot_title_annotationsdomains_listdomain_paircolumn_title_annotationssF    `                                                                    r   make_subplotsr   *   sr   V	 # $/&#8 **[+6KJJ~}=MDKKV
 	
 dC  DAI++16JDJ ,2 ,
 	
 dC  DAI++16JDJ ,2 ,
 	
 ]"	z	!+ ,26$$z*: ,2 ,	
 	
")J }49$K@KqeDk*k"k*K@54-((@%@@@J$2E222TeTTT+ ,26$u+4; ,2 ,	
 	
 D t$//&V	   uacSCSVM %7 OD"1"HT-5HtV,m1D1D  F"6l  	 	   ~56D%=))c1Vv1V.V.V++16Ld6l ,2 ,
 	
 Eu7D11 'f  dcX
 	Xv~> F+N ,,!!",II	 " 
 	
 ,,!!",II	 " 
 	
& !!$t!$td.fiP %"Tz"Tzdj&&I t+ 				1TAX>>$FG$N	MD%=	1	1c-6HD6PM*+AMM9'9TAX'FF1w;WX  + ,26tM2]8K ,2 ,	
 	
 *Qh774?@4G	K$	/	/C4D4LK()ANNC"2Qh"??AKPQ Q;;8G,-G+ ,26tK0d;6G ,2 ,	
 	
 Ze}EE++16'T--@ ,2 ,
 	
 *Z$??++16$$z*: ,2 ,
 	
 YY[F
 Dk)G)$GDk)G)$G 	 A 	

  VBQZ1'9#99WRa[!A(8$88 	
  	 	 :?tEA5;/;aT;/LE 6;4[A[uT{+{!{+[HAO24O !'8 *GAt| DO+a/IDO+a/I D Q  D Q 
 q'!*Q-$s)+Cq')$Q'&*;;d3iGCSzH {1gajmd3i/9oa(+gi.@@49L9oa(+d3i71gajmgb1fo5S	ASy ;C#N  Sy :C#N 
 Sy;C#N 
 Sy:C#N 
 SzH""8,""8,"*H!5LOA  <L}-K(k8XL *HQKNi + (n 68UCwO68UCwO
 <BE#f+$67$65$$67tJ'/NGUfa 1$Afa 1$A MTM8  MTM8  q'!*Q-%*vay"88CSzX%1gajmfQi/E#J22SzH q'!*Q-%*wrAv">>CSzX%1gajmgb1fo5E#Ja88SzH""8,""8, =L(eXxL #/JwS 0Z uh
GLH > 3F= Q;4[*2.q1; ''4 !
 4[*1oa0; ''4 ! $D<$
  	}'?!@@tA&q/"-K{##K0  $D$
  	}'?!@@I/ $DI|$
  	}'?!@@' $DI|r$
  	}'?!@@ h ~
  $,FOOK #+FOOK MK +@p	
	 0E ,AH 8sf   <qqq
q2q
q!q"4q
 q"q,*q'6q,4q2qqq"'q,c                   ^ ^^ [        U5      n[        US   5      nSS/R                  T5      mUS:  a  [        US-
  SS5      nO[        U5      nU UU4S jn	US:X  d  TS:X  aP  USL aK  [        U5       H;  n
S nTS:H  nU H+  nX   U
   (       d  M  X   U
   S   nX-   U
   nU	" XX5      nM-     M=     g US	:X  d  TS:X  aP  USL aK  U HD  nS nTS:H  n[        U5       H+  n
X   U
   (       d  M  X   U
   S   nX-   U
   nU	" XX5      nM-     MF     g US
:X  ap  S n[        U5       H^  n
[        U5       HL  u  nnX   U
   (       d  M  X   U
   S   nX-   U
   nTS:X  a  U
S:  nOUS:  a  US:  OXS-
  :  nU	" XX5      nMN     M`     g g )Nr   r   r   r"   r$   c                    > Uc  U $ T
S:X  a  US   nOUS   nUR                   S:X  aT  US:X  aN  U c#  UR                  T	   nUR                  SS5      n U $ UR                  T	   nTU   nXl        U(       a  SUl        U $ )	Nr   rT   rU   r	   r"   axisrr   F)r   r   replacematchesshowticklabels)first_axis_idsubplot_refr   remove_labelspanfirst_axis_name	axis_nameaxis_to_matchr   layout_key_indx_or_ys           r   update_axis_matches3_configure_shared_axes.<locals>.update_axis_matches  s      S=	?D	?D##t+	$"-"9"9."I / 7 7 C  (33NC	 &y 1(5%38M0r8   rb   TrP   rO   )rH   indexr   r   )r   r   rZ   r   sharedr   rP   rI   	rows_iterr   r   r   ok_to_remove_labelrW   r   r   rir   s   `  `             @r   r   r   z  s   x=Dx{D3Z%%f-N{$(B+	$K	, v}4tA M!'3{1~&k!nQ/x{ 3!!   
6	fm$A M!'34[{1~&k!nQ/x{ 3!! !  
5tA"9-A{1~&k!nQ/x{S=)*Q&3:Q;aAqL& 3!! .  
r8   c           	         Uc
  [        5       nUS   S-   nUS   S-   nSR                  US:  a  UOSS9nSR                  US:  a  UOSS9nXpSR                  US:  a  UOSS9nS	R                  US:  a  UOSS9nX)S
.nX:S
.nXU'   XU'   [        SX4XxS.S9/nU(       aT  US-  nS	R                  US:  a  UOSS9nSR                  US9nUR                  [        SUU4UUS.S95        XSS.nUU U'   XTS'   XdS'   [	        U5      $ )Nr   r"   r   zx{cnt}rr   )cntzy{cnt}z
xaxis{cnt}z
yaxis{cnt})r
   anchorr	   r   r   rv   )r   
overlayingside)r   r-   r   r   r9   )r   rS   r   r   r   x_cnty_cntx_labely_labelx_anchory_anchor
xaxis_name
yaxis_namex_axisy_axisr   secondary_yaxis_namesecondary_y_labelsecondary_y_axiss                      r   _init_subplot_xyr     s~   68 G$q(EG$q(E oo519%"o=Goo519%"o=G !h $$%!)$DJ$$%!)$DJ 5F 5F:: 	#0#*=	
L 
+22	ur2R$OOO6 	!')=>'.9JK	
 '/wW'7#$  %G$Gr8   c                     Uc
  [        5       nXA   S-   nSR                  XS:  a  UOSS9n[        X#S.S9nXpU'   U[        ;   a  SOUn[	        X4X0S9n	XTU'   U	4$ )	Nr"   z{subplot_type}{cnt}rr   )r   r   r   )r
   subplotr   )r   r-   r+   _subplot_prop_named_subplotr   )
r   r   r   r   r   r   labelr   	trace_keyr   s
             r   _init_subplot_singler     s     68 
'!
+C!((!Ags2 ) E h67E5M "%@@	l  !xyFXK
 %(L!>r8   c           	      L    [        SSS[        U 5      [        U5      S.0S9nU4$ )Nr
    r   r   )r   r9   )r   r   r   s      r   _init_subplot_domainr     s1    eHoE(O LMK >r8   c                    SSK Jn  U" 5       nXR                  ;   aU  UR                  SU 0/5      S   nSU;   a  gSU;   a  SU;   a  gSU;   a  gS	U;   a  g	S
U;   a  [         H  n XCl        Us  $    g ! [         a     M  f = f)Nr   )DataValidatorr.   r
   r   r   r	   r   r   r   )plotly.validatorsr   class_strs_mapvalidate_coercer   r   r,   )
trace_typer   trace_validatortracerY   s        r   _subplot_type_for_trace_typer  (  s    /#oO333//&*1E0FGJu'U"2e^%0$%MH 1  " s   &A33
B Bc                     U nU R                  5       n U [        ;   a  U $ [        U 5      n U c#  [        SR	                  [        U5      5      5      eU $ )NUnsupported subplot type: {})lower_subplot_typesr  r,   r-   r/   )r   orig_subplot_types     r   _validate_coerce_subplot_typer  B  s[    $%%'L ~% 0=L7>>tDU?VWXXr8   c                 r   [        U5      nUc
  [        5       n[        SUS   5      [        SUS   5      /n[        SUS   5      [        SUS   5      /nUS:X  a  [	        XX4U5      nU$ U[
        ;   a  [        XX4U5      nU$ US:X  a  [        X45      nU$ [        SR                  [        U5      5      5      e)NrR   r   rg   r"   r	   r
   r  )r  r   maxminr   r   r   r   r,   r-   r/   )r   r   rS   r   r   r   r   s          r   r   r   T  s     1>L68
 C!%s3'<=HC!%s3'<=Ht'_
  
.	.+(o
  
	!+H?  7>>tL?QRSSr8   c                 $    SR                  XS9nU$ )Nz{x_or_y}{cnt})r   r   )r-   )r   rW   r   r   r   s        r   _get_cartesian_labelr  s  s    ""&":ELr8   c                    US S S2   nUSS S2   n/ n/ nUS:X  aO  SnSn	Sn
U H   nUR                  [        U5      S-  5        M"     U H  nUR                  US   5        M     UnSnGOUS:X  aO  SnSn	Sn
U H   nUR                  [        U5      S-  5        M"     U H  nUR                  US   5        M     U* nSnOUS:X  aN  S	nS
n	Sn
U H  nUR                  US   5        M     U H   nUR                  [        U5      S-  5        M"     SnUnOmUS
:X  aO  SnSn	Sn
U H  nUR                  US   5        M     U H   nUR                  [        U5      S-  5        M"     SnU* nO[        SR                  US95      e/ n[	        [        U 5      5       Hl  nU U   (       a  U[        U5      :  a  M  UU   SUU   SU U   S[        SS9U	U
S.	nUS:w  a  UUS'   US:w  a  UUS'   US:w  a  UUS'   UR                  U5        Mn     U$ )N   r"   topr   centerrx   g       @rv   Z   r{   middleiz Invalid annotation edge '{edge}')edgepaperF   )size)	r   xrefr   yreftext	showarrowfontxanchoryanchorxshiftyshift	textangle)r   r   r,   r-   r   rH   r+   )r   r   rw   rz   x_domy_domsubtitle_pos_xsubtitle_pos_y
text_angler   r!  	x_domains	y_domainsr#  r"  plot_titlesr   annots                     r   r   r   y  sz    CaC EADqD!ENNU
I!!#i.3"67 I!!)A,/  	x	
I!!#i.3"67 I!!)A,/  	w	
I!!)A,/ I!!#i.3"67  	v	
I!!)A,/ I!!#i.3"67  ;BB
BSTTKs>*+e$^1D(D $E*#E*&u-""""
E {"(h{"(hQ%/k"u%3 ,4 r8   c                 "   [        U 5      n[        U S   5      nSnSnSn	Sn
SnSnSnS	nS
nSnSnSnSn[        U5       VVs/ s H  n[        U5       Vs/ s H  nSPM     snPM!     nnnS n[        [        U5       VVVVs/ s H8  u  nn[        U5        H"  u  nnU(       d  M  [        U" UUU5      5      PM$     M:     snnnn5      [        U5      -   [        U	5      -   nU4S jn[        U 5       GH  u  nn[        U5       GH  u  nnUU   U   nUc  UU   U   S:X  a  UU" U5      -   UU   U'   M1  US   S:  a  U
U" UUU5      -   nOUU" UUU5      -   nUS   S:  ax  [        SUS   S-
  5       H  nUU" U5      -   UU   UU-   '   M     US   S:  a!  UU" UU	-   5      -   U-   UU   UUS   -   S-
  '   OOUU" UU	-   5      -   U	-   UU   UUS   -   S-
  '   O.SU[        U5      -
  S-
  -  n US   S:  a	  UU U-   -  nOUU U	-   -  nUS   S:  a  [        US   5       H~  n[        SUS   5       Hh  n!UU" U5      -   n"US:X  a  U!US   S-
  :  a	  UU"SS  -   n"OUU"SS  -   n"UUS   S-
  :X  a  U!US   S-
  :  a	  U"S S U-   n"OU"S S U-   n"U"UUU!-      UU-   '   Mj     M     UU" U5      -   UU   U'   GM     GM     US S S2    H  nUUR	                  UU   5      S-   -  nM     U(       a  US-  n[        U5       Hy  u  n#n$U$S   S   S-
  nU$S   S   S-
  nUU   U   nSR	                  UU#   S   R
                  5      n%U%R                  SS5      n%UUU%-   U	-   S-   U-   U" UUU5      -   U	-   S-   -  nM{     U$ s  snf s  snnf s  snnnnf )Nr   z  z[ z ]u   ⎡ u   ⎢ u   ⎣ u    ⎤u    ⎟u    ⎦z       -z       :z    (empty) z&This is the format of your plot grid:
rr   c                     [        U VVs1 s H  o3R                    H  oDiM     M     snn5      nSR                  U5      nUR                  SS5      nSR	                  U S-   US-   US9$ s  snnf )N,r   rr   z({r},{c}) {ref}r"   )rW   r   ref)sortedr   joinr   r-   )rW   r   r   r1  r(   r   ref_strs          r   _get_cell_str&_build_grid_str.<locals>._get_cell_str  sk    <Q<CAaa<QR((;' //&"- ''!a%1q5g'FF Rs   A+
c                 $    SU[        U 5      -
  -  $ )N rG   )scell_lens     r   _pad_build_grid_str.<locals>._pad  s    hQ'((r8   rU   r"   rT   r8  r  r$   
z
With insets:
r^   r0  r   z over )rH   r   r  r   r3  r   r   )&rZ   r   ra   r   r   rP   rI   sps_stre_strs_tops_mids_bote_tope_mide_botcolspan_strrowspan_str	empty_strr   rW   r   _tmpr5  row_refr1  r:  r;  r   r   cell_strccpaddingrrrow_strr   r   subplot_labels_strs&                                         r   r   r     s   u:DuQx=D 
BEEEEEEEEKKI8H 05T{;{!t%AR%{D;G 	 #,H"5"5JAw'0FAs .M!Q,-0 ."5	
 e*	 e*		  " ) !'8 *GAt1+a.C{71:#!*T)_!<DGAJI" =As#;; =As#;;I"4	?Q#67B&1D4E&EDGAFO 8 	?Q&#d;+>&??8DGAY/!34
 $d;+>&??8DGAY/!34 CM!9A!=>	?Q&%/H%/HI"Y0B#AtI7"-[0A"A7!DOa$77*/'!"+*=*/'!"+*=i1!44!DOa$77*1#2,*>*1#2,*>/6QVQV, 8 1" "DN2DGAJc + (j TrT]BGGDG$t++  &&'/NGUfa 1$Afa 1$A1+a.C!$*W*=a*@*L*L!M "4!;!;FB!G$%  	
  1c*+  	H 0( O[ &;s$   NM>!N N	'N	>Nc           
         US::  a  [        S5      eUS::  a  [        S5      e X#S-
     US-
     nU(       d  [        SR                  X4S95      eU(       a*  [	        U5      S:  a  [        S	5      eUS   R
                  nOUS   R
                  nU H:  nX;  d  M
  [        S
R                  U R                  US   R                  UUS95      e   U R                  U5        g ! [         a    [        S5      ef = f)Nr   z<Row value is out of range. Note: the starting cell is (1, 1)z<Col value is out of range. Note: the starting cell is (1, 1)r"   zZThe (row, col) pair sent is out of range. Use Figure.print_grid to view the subplot grid. z5
No subplot specified at grid position ({row}, {col}))rC   colr  z
Subplot with type '{subplot_type}' at grid position ({row}, {col}) was not
created with the secondary_y spec property set to True. See the docstring
for the specs argument to plotly.subplots.make_subplots for more information.
zTrace type '{typ}' is not compatible with subplot type '{subplot_type}'
at grid position ({row}, {col})

See the docstring for the specs argument to plotly.subplots.make_subplots
for more information on subplot types)r    r   rC   rT  )	r   
IndexErrorr,   r-   rH   r   r.   r   update)	r  r   r   rC   rT  rS   r   r   r(   s	            r   _set_trace_grid_referencerW  ^  s7   
axM
 	
 axM
 	

a(q1 88> 9? 9
 	
 |q   $A33#A33>)
 *0

!-a!=!=	 *0 *  " 
LL[  

 	

s   C" "C8c           	          U R                   n[        U5      n[        US   5      n[	        U[
        5      (       a  US:  d  XQ:  a,  [        SR                  U[        U5      [        U5      S95      e[	        U[
        5      (       a  US:  d  Xb:  a,  [        SR                  U[        U5      [        U5      S95      eU R                   US-
     US-
     nU(       d  g U(       a   [        U5      S:  a  US   R                  nOg US   R                  n[        U5      S:X  a  [        S0 US   R                  S   D6$ [        U5      S:X  a  U R                  US      $ [        U5      S	:X  a*  [        U R                  US      U R                  US      S
9$ [        SR                  U5      5      e! [         a    [        S5      ef = f)NzIn order to reference traces by row and column, you must first use plotly.tools.make_subplots to create the figure with a subplot grid.r   r"   zt
The row argument to get_subplot must be an integer where 1 <= row <= {rows}
    Received value of type {typ}: {val}rt   zt
The col argument to get_subplot must be an integer where 1 <= row <= {cols}
    Received value of type {typ}: {val}rs   r
   r  r   z/
Unexpected subplot type with layout_keys of {}r   )r}   AttributeErrorr   rH   r*   r   r,   r-   r.   r/   r   r   r   r   r   )	figrC   rT  rS   r   rP   rI   r   r   s	            r   _get_grid_subplotr[    s   
== x=Dx{D c337dj++16tCyd3i ,2 ,
 	
 c337dj++16tCyd3i ,2 ,
 	
 ==q)#'2L|q &q/55K"1o11
;1F|A;;HEFF	[	Q	zz+a.))	[	Q	**[^,CJJ{1~4N
 	
 228&3
 	
g  
8
 	

s   F3 3G	c                    SU ;   a8  [        SSSU R                  R                  U R                  R                  S.0S9$ SU ;   as  SU ;   am  U R                  (       a  SU R                  SS  -   OSnU R
                  (       a  SU R
                  SS  -   OSn[        SX4U R                  U R
                  S	.S9$ S
U ;   a"  [        S
U R                  4S
U R                  0S9$ SU ;   a"  [        SU R                  4SU R                  0S9$ SU ;   aR  [         HH  n U R                  S5      nUR                  U5        [        UU R                  4SU R                  0S9s  $    g ! [         a     MZ  f = f)Nr
   r   r   r   r   r   r"   r	   r   r   r   r   )r   r
   r   r   r   r   r   r   r   _get_prop_validatorr  r   r,   )r  r   r   rY   	validators        r   _get_subplot_ref_for_tracer_    s|   5!"%,,..u||~~$NO
 	
 
E	g.27++Wu{{12.7
27++Wu{{12.7
#0#(;;E
 	

 
%+
 	

 
E	 !5;;/
 	

 
e	,A	!55i@	))!,!!"!& 0"+U]]!; 	 -   s   AE!!
E/.E/)r"   r"   FFr#   FNNNNNNNNNNNNr@   )r  r   )F)collectionsr   setunionr	  r   
namedtupler   r   r   r   r   r   r   r   r   r  r  r   r  r   r   rW  r[  r_  r   r8   r   <module>rd     s   M 042BC D  "";0BC	&&
C##A

 
	

%M`K\6t ?C84& LP> ?@YxFR8v;
|*r8   