
    A>ij                    l   S SK Jr  S SKJrJr  S SKrS SKJr  S SKJ	r	  S SK
Jr  S SKJr  S SKJr  \	(       a  S S	KJrJrJrJr  S S
KJrJr  S SKJrJrJr  \" S5      r\" S5      r\" S5      r\" S5      r SS\ \\\SS.r!S4S jr"S5S jr# S6   S7S jjr$ " S S\5      r% " S S\%5      r& " S S\%5      r' " S S5      r( " S S \(5      r) " S! S"\(5      r* " S# S$\5      r+ " S% S&\+5      r, " S' S(\,5      r- " S) S*\+5      r. " S+ S,\,\.5      r/ " S- S.\+5      r0 " S/ S0\05      r1 " S1 S2\0\.5      r2S8S3 jr3g)9    )annotations)ABCabstractmethodN)dedent)TYPE_CHECKING
get_option)format)pprint_thing)IterableIteratorMappingSequence)DtypeWriteBuffer)	DataFrameIndexSeriesaR      show_counts : bool, optional
        Whether to show the non-null counts. By default, this is shown
        only if the DataFrame is smaller than
        ``pandas.options.display.max_info_rows`` and
        ``pandas.options.display.max_info_columns``. A value of True always
        shows the counts, and False never shows the counts.a      >>> int_values = [1, 2, 3, 4, 5]
    >>> text_values = ['alpha', 'beta', 'gamma', 'delta', 'epsilon']
    >>> s = pd.Series(text_values, index=int_values)
    >>> s.info()
    <class 'pandas.Series'>
    Index: 5 entries, 1 to 5
    Series name: None
    Non-Null Count  Dtype
    --------------  -----
    5 non-null      object
    dtypes: object(1)
    memory usage: 80.0+ bytes

    Prints a summary excluding information about its values:

    >>> s.info(verbose=False)
    <class 'pandas.Series'>
    Index: 5 entries, 1 to 5
    dtypes: object(1)
    memory usage: 80.0+ bytes

    Pipe output of Series.info to buffer instead of sys.stdout, get
    buffer content and writes to a text file:

    >>> import io
    >>> buffer = io.StringIO()
    >>> s.info(buf=buffer)
    >>> s = buffer.getvalue()
    >>> with open("df_info.txt", "w",
    ...           encoding="utf-8") as f:  # doctest: +SKIP
    ...     f.write(s)
    260

    The `memory_usage` parameter allows deep introspection mode, specially
    useful for big Series and fine-tune memory optimization:

    >>> random_strings_array = np.random.choice(['a', 'b', 'c'], 10 ** 6)
    >>> s = pd.Series(np.random.choice(['a', 'b', 'c'], 10 ** 6))
    >>> s.info()
    <class 'pandas.Series'>
    RangeIndex: 1000000 entries, 0 to 999999
    Series name: None
    Non-Null Count    Dtype
    --------------    -----
    1000000 non-null  object
    dtypes: object(1)
    memory usage: 7.6+ MB

    >>> s.info(memory_usage='deep')
    <class 'pandas.Series'>
    RangeIndex: 1000000 entries, 0 to 999999
    Series name: None
    Non-Null Count    Dtype
    --------------    -----
    1000000 non-null  object
    dtypes: object(1)
    memory usage: 55.3 MBzp    Series.describe: Generate descriptive statistics of Series.
    Series.memory_usage: Memory usage of Series.z_    max_cols : int, optional
        Unused, exists only for compatibility with DataFrame.info.r    z
.. versionadded:: 1.4.0
)klasstype_submax_cols_subshow_counts_subexamples_subsee_also_subversion_added_subc                <    [        U 5      SU R                  U5      $ )as  
Make string of specified length, padding to the right if necessary.

Parameters
----------
s : Union[str, Dtype]
    String to be formatted.
space : int
    Length to force string to be of.

Returns
-------
str
    String coerced to given length.

Examples
--------
>>> pd.io.formats.info._put_str("panda", 6)
'panda '
>>> pd.io.formats.info._put_str("panda", 4)
'pand'
N)strljust)sspaces     U/var/www/html/land-tabula/venv/lib/python3.13/site-packages/pandas/io/formats/info.py_put_strr#      s    . q6&5>&&    c                R    S H  nU S:  a  U S U SU 3s  $ U S-  n M     U S U S3$ )a3  
Return size in human readable format.

Parameters
----------
num : int
    Size in bytes.
size_qualifier : str
    Either empty, or '+' (if lower bound).

Returns
-------
str
    Size in human readable format.

