class_docstr: Generate random variables distributed according to an arbitrary function
  
  Parameters
  ----------
  func : function
      func should take an array of x values, and return an array
      proportional to the probability density at each value
  xmin : float
      minimum value of interest
  xmax : float
      maximum value of interest
  Nx : int (optional)
      number of samples to draw.  Default is 1000
  random_state : None, int, or np.random.RandomState instance
      random seed or random number generator
  func_args : dictionary (optional)
      additional keyword arguments to be passed to func
docstr: Draw random variables from the distribution
  
  Parameters
  ----------
  shape : integer or tuple
      shape of desired array
  
  Returns
  -------
  rv : ndarray, shape=shape
      random variables
code: def rvs(self, shape):
      """Draw random variables from the distribution
  
      Parameters
      ----------
      shape : integer or tuple
          shape of desired array
  
      Returns
      -------
      rv : ndarray, shape=shape
          random variables
      """
      # generate uniform variables between 0 and 1
      y = self.random_state.random_sample(shape)
      return interpolate.splev(y, self._tck)
  
file_path: astroML/astroML/density_estimation/empirical.py
imports: import numpy
  from scipy import interpolate
  from sklearn.utils import check_random_state
label_desc: Use image node_id 2 for calling the FunctionDistribution obj's underlying member method code with example usage: obj.rvs(shape) and returns: interpolate