B
    Z                 @   sl   d Z dZdZe ZdZdZdZdZddlm	Z	m
Z
mZ dd	lmZ dd
lmZmZ dd Zdd Zdd ZdS )zU.S. Strike Duration DataZrestructuredtextzThis is public domain.z
This is a subset of the data used in Kennan (1985). It was originally
published by the Bureau of Labor Statistics.

::

    Kennan, J. 1985. "The duration of contract strikes in US manufacturing.
        `Journal of Econometrics` 28.1, 5-28.
zcContains data on the length of strikes in US manufacturing and
unanticipated industrial production.zContains data on the length of strikes in US manufacturing and
unanticipated industrial production. The data is a subset of the data originally
used by Kennan. The data here is data for the months of June only to avoid
seasonal issues.z::

    Number of observations - 62

    Number of variables - 2

    Variable name definitions::

                duration - duration of the strike in days
                iprod - unanticipated industrial production
    )
recfromtxtcolumn_stackarray)utils)dirnameabspathc              C   s   t  } tj| dtdS )z
    Load the strikes data and return a Dataset class instance.

    Returns
    -------
    Dataset instance:
        See DATASET_PROPOSAL.txt for more information.
    r   )	endog_idxdtype)	_get_dataduZprocess_recarrayfloat)data r   @lib/python3.7/site-packages/statsmodels/datasets/strikes/data.pyload+   s    	r   c              C   s   t  } tj| dtdS )z
    Load the strikes data and return a Dataset class instance.

    Returns
    -------
    Dataset instance:
        See DATASET_PROPOSAL.txt for more information.
    r   )r   r	   )r
   r   Zprocess_recarray_pandasr   )r   r   r   r   load_pandas7   s    	r   c           	   C   s:   t tt} t| d d}t|ddtd}W d Q R X |S )Nz/strikes.csvrb,T)Z	delimiternamesr	   )r   r   __file__openr   r   )filepathfr   r   r   r   r
   C   s    r
   N)__doc__Z__docformat__Z	COPYRIGHTZTITLEZSOURCEZ
DESCRSHORTZ	DESCRLONGZNOTEZnumpyr   r   r   Zstatsmodels.datasetsr   r   os.pathr   r   r   r   r
   r   r   r   r   <module>   s   	