U
    Ãmœd   ã                   @   sH   d Z ddlmZ dZdZdZdZdZdZ	d	Z
d
d„ Zdd„ Zdd„ ZdS )z"Heart Transplant Data, Miller 1976é    )ÚutilsÚrestructuredtextz???zTransplant Survival Dataz^Miller, R. (1976). Least squares regression with censored data. Biometrica, 63 (3). 449-464.

z1Survival times after receiving a heart transplantz“This data contains the survival time after receiving a heart transplant, the age of the patient and whether or not the survival time was censored.
a  ::

    Number of Observations - 69

    Number of Variables - 3

    Variable name definitions::
        death - Days after surgery until death
        age - age at the time of surgery
        censored - indicates if an observation is censored.  1 is uncensored
c                   C   s   t ƒ S )z˜
    Load the data and return a Dataset class instance.

    Returns
    -------
    Dataset
        See DATASET_PROPOSAL.txt for more information.
    )Úload_pandas© r   r   úX/home/sam/Atlas/atlas_env/lib/python3.8/site-packages/statsmodels/datasets/heart/data.pyÚload    s    	r   c                  C   sF   t ƒ } tj| dd d�}|jjd d …df |_|jjd d …df |_|S )Nr   )Z	endog_idxZexog_idxé   )Ú	_get_dataÚduZprocess_pandasZexogZilocZcensors)ÚdataZdatasetr   r   r   r   ,   s
    r   c                   C   s   t  td¡S )Nz	heart.csv)r
   Zload_csvÚ__file__r   r   r   r   r	   4   s    r	   N)Ú__doc__Zstatsmodels.datasetsr   r
   Ú__docformat__Z	COPYRIGHTZTITLEZSOURCEZ
DESCRSHORTZ	DESCRLONGÚNOTEr   r   r	   r   r   r   r   Ú<module>   s   