Examples
--------
>>> _sizeof_fmt(23028, "")
'22.5 KB'

>>> _sizeof_fmt(23028, "+")
'22.5+ KB'
)bytesKBMBGBTBg      @z3.1f z PB )numsize_qualifierxs      r"   _sizeof_fmtr0      sL    0 /<$Z/q44v / $Z's++r$   c                "    U c  [        S5      n U $ )z5Get memory usage based on inputs and display options.zdisplay.memory_usager   )memory_usages    r"   _initialize_memory_usager3      s     !"89r$   c                      \ rS rSr% SrS\S'   S\S'   \\SS j5       5       r\\SS j5       5       r	\\SS	 j5       5       r
\\SS
 j5       5       r\SS j5       r\SS j5       r\          SS j5       rSrg)	_BaseInfo   aB  
Base class for DataFrameInfo and SeriesInfo.

Parameters
----------
data : DataFrame or Series
    Either dataframe or series.
memory_usage : bool or str, optional
    If "deep", introspect the data deeply by interrogating object dtypes
    for system-level memory consumption, and include it in the returned
    values.
DataFrame | Seriesdata
bool | strr2   c                    g)zq
Dtypes.

Returns
-------
dtypes : sequence
    Dtype of each of the DataFrame's columns (or one series column).
Nr,   selfs    r"   dtypes_BaseInfo.dtypes       r$   c                    g)!Mapping dtype - number of counts.Nr,   r;   s    r"   dtype_counts_BaseInfo.dtype_counts   r?   r$   c                    g)BSequence of non-null counts for all columns or column (if series).Nr,   r;   s    r"   non_null_counts_BaseInfo.non_null_counts   r?   r$   c                    g)zl
Memory usage in bytes.

Returns
-------
memory_usage_bytes : int
    Object's total memory usage in bytes.
Nr,   r;   s    r"   memory_usage_bytes_BaseInfo.memory_usage_bytes   r?   r$   c                H    [        U R                  U R                  5       S3$ )z0Memory usage in a form of human readable string.
)r0   rI   r.   r;   s    r"   memory_usage_string_BaseInfo.memory_usage_string   s%     d55t7J7JKLBOOr$   c                    SnU R                   (       aG  U R                   S:w  a7  SU R                  ;   d%  U R                  R                  R                  (       a  SnU$ )Nr   deepobject+)r2   rB   r8   index_is_memory_usage_qualified)r<   r.   s     r"   r.   _BaseInfo.size_qualifier   sJ      F*
  1 11yyAA%(Nr$   c                   g Nr,   )r<   bufmax_colsverboseshow_countss        r"   render_BaseInfo.render  s     	r$   r,   NreturnzIterable[Dtype]r_   Mapping[str, int]r_   zlist[int] | Seriesr_   intr_   r   
rX   WriteBuffer[str] | NonerY   
int | NonerZ   bool | Noner[   ri   r_   None)__name__
__module____qualname____firstlineno____doc____annotations__propertyr   r=   rB   rF   rI   rM   r.   r\   __static_attributes__r,   r$   r"   r5   r5      s        0  0 Q  Q    P P    % 	
  ! 
 r$   r5   c                      \ rS rSrSr S     SS jjr\SS j5       r\SS j5       r\SS j5       r	\SS j5       r
\SS	 j5       r\SS
 j5       r          SS jrSrg)DataFrameInfoi  z(
Class storing dataframe-specific info.
Nc                0    Xl         [        U5      U l        g rW   r8   r3   r2   r<   r8   r2   s      r"   __init__DataFrameInfo.__init__  s    
  $	4\Br$   c                ,    [        U R                  5      $ rW   )_get_dataframe_dtype_countsr8   r;   s    r"   rB   DataFrameInfo.dtype_counts$  s    *49955r$   c                .    U R                   R                  $ )zO
Dtypes.

Returns
-------
dtypes
    Dtype of each of the DataFrame's columns.
r8   r=   r;   s    r"   r=   DataFrameInfo.dtypes(  s     yyr$   c                .    U R                   R                  $ )zJ
Column names.

Returns
-------
ids : Index
    DataFrame's column names.
)r8   columnsr;   s    r"   idsDataFrameInfo.ids4  s     yy   r$   c                ,    [        U R                  5      $ z#Number of columns to be summarized.)lenr   r;   s    r"   	col_countDataFrameInfo.col_count@  s     488}r$   c                6    U R                   R                  5       $ )rE   r8   countr;   s    r"   rF   DataFrameInfo.non_null_countsE  s     yy  r$   c                p    U R                   S:H  nU R                  R                  SUS9R                  5       $ )NrP   TrS   rP   )r2   r8   sumr<   rP   s     r"   rI    DataFrameInfo.memory_usage_bytesJ  s5      F*yy%%Dt%<@@BBr$   c               >    [        U UUUS9nUR                  U5        g )N)inforY   rZ   r[   )_DataFrameInfoPrinter	to_bufferr<   rX   rY   rZ   r[   printers         r"   r\   DataFrameInfo.renderO  s*     (#	
 	#r$   r8   r2   rW   )r8   r   r2   bool | str | Noner_   rj   r`   r^   r_   r   rc   r_   r   rf   )rk   rl   rm   rn   ro   rx   rq   rB   r=   r   r   rF   rI   r\   rr   r,   r$   r"   rt   rt     s     +/CC (C 
	C 6 6 	  	  	! 	!   ! ! C C % 	
  ! 
r$   rt   c                      \ rS rSrSr S     SS jjrSSSSS.         SS jjr\SS j5       r\SS j5       r	\SS	 j5       r
\SS
 j5       rSrg)
