o
    d                     @  s   d dl mZ d dlmZ d dlmZmZ d dlmZ d dl	m
Z
 d dlmZ d dlmZ d dlmZ er@d d	lmZ d d
lmZ ddejfdddZdS )    )annotations)Path)TYPE_CHECKINGSequence)lib)import_optional_dependency)check_dtype_backend)is_list_like)stringify_path)DtypeBackend)	DataFrameNTpath
str | PathusecolsSequence[str] | Noneconvert_categoricalsbooldtype_backendDtypeBackend | lib.NoDefaultreturnr   c                 C  sb   t d}t| |durt|stdt|}|jt| ||d\}}|tjur/|j	|d}|S )a?  
    Load an SPSS file from the file path, returning a DataFrame.

    Parameters
    ----------
    path : str or Path
        File path.
    usecols : list-like, optional
        Return a subset of the columns. If None, return all columns.
    convert_categoricals : bool, default is True
        Convert categorical columns into pd.Categorical.
    dtype_backend : {"numpy_nullable", "pyarrow"}, defaults to NumPy backed DataFrames
        Which dtype_backend to use, e.g. whether a DataFrame should have NumPy
        arrays, nullable dtypes are used for all dtypes that have a nullable
        implementation when "numpy_nullable" is set, pyarrow is used for all
        dtypes if "pyarrow" is set.

        The dtype_backends are still experimential.

        .. versionadded:: 2.0

    Returns
    -------
    DataFrame
    
pyreadstatNzusecols must be list-like.)r   Zapply_value_formats)r   )
r   r   r	   	TypeErrorlistZread_savr
   r   
no_defaultZconvert_dtypes)r   r   r   r   r   Zdf_ r   B/app/.heroku/python/lib/python3.10/site-packages/pandas/io/spss.py	read_spss   s   


r   )
r   r   r   r   r   r   r   r   r   r   )
__future__r   pathlibr   typingr   r   Zpandas._libsr   Zpandas.compat._optionalr   Zpandas.util._validatorsr   Zpandas.core.dtypes.inferencer	   Zpandas.io.commonr
   Zpandas._typingr   Zpandasr   r   r   r   r   r   r   <module>   s    