code: def _create_risk_curve(self, effect, amplitude, cut, width, lag):
      if cut:
          effect = effect[: int(width - cut)]
      end_effect = int(lag + width - cut)
      if end_effect > self.n_intervals:
          end_effect = self.n_intervals
      effect = effect[: end_effect - lag]
  
      M = effect.max()
      m = effect.min()
      effect = (effect - m) / (M - m)
      effect *= amplitude - 1
      risk_curve = np.ones(self.n_intervals)
      risk_curve[lag:end_effect] += effect
      return risk_curve
  
imports: from operator import itemgetter
  import numpy
  import scipy.sparse
  from scipy.sparse import csr_matrix
  from tick.base.simulation import Simu
  from tick.hawkes import SimuHawkesExpKernels, SimuHawkesMulti
  from tick.preprocessing import LongitudinalFeaturesLagger
  from itertools import permutations
  from copy import deepcopy
  from scipy.stats import beta, norm
label_desc: Use image node_id 6 for calling the CustomEffects obj's underlying member method code with example usage: obj._create_risk_curve(effect, amplitude, cut, width, lag) and returns: risk_curve