SeriesInfoi`  z%
Class storing series-specific info.
Nc                0    Xl         [        U5      U l        g rW   rv   rw   s      r"   rx   SeriesInfo.__init__e  s    
 !	4\Br$   )rX   rY   rZ   r[   c               X    Ub  [        S5      e[        U UUS9nUR                  U5        g )NzIArgument `max_cols` can only be passed in DataFrame.info, not Series.info)r   rZ   r[   )
ValueError_SeriesInfoPrinterr   r   s         r"   r\   SeriesInfo.renderm  sA     5  %#

 	#r$   c                8    U R                   R                  5       /$ rW   r   r;   s    r"   rF   SeriesInfo.non_null_counts  s    		!""r$   c                0    U R                   R                  /$ rW   r~   r;   s    r"   r=   SeriesInfo.dtypes  s    		  !!r$   c                D    SSK Jn  [        U" U R                  5      5      $ )Nr   )r   )pandas.core.framer   r{   r8   )r<   r   s     r"   rB   SeriesInfo.dtype_counts  s    /*9TYY+?@@r$   c                T    U R                   S:H  nU R                  R                  SUS9$ )zkMemory usage in bytes.

Returns
-------
memory_usage_bytes : int
    Object's total memory usage in bytes.
rP   Tr   )r2   r8   r   s     r"   rI   SeriesInfo.memory_usage_bytes  s.       F*yy%%Dt%<<r$   r   rW   )r8   r   r2   r   r_   rj   rf   )r_   z	list[int]r^   r`   rc   )rk   rl   rm   rn   ro   rx   r\   rq   rF   r=   rB   rI   rr   r,   r$   r"   r   r   `  s     +/CC (C 
	C (,###' % 	
  ! 
( # # " " A A
 	= 	=r$   r   c                  :    \ rS rSrSrSSS jjr\S	S j5       rSrg)
_InfoPrinterAbstracti  z.
Class for printing dataframe or series info.
Nc                    U R                  5       nUR                  5       nUc  [        R                  n[        R
                  " X5        g)z Save dataframe info into buffer.N)_create_table_builder	get_linessysstdoutfmtbuffer_put_lines)r<   rX   table_builderliness       r"   r   _InfoPrinterAbstract.to_buffer  s:    224'');**CS(r$   c                    g)z!Create instance of table builder.Nr,   r;   s    r"   r   *_InfoPrinterAbstract._create_table_builder  r?   r$   r,   rW   )rX   rg   r_   rj   )r_   _TableBuilderAbstract)	rk   rl   rm   rn   ro   r   r   r   rr   r,   r$   r"   r   r     s     ) 0 0r$   r   c                      \ rS rSrSr   S         SS jjr\SS j5       r\SS j5       r\SS j5       r	\SS j5       r
SS	 jrSS
 jrSS jrSrg)r   i  aK  
Class for printing dataframe info.

Parameters
----------
info : DataFrameInfo
    Instance of DataFrameInfo.
max_cols : int, optional
    When to switch from the verbose to the truncated output.
verbose : bool, optional
    Whether to print the full summary.
show_counts : bool, optional
    Whether to show the non-null counts.
