class_docstr: A generic Copula class meant for subclassing.
  
  Notes
  -----
  A function :math:`\phi` on :math:`[0, \infty]` is the Laplace-Stieltjes
  transform of a distribution function if and only if :math:`\phi` is
  completely monotone and :math:`\phi(0) = 1` [2]_.
  
  The following algorithm for sampling a ``d``-dimensional exchangeable
  Archimedean copula with generator :math:`\phi` is due to Marshall, Olkin
  (1988) [1]_, where :math:`LS^{−1}(\phi)` denotes the inverse
  Laplace-Stieltjes transform of :math:`\phi`.
  
  From a mixture representation with respect to :math:`F`, the following
  algorithm may be derived for sampling Archimedean copulas, see [1]_.
  
  1. Sample :math:`V \sim F = LS^{−1}(\phi)`.
  2. Sample i.i.d. :math:`X_i \sim U[0,1], i \in \{1,...,d\}`.
  3. Return:math:`(U_1,..., U_d)`, where :math:`U_i = \phi(−\log(X_i)/V), i
     \in \{1, ...,d\}`.
  
  Detailed properties of each copula can be found in [3]_.
  
  Instances of the class can access the attributes: ``rng`` for the random
  number generator (used for the ``seed``).
  
  **Subclassing**
  
  When subclassing `Copula` to create a new copula, ``__init__`` and
  ``random`` must be redefined.
  
  * ``__init__(theta)``: If the copula
    does not take advantage of a ``theta``, this parameter can be omitted.
  * ``random(n, random_state)``: draw ``n`` from the copula.
  * ``pdf(x)``: PDF from the copula.
  * ``cdf(x)``: CDF from the copula.
  
  References
  ----------
  .. [1] Marshall AW, Olkin I. “Families of Multivariate Distributions”,
    Journal of the American Statistical Association, 83, 834–841, 1988.
  .. [2] Marius Hofert. "Sampling Archimedean copulas",
    Universität Ulm, 2008.
  .. rvs[3] Harry Joe. "Dependence Modeling with Copulas", Monographs on
    Statistics and Applied Probability 134, 2015.
class_docstr_tok: ["A","generic","Copula","class","meant","for","subclassing",".","Notes","--","--","-","A","function",":","math",":","`","\\phi","`","on",":","math",":","`","[","0",",","\\infty","]","`","is","the","Laplace-Stieltjes","transform","of","a","distribution","function","if","and","only","if",":","math",":","`","\\phi","`","is","completely","monotone","and",":","math",":","`","\\phi","(","0",")","=","1","`","[","2","]","_",".","The","following","algorithm","for","sampling","a","``","d","``","-dimensional","exchangeable","Archimedean","copula","with","generator",":","math",":","`","\\phi","`","is","due","to","Marshall",",","Olkin","(","1988",")","[","1","]","_",",","where",":","math",":","`","LS^","{","\u22121","}","(","\\phi",")","`","denotes","the","inverse","Laplace-Stieltjes","transform","of",":","math",":","`","\\phi","`",".","From","a","mixture","representation","with","respect","to",":","math",":","`","F","`",",","the","following","algorithm","may","be","derived","for","sampling","Archimedean","copulas",",","see","[","1","]","_",".","1",".","Sample",":","math",":","`","V","\\sim","F","=","LS^","{","\u22121","}","(","\\phi",")","`",".","2",".","Sample","i.i.d",".",":","math",":","`","X_i","\\sim","U","[","0,1","]",",","i","\\in","\\","{","1",",","...",",","d\\","}","`",".","3",".","Return",":","math",":","`","(","U_1",",","...",",","U_d",")","`",",","where",":","math",":","`","U_i","=","\\phi","(","\u2212\\log","(","X_i",")","\/V",")",",","i","\\in","\\","{","1",",","...",",","d\\","}","`",".","Detailed","properties","of","each","copula","can","be","found","in","[","3","]","_",".","Instances","of","the","class","can","access","the","attributes",":","``","rng","``","for","the","random","number","generator","(","used","for","the","``","seed","``",")",".","*","*","Subclassing","*","*","When","subclassing","`","Copula","`","to","create","a","new","copula",",","``","__init__","``","and","``","random","``","must","be","redefined",".","*","``","__init__","(","theta",")","``",":","If","the","copula","does","not","take","advantage","of","a","``","theta","``",",","this","parameter","can","be","omitted",".","*","``","random","(","n",",","random_state",")","``",":","draw","``","n","``","from","the","copula",".","*","``","pdf","(","x",")","``",":","PDF","from","the","copula",".","*","``","cdf","(","x",")","``",":","CDF","from","the","copula",".","References","--","--","--","--","--","..","[","1","]","Marshall","AW",",","Olkin","I",".","\u201c","Families","of","Multivariate","Distributions","\u201d",",","Journal","of","the","American","Statistical","Association",",","83",",","834\u2013841",",","1988",".","..","[","2","]","Marius","Hofert",".","``","Sampling","Archimedean","copulas","''",",","Universit\u00e4t","Ulm",",","2008",".","..","rvs","[","3","]","Harry","Joe",".","``","Dependence","Modeling","with","Copulas","''",",","Monographs","on","Statistics","and","Applied","Probability","134",",","2015","."]
docstr: Probability density function of copula.
  
  Parameters
  ----------
  u : array_like, 2-D
      Points of random variables in unit hypercube at which method is
      evaluated.
      The second (or last) dimension should be the same as the dimension
      of the random variable, e.g. 2 for bivariate copula.
  args : tuple
      Arguments for copula parameters. The number of arguments depends
      on the copula.
  
  Returns
  -------
  pdf : ndarray, (nobs, k_dim)
      Copula pdf evaluated at points ``u``.
docstr_tok: ["Probability","density","function","of","copula",".","Parameters","--","--","--","--","--","u",":","array_like",",","2-D","Points","of","random","variables","in","unit","hypercube","at","which","method","is","evaluated",".","The","second","(","or","last",")","dimension","should","be","the","same","as","the","dimension","of","the","random","variable",",","e.g",".","2","for","bivariate","copula",".","args",":","tuple","Arguments","for","copula","parameters",".","The","number","of","arguments","depends","on","the","copula",".","Returns","--","--","--","-","pdf",":","ndarray",",","(","nobs",",","k_dim",")","Copula","pdf","evaluated","at","points","``","u","``","."]
code: def pdf(self, u, args=()):
      """Probability density function of copula.
  
      Parameters
      ----------
      u : array_like, 2-D
          Points of random variables in unit hypercube at which method is
          evaluated.
          The second (or last) dimension should be the same as the dimension
          of the random variable, e.g. 2 for bivariate copula.
      args : tuple
          Arguments for copula parameters. The number of arguments depends
          on the copula.
  
      Returns
      -------
      pdf : ndarray, (nobs, k_dim)
          Copula pdf evaluated at points ``u``.
      """
  
imports: from abc import ABC, abstractmethod
  import numpy
  from scipy import stats
  from statsmodels.graphics import utils
label_desc: Use image node_id 3 for calling the Copula obj's underlying member method code with example usage: obj.pdf(u, args) without return types