code: def simulate_randomized_trial(n=1000, p=5, sigma=1.0, adj=0.0):
      """Synthetic data of a randomized trial
          From Setup B in Nie X. and Wager S. (2018) 'Quasi-Oracle Estimation of Heterogeneous Treatment Effects'
      Args:
          n (int, optional): number of observations
          p (int optional): number of covariates (>=5)
          sigma (float): standard deviation of the error term
          adj (float): no effect. added for consistency
      Returns:
          (tuple): Synthetically generated samples with the following outputs:
              - y ((n,)-array): outcome variable.
              - X ((n,p)-ndarray): independent variables.
              - w ((n,)-array): treatment flag with value 0 or 1.
              - tau ((n,)-array): individual treatment effect.
              - b ((n,)-array): expected outcome.
              - e ((n,)-array): propensity of receiving treatment.
      """
  
      X = np.random.normal(size=n * p).reshape((n, -1))
      b = np.maximum.reduce(
          [np.repeat(0.0, n), X[:, 0] + X[:, 1], X[:, 2]]
      ) + np.maximum(np.repeat(0.0, n), X[:, 3] + X[:, 4])
      e = np.repeat(0.5, n)
      tau = X[:, 0] + np.log1p(np.exp(X[:, 1]))
  
      w = np.random.binomial(1, e, size=n)
      y = b + (w - 0.5) * tau + sigma * np.random.normal(size=n)
  
      return y, X, w, tau, b, e
  
file_path: causalml/causalml/dataset/regression.py
imports: import logging
  import numpy
  from scipy.special import expit, logit
label_desc: Use image node_id 3 for calling a global function with example usage: simulate_randomized_trial(n, p, sigma, adj) and returns: y,  X,  w,  tau,  b,  e