Nc                    Xl         UR                  U l        X0l        U R                  U5      U l        U R                  U5      U l        g rW   )r   r8   rZ   _initialize_max_colsrY   _initialize_show_countsr[   )r<   r   rY   rZ   r[   s        r"   rx   _DataFrameInfoPrinter.__init__  s>     	II	11(;77Dr$   c                    [        S5      $ )z"Maximum info rows to be displayed.zdisplay.max_info_rowsr   r;   s    r"   max_rows_DataFrameInfoPrinter.max_rows  s     122r$   c                F    [        U R                  U R                  :  5      $ )zDCheck if number of columns to be summarized does not exceed maximum.)boolr   rY   r;   s    r"   exceeds_info_cols'_DataFrameInfoPrinter.exceeds_info_cols  s     DNNT]]233r$   c                X    [        [        U R                  5      U R                  :  5      $ )zACheck if number of rows to be summarized does not exceed maximum.)r   r   r8   r   r;   s    r"   exceeds_info_rows'_DataFrameInfoPrinter.exceeds_info_rows  s      C		NT]]233r$   c                .    U R                   R                  $ r   r   r   r;   s    r"   r   _DataFrameInfoPrinter.col_count       yy"""r$   c                "    Uc  [        S5      $ U$ )Nzdisplay.max_info_columnsr   )r<   rY   s     r"   r   *_DataFrameInfoPrinter._initialize_max_cols  s    899r$   c                p    Uc2  [        U R                  (       + =(       a    U R                  (       + 5      $ U$ rW   )r   r   r   r<   r[   s     r"   r   -_DataFrameInfoPrinter._initialize_show_counts  s0    D222Q4;Q;Q7QRRr$   c                (   U R                   (       a  [        U R                  U R                  S9$ U R                   SL a  [	        U R                  S9$ U R
                  (       a  [	        U R                  S9$ [        U R                  U R                  S9$ )zK
Create instance of table builder based on verbosity and display settings.
r   with_countsFr   )rZ   _DataFrameTableBuilderVerboser   r[    _DataFrameTableBuilderNonVerboser   r;   s    r"   r   +_DataFrameInfoPrinter._create_table_builder  sz     <<0YY ,,  \\U"3CC##3CC0YY ,, r$   )r8   r   rY   r[   rZ   )NNN)
r   rt   rY   rh   rZ   ri   r[   ri   r_   rj   rc   r_   r   )rY   rh   r_   rd   r[   ri   r_   r   )r_   _DataFrameTableBuilder)rk   rl   rm   rn   ro   rx   rq   r   r   r   r   r   r   r   rr   r,   r$   r"   r   r     s    $  $##'EE E 	E
 !E 
E 3 3 4 4 4 4 # #
r$   r   c                  L    \ rS rSrSr  S       S	S jjrS
S jrSS jrSrg)r   i  zClass for printing series info.

Parameters
----------
info : SeriesInfo
    Instance of SeriesInfo.
verbose : bool, optional
    Whether to print the full summary.
show_counts : bool, optional
    Whether to show the non-null counts.
Nc                j    Xl         UR                  U l        X l        U R                  U5      U l        g rW   )r   r8   rZ   r   r[   )r<   r   rZ   r[   s       r"   rx   _SeriesInfoPrinter.__init__  s,     	II	77Dr$   c                    U R                   (       d  U R                   c  [        U R                  U R                  S9$ [	        U R                  S9$ )z6
Create instance of table builder based on verbosity.
r   r   )rZ   _SeriesTableBuilderVerboser   r[   _SeriesTableBuilderNonVerboser;   s    r"   r   (_SeriesInfoPrinter._create_table_builder  sB     <<4<</-YY ,, 
 1dii@@r$   c                    Uc  gU$ )NTr,   r   s     r"   r   *_SeriesInfoPrinter._initialize_show_counts"  s    r$   )r8   r   r[   rZ   )NN)r   r   rZ   ri   r[   ri   r_   rj   )r_   _SeriesTableBuilderr   )	rk   rl   rm   rn   ro   rx   r   r   rr   r,   r$   r"   r   r     sJ    
  $#'		E	E 	E !		E
 
	E
Ar$   r   c                      \ rS rSr% SrS\S'   S\S'   \SS j5       r\SS j5       r	\SS	 j5       r
\SS
 j5       r\SS j5       r\SS j5       r\SS j5       rSS jrSS jrSS jrSrg)r   i)  z"
