class_docstr: Class for estimating and conducting inference in an AFT model.
  
  Parameters
  ----------
  
  endog: nx1 array
      Response variables that are subject to random censoring
  
  exog: nxk array
      Matrix of covariates
  
  censors: nx1 array
      array with entries 0 or 1.  0 indicates a response was
      censored.
  
  Attributes
  ----------
  nobs : float
      Number of observations
  endog : ndarray
      Endog attay
  exog : ndarray
      Exogenous variable matrix
  censors
      Censors array but sets the max(endog) to uncensored
  nvar : float
      Number of exogenous variables
  uncens_nobs : float
      Number of uncensored observations
  uncens_endog : ndarray
      Uncensored response variables
  uncens_exog : ndarray
      Exogenous variables of the uncensored observations
  
  Methods
  -------
  
  params:
      Fits model parameters
  
  test_beta:
      Tests if beta = b0 for any vector b0.
  
  Notes
  -----
  
  The data is immediately sorted in order of increasing endogenous
  variables
  
  The last observation is assumed to be uncensored which makes
  estimation and inference possible.
class_docstr_tok: ["Class","for","estimating","and","conducting","inference","in","an","AFT","model",".","Parameters","--","--","--","--","--","endog",":","nx1","array","Response","variables","that","are","subject","to","random","censoring","exog",":","nxk","array","Matrix","of","covariates","censors",":","nx1","array","array","with","entries","0","or","1",".","0","indicates","a","response","was","censored",".","Attributes","--","--","--","--","--","nobs",":","float","Number","of","observations","endog",":","ndarray","Endog","attay","exog",":","ndarray","Exogenous","variable","matrix","censors","Censors","array","but","sets","the","max","(","endog",")","to","uncensored","nvar",":","float","Number","of","exogenous","variables","uncens_nobs",":","float","Number","of","uncensored","observations","uncens_endog",":","ndarray","Uncensored","response","variables","uncens_exog",":","ndarray","Exogenous","variables","of","the","uncensored","observations","Methods","--","--","--","-","params",":","Fits","model","parameters","test_beta",":","Tests","if","beta","=","b0","for","any","vector","b0",".","Notes","--","--","-","The","data","is","immediately","sorted","in","order","of","increasing","endogenous","variables","The","last","observation","is","assumed","to","be","uncensored","which","makes","estimation","and","inference","possible","."]
docstr: Fits an AFT model and returns results instance
  
  Parameters
  ----------
  None
  
  
  Returns
  -------
  Results instance.
  
  Notes
  -----
  To avoid dividing by zero, max(endog) is assumed to be uncensored.
docstr_tok: ["Fits","an","AFT","model","and","returns","results","instance","Parameters","--","--","--","--","--","None","Returns","--","--","--","-","Results","instance",".","Notes","--","--","-","To","avoid","dividing","by","zero",",","max","(","endog",")","is","assumed","to","be","uncensored","."]
code: def fit(self):
      """
  
      Fits an AFT model and returns results instance
  
      Parameters
      ----------
      None
  
  
      Returns
      -------
      Results instance.
  
      Notes
      -----
      To avoid dividing by zero, max(endog) is assumed to be uncensored.
      """
      return AFTResults(self)
  
imports: import warnings
  import numpy
  from scipy import optimize
  from scipy.stats import chi2
  from statsmodels.regression.linear_model import OLS, WLS
  from statsmodels.tools import add_constant
  from statsmodels.tools.sm_exceptions import IterationLimitWarning
  from .descriptive import _OptFuncts
label_desc: Use image node_id 5 for calling the emplikeAFT obj's underlying member method code with example usage: obj.fit() and returns: AFTResults