Abstract builder for info table.
	list[str]_linesr5   r   c                    g)z-Product in a form of list of lines (strings).Nr,   r;   s    r"   r   _TableBuilderAbstract.get_lines1  r?   r$   c                .    U R                   R                  $ rW   r   r8   r;   s    r"   r8   _TableBuilderAbstract.data5  s    yy~~r$   c                .    U R                   R                  $ )z*Dtypes of each of the DataFrame's columns.)r   r=   r;   s    r"   r=   _TableBuilderAbstract.dtypes9  s     yyr$   c                .    U R                   R                  $ )rA   )r   rB   r;   s    r"   rB   "_TableBuilderAbstract.dtype_counts>  s     yy%%%r$   c                @    [        U R                  R                  5      $ )z Whether to display memory usage.)r   r   r2   r;   s    r"   display_memory_usage*_TableBuilderAbstract.display_memory_usageC  s     DII**++r$   c                .    U R                   R                  $ )z/Memory usage string with proper size qualifier.)r   rM   r;   s    r"   rM   )_TableBuilderAbstract.memory_usage_stringH  s     yy,,,r$   c                .    U R                   R                  $ rW   )r   rF   r;   s    r"   rF   %_TableBuilderAbstract.non_null_countsM  s    yy(((r$   c                r    U R                   R                  [        [        U R                  5      5      5        g)z>Add line with string representation of dataframe to the table.N)r   appendr   typer8   r;   s    r"   add_object_type_line*_TableBuilderAbstract.add_object_type_lineQ  s!    3tDII/0r$   c                ~    U R                   R                  U R                  R                  R	                  5       5        g)z,Add line with range of indices to the table.N)r   r   r8   rS   _summaryr;   s    r"   add_index_range_line*_TableBuilderAbstract.add_index_range_lineU  s%    499??3356r$   c                    [        U R                  R                  5       5       VVs/ s H  u  pU SUS S3PM     nnnU R                  R	                  SSR                  U5       35        gs  snnf )z2Add summary line with dtypes present in dataframe.(d)zdtypes: z, N)sortedrB   itemsr   r   join)r<   keyvalcollected_dtypess       r"   add_dtypes_line%_TableBuilderAbstract.add_dtypes_lineY  sq     /5T5F5F5L5L5N.O
.O(#se1SG1.O 	 
 	Xdii0@&A%BCD
s   A-r,   Nr_   r   )r_   r7   r^   r`   r   re   rb   r_   rj   )rk   rl   rm   rn   ro   rp   r   r   rq   r8   r=   rB   r   rM   rF   r   r  r  rr   r,   r$   r"   r   r   )  s     
O< <       & & , , - - ) )17Er$   r   c                      \ rS rSrSrSS jrSS jrSS jr\SS j5       r	\
SS j5       r\
SS j5       r\
SS	 j5       rSS
 jrSrg)r   ia  zx
Abstract builder for dataframe info table.

Parameters
----------
info : DataFrameInfo.
    Instance of DataFrameInfo.
c                   Xl         g rW   r   r<   r   s     r"   rx   _DataFrameTableBuilder.__init__k  s    #'	r$   c                    / U l         U R                  S:X  a  U R                  5         U R                   $ U R                  5         U R                   $ )Nr   )r   r   _fill_empty_info_fill_non_empty_infor;   s    r"   r    _DataFrameTableBuilder.get_linesn  sE    >>Q!!# {{ %%'{{r$   c                    U R                  5         U R                  5         U R                  R                  S[	        U R
                  5      R                   S35        g)z;Add lines to the info table, pertaining to empty dataframe.zEmpty rL   N)r   r  r   r   r   r8   rk   r;   s    r"   r  '_DataFrameTableBuilder._fill_empty_infov  sD    !!#!!#VDO$<$<#=R@Ar$   c                    gz?Add lines to the info table, pertaining to non-empty dataframe.Nr,   r;   s    r"   r  +_DataFrameTableBuilder._fill_non_empty_info|  r?   r$   c                .    U R                   R                  $ )z
DataFrame.r   r;   s    r"   r8   _DataFrameTableBuilder.data       yy~~r$   c                .    U R                   R                  $ )zDataframe columns.)r   r   r;   s    r"   r   _DataFrameTableBuilder.ids  s     yy}}r$   c                .    U R                   R                  $ )z-Number of dataframe columns to be summarized.r   r;   s    r"   r    _DataFrameTableBuilder.col_count  r   r$   c                T    U R                   R                  SU R                   35        gz!Add line containing memory usage.zmemory usage: Nr   r   rM   r;   s    r"   add_memory_usage_line,_DataFrameTableBuilder.add_memory_usage_line  "    ^D,D,D+EFGr$   r   r   N)r   rt   r_   rj   r  r  )r_   r   r   rc   )rk   rl   rm   rn   ro   rx   r   r  r   r  rq   r8   r   r   r*  rr   r,   r$   r"   r   r   a  so    (B N N     # #Hr$   r   c                  ,    \ rS rSrSrSS jrSS jrSrg)r   i  z6
Dataframe info table builder for non-verbose output.
c                    U R                  5         U R                  5         U R                  5         U R                  5         U R                  (       a  U R                  5         ggr  )r   r  add_columns_summary_liner  r   r*  r;   s    r"   r  5_DataFrameTableBuilderNonVerbose._fill_non_empty_info  sL    !!#!!#%%'$$&&( %r$   c                h    U R                   R                  U R                  R                  SS95        g )NColumnsname)r   r   r   r  r;   s    r"   r0  9_DataFrameTableBuilderNonVerbose.add_columns_summary_line  s&    488,,),<=r$   r,   Nr  )rk   rl   rm   rn   ro   r  r0  rr   r,   r$   r"   r   r     s    )>r$   r   c                      \ rS rSr% SrSrS\S'   S\S'   S\S	'   S
\S'   \\SS j5       5       r	\SS j5       r
SS jrSS jrSS jr\SS j5       r\SS j5       rSS jrSS jrSS jrSS jrSS jrSrg)_TableBuilderVerboseMixini  z 
Mixin for verbose info output.
z  r   SPACINGzSequence[Sequence[str]]strrowsSequence[int]gross_column_widthsr   r   c                    g).Headers names of the columns in verbose table.Nr,   r;   s    r"   headers!_TableBuilderVerboseMixin.headers  r?   r$   c                X    U R                    Vs/ s H  n[        U5      PM     sn$ s  snf )z'Widths of header columns (only titles).)r?  r   r<   cols     r"   header_column_widths._TableBuilderVerboseMixin.header_column_widths  s$     %)LL1LSCL111s   'c                    U R                  5       n[        U R                  USS9 Vs/ s H  n[        U6 PM     sn$ s  snf )zAGet widths of columns containing both headers and actual content.Fstrict)_get_body_column_widthsziprD  max)r<   body_column_widthswidthss      r"   _get_gross_column_widths2_TableBuilderVerboseMixin._get_gross_column_widths  sS    !99; ))+=e
 L
 	
 
s   =c                    [        [        U R                  SS065      nU Vs/ s H  n[        S U 5       5      PM     sn$ s  snf )z$Get widths of table content columns.rH  Tc              3  8   #    U  H  n[        U5      v   M     g 7frW   )r   ).0r/   s     r"   	<genexpr>D_TableBuilderVerboseMixin._get_body_column_widths.<locals>.<genexpr>  s     (CqCFFCs   )listrJ  r:  rK  )r<   strcolsrC  s      r"   rI  1_TableBuilderVerboseMixin._get_body_column_widths  s=    +/T\\0O$0O+P4;<GS(C((G<<<s   Ac                d    U R                   (       a  U R                  5       $ U R                  5       $ )zl
Generator function yielding rows content.

Each element represents a row comprising a sequence of strings.
)r   _gen_rows_with_counts_gen_rows_without_countsr;   s    r"   	_gen_rows#_TableBuilderVerboseMixin._gen_rows  s+     --//0022r$   c                    g)=Iterator with string representation of body data with counts.Nr,   r;   s    r"   rY  /_TableBuilderVerboseMixin._gen_rows_with_counts  r?   r$   c                    g)@Iterator with string representation of body data without counts.Nr,   r;   s    r"   rZ  2_TableBuilderVerboseMixin._gen_rows_without_counts  r?   r$   c           
         U R                   R                  [        U R                  U R                  SS9 VVs/ s H  u  p[        X5      PM     snn5      nU R                  R                  U5        g s  snnf NTrG  )r9  r  rJ  r?  r<  r#   r   r   )r<   header	col_widthheader_lines       r"   add_header_line)_TableBuilderVerboseMixin.add_header_line  sn    ll'' *-LL$":":4**%F +*
 	;'s   A3
c           
         U R                   R                  [        U R                  U R                  SS9 VVs/ s H  u  p[        SU-  U5      PM     snn5      nU R                  R                  U5        g s  snnf )NTrG  -)r9  r  rJ  rD  r<  r#   r   r   )r<   header_colwidthgross_colwidthseparator_lines       r"   add_separator_line,_TableBuilderVerboseMixin.add_separator_line  sx    ** 8;--t/G/GPT883O .?8
 	>*s   A7
c                   U R                    Hi  nU R                  R                  [        XR                  SS9 VVs/ s H  u  p#[        X#5      PM     snn5      nU R                  R                  U5        Mk     g s  snnf rd  )r:  r9  r  rJ  r<  r#   r   r   )r<   rowrC  rm  	body_lines        r"   add_body_lines(_TableBuilderVerboseMixin.add_body_lines  sv    <<C)) 0355d00+ S10I KKy)  s   A;c              #  @   #    U R                    H
  nU S3v   M     g7f)z7Iterator with string representation of non-null counts.z	 non-nullN)rF   )r<   r   s     r"   _gen_non_null_counts._TableBuilderVerboseMixin._gen_non_null_counts  s"     ))EG9%% *s   c              #  L   #    U R                    H  n[        U5      v   M     g7f)z5Iterator with string representation of column dtypes.N)r=   r   )r<   dtypes     r"   _gen_dtypes%_TableBuilderVerboseMixin._gen_dtypes  s     [[Eu%% !   "$r,   Nr_   zSequence[str])r_   r;  r_   zIterator[Sequence[str]]r  r_   zIterator[str])rk   rl   rm   rn   ro   r9  rp   rq   r   r?  rD  rN  rI  r[  rY  rZ  rh  ro  rt  rw  r{  rr   r,   r$   r"   r8  r8    s     GS$$&&=  = 2 2
=
	3 L L O O	(	+
*&
&r$   r8  c                  ~    \ rS rSrSr      SS jrSS jr\SS j5       rSS jr	SS jr
SS jrSS	 jrSS
 jrSrg)r   i	  z2
Dataframe info table builder for verbose output.
c                   Xl         X l        [        U R                  5       5      U l        U R                  5       U l        g rW   r   r   rU  r[  r:  rN  r<  r<   r   r   s      r"   rx   &_DataFrameTableBuilderVerbose.__init__  3     	&04T^^5E0F262O2O2Q r$   c                (   U R                  5         U R                  5         U R                  5         U R                  5         U R	                  5         U R                  5         U R                  5         U R                  (       a  U R                  5         ggr  )	r   r  r0  rh  ro  rt  r  r   r*  r;   s    r"   r  2_DataFrameTableBuilderVerbose._fill_non_empty_info  sp    !!#!!#%%'!$$&&( %r$   c                4    U R                   (       a  / SQ$ / SQ$ )r>  ) # ColumnNon-Null Countr   )r  r  r   r   r;   s    r"   r?  %_DataFrameTableBuilderVerbose.headers%  s     ??))r$   c                V    U R                   R                  SU R                   S35        g )NzData columns (total z
 columns):)r   r   r   r;   s    r"   r0  6_DataFrameTableBuilderVerbose.add_columns_summary_line,  s#    1$..1ALMr$   c              #     #    [        U R                  5       U R                  5       U R                  5       SS9 Sh  vN   g N7f)ra  TrG  N)rJ  _gen_line_numbers_gen_columnsr{  r;   s    r"   rZ  6_DataFrameTableBuilderVerbose._gen_rows_without_counts/  s>     ""$	
 	
 	
s   :AAAc              #     #    [        U R                  5       U R                  5       U R                  5       U R	                  5       SS9 Sh  vN   g N7fr^  TrG  N)rJ  r  r  rw  r{  r;   s    r"   rY  3_DataFrameTableBuilderVerbose._gen_rows_with_counts8  sJ     ""$%%'
 	
 	
s   A	AAAc              #  V   #    [        U R                  5       H  u  pSU 3v   M     g7f)z6Iterator with string representation of column numbers.r+   N)	enumerater   )r<   i_s      r"   r  /_DataFrameTableBuilderVerbose._gen_line_numbersB  s%     dhh'DAaS'M (s   ')c              #  L   #    U R                    H  n[        U5      v   M     g7f)z4Iterator with string representation of column names.N)r   r   rB  s     r"   r  *_DataFrameTableBuilderVerbose._gen_columnsG  s     88Cs## r}  r<  r   r:  r   N)r   rt   r   r   r_   rj   r  r~  r  r  )rk   rl   rm   rn   ro   rx   r  rq   r?  r0  rZ  rY  r  r  rr   r,   r$   r"   r   r   	  sa    	R 	R 		R
 
	R
) * *N


$r$   r   c                  ^    \ rS rSrSrS
S jrSS jr\SS j5       rSS jr	\
SS j5       rSrg	)r   iM  zo
Abstract builder for series info table.

Parameters
----------
info : SeriesInfo.
    Instance of SeriesInfo.
c                   Xl         g rW   r   r  s     r"   rx   _SeriesTableBuilder.__init__W  s     $	r$   c                H    / U l         U R                  5         U R                   $ rW   )r   r  r;   s    r"   r   _SeriesTableBuilder.get_linesZ  s    !!#{{r$   c                .    U R                   R                  $ )zSeries.r   r;   s    r"   r8   _SeriesTableBuilder.data_  r"  r$   c                T    U R                   R                  SU R                   35        gr(  r)  r;   s    r"   r*  )_SeriesTableBuilder.add_memory_usage_lined  r,  r$   c                    gz<Add lines to the info table, pertaining to non-empty series.Nr,   r;   s    r"   r  (_SeriesTableBuilder._fill_non_empty_infoh  r?   r$   r-  N)r   r   r_   rj   r  r   r  )rk   rl   rm   rn   ro   rx   r   rq   r8   r*  r   r  rr   r,   r$   r"   r   r   M  sA    %
  H K Kr$   r   c                  "    \ rS rSrSrSS jrSrg)r   im  z3
Series info table builder for non-verbose output.
c                    U R                  5         U R                  5         U R                  5         U R                  (       a  U R	                  5         ggr  )r   r  r  r   r*  r;   s    r"   r  2_SeriesTableBuilderNonVerbose._fill_non_empty_infor  s@    !!#!!#$$&&( %r$   r,   Nr  )rk   rl   rm   rn   ro   r  rr   r,   r$   r"   r   r   m  s    )r$   r   c                  j    \ rS rSrSr      SS jrSS jrSS jr\SS j5       r	SS jr
SS jrS	rg
)r   i{  z/
Series info table builder for verbose output.
c                   Xl         X l        [        U R                  5       5      U l        U R                  5       U l        g rW   r  r  s      r"   rx   #_SeriesTableBuilderVerbose.__init__  r  r$   c                (   U R                  5         U R                  5         U R                  5         U R                  5         U R	                  5         U R                  5         U R                  5         U R                  (       a  U R                  5         ggr  )	r   r  add_series_name_linerh  ro  rt  r  r   r*  r;   s    r"   r  /_SeriesTableBuilderVerbose._fill_non_empty_info  sp    !!#!!#!!#!$$&&( %r$   c                h    U R                   R                  SU R                  R                   35        g )NzSeries name: )r   r   r8   r5  r;   s    r"   r  /_SeriesTableBuilderVerbose.add_series_name_line  s$    ]499>>*:;<r$   c                2    U R                   (       a  SS/$ S/$ )r>  r  r   r  r;   s    r"   r?  "_SeriesTableBuilderVerbose.headers  s      $g..yr$   c              #  N   #    S U R                  5        5        Sh  vN   g N7f)ra  c              3  &   #    U  H  o/v   M	     g 7frW   r,   )rR  rz  s     r"   rS  F_SeriesTableBuilderVerbose._gen_rows_without_counts.<locals>.<genexpr>  s     <);G);s   N)r{  r;   s    r"   rZ  3_SeriesTableBuilderVerbose._gen_rows_without_counts  s     <)9)9);<<<s   %#%c              #  n   #    [        U R                  5       U R                  5       SS9 Sh  vN   g N7fr  )rJ  rw  r{  r;   s    r"   rY  0_SeriesTableBuilderVerbose._gen_rows_with_counts  s)     t002D4D4D4FtTTTs   +535r  N)r   r   r   r   r_   rj   r  r~  r  )rk   rl   rm   rn   ro   rx   r  r  rq   r?  rZ  rY  rr   r,   r$   r"   r   r   {  sW    	R 	R 		R
 
	R
)=  =Ur$   r   c                r    U R                   R                  5       R                  S 5      R                  5       $ )zC
Create mapping between datatypes and their number of occurrences.
c                    U R                   $ rW   r4  )r/   s    r"   <lambda>-_get_dataframe_dtype_counts.<locals>.<lambda>  s    affr$   )r=   value_countsgroupbyr   )dfs    r"   r{   r{     s,    
 99!!#++,<=AACCr$   )r    zstr | Dtyper!   rd   r_   r   )r-   floatr.   r   r_   r   rW   )r2   r   r_   r9   )r  r   r_   ra   )4
__future__r   abcr   r   r   textwrapr   typingr   pandas._configr	   pandas.io.formatsr
   r   pandas.io.formats.printingr   collections.abcr   r   r   r   pandas._typingr   r   pandasr   r   r   r   series_examples_subseries_see_also_subseries_max_cols_subseries_sub_kwargsr#   r0   r3   r5   rt   r   r   r   r   r   r   r   r8  r   r   r   r   r{   r,   r$   r"   <module>r     s   "     % + 3 
  ? 9; | 4 
 F  '&''6 '4,@ '+#P PfFI FR9= 9=x0 0$M0 M`(- (V5EC 5Ep0H2 0Hf>'= >$`& 5 `&FA$$:<U A$HK/ K@)$7 ),U!46O ,U^Dr$   