class_docstr: Calculate model-level hierarchical aspect importance
  
  Parameters
  ----------
  loss_function :  {'rmse', '1-auc', 'mse', 'mae', 'mad'} or function, optional
      If string, then such loss function will be used to assess aspect importance
      (default is `'rmse'` or `'1-auc'`, depends on `explainer.model_type` attribute).
  type : {'variable_importance', 'ratio', 'difference'}, optional
      Type of transformation that will be applied to dropout loss
      (default is `'variable_importance'`, which is Permutational Variable Importance).
  N : int, optional
      Number of observations that will be sampled from the `explainer.data` attribute before
      the calculation of aspect importance. `None` means all `data` (default is `1000`).
  B : int, optional
      Number of permutation rounds to perform on each variable (default is `10`).
  processes : int, optional
      Number of parallel processes to use in calculations. Iterated over `B`
      (default is `1`, which means no parallel computation).
  random_state : int, optional
      Set seed for random number generator (default is random seed).
  
  Attributes
  -----------
  result : pd.DataFrame
      Main result attribute of an explanation.
  single_variable_importance : pd.DataFrame
      Additional result attribute of an explanation (it contains information 
      about the importance of individual variables).
  loss_function : function
      Loss function used to assess the variable importance.
  type : {'variable_importance', 'ratio', 'difference'}
      Type of transformation that will be applied to dropout loss.
  N : int
      Number of observations that will be sampled from the `explainer.data` attribute before
      the calculation of aspect importance. `None` means all `data` (default is `1000`).
  B : int
      Number of permutation rounds to perform on each variable (default is `10`).
  processes : int
      Number of parallel processes to use in calculations. Iterated over `B`
      (default is `1`, which means no parallel computation).
  random_state : int or None
      Set seed for random number generator.
  
  Notes
  -----
  - https://arxiv.org/abs/2104.03403
class_docstr_tok: ["Calculate","model-level","hierarchical","aspect","importance","Parameters","--","--","--","--","--","loss_function",":","{","'rmse","'",",","'","1-auc","'",",","'mse","'",",","'mae","'",",","'mad","'","}","or","function",",","optional","If","string",",","then","such","loss","function","will","be","used","to","assess","aspect","importance","(","default","is","`","'rmse","'","`","or","`","'","1-auc","'","`",",","depends","on","`","explainer.model_type","`","attribute",")",".","type",":","{","'variable_importance","'",",","'ratio","'",",","'difference","'","}",",","optional","Type","of","transformation","that","will","be","applied","to","dropout","loss","(","default","is","`","'variable_importance","'","`",",","which","is","Permutational","Variable","Importance",")",".","N",":","int",",","optional","Number","of","observations","that","will","be","sampled","from","the","`","explainer.data","`","attribute","before","the","calculation","of","aspect","importance",".","`","None","`","means","all","`","data","`","(","default","is","`","1000","`",")",".","B",":","int",",","optional","Number","of","permutation","rounds","to","perform","on","each","variable","(","default","is","`","10","`",")",".","processes",":","int",",","optional","Number","of","parallel","processes","to","use","in","calculations",".","Iterated","over","`","B","`","(","default","is","`","1","`",",","which","means","no","parallel","computation",")",".","random_state",":","int",",","optional","Set","seed","for","random","number","generator","(","default","is","random","seed",")",".","Attributes","--","--","--","--","--","-","result",":","pd.DataFrame","Main","result","attribute","of","an","explanation",".","single_variable_importance",":","pd.DataFrame","Additional","result","attribute","of","an","explanation","(","it","contains","information","about","the","importance","of","individual","variables",")",".","loss_function",":","function","Loss","function","used","to","assess","the","variable","importance",".","type",":","{","'variable_importance","'",",","'ratio","'",",","'difference","'","}","Type","of","transformation","that","will","be","applied","to","dropout","loss",".","N",":","int","Number","of","observations","that","will","be","sampled","from","the","`","explainer.data","`","attribute","before","the","calculation","of","aspect","importance",".","`","None","`","means","all","`","data","`","(","default","is","`","1000","`",")",".","B",":","int","Number","of","permutation","rounds","to","perform","on","each","variable","(","default","is","`","10","`",")",".","processes",":","int","Number","of","parallel","processes","to","use","in","calculations",".","Iterated","over","`","B","`","(","default","is","`","1","`",",","which","means","no","parallel","computation",")",".","random_state",":","int","or","None","Set","seed","for","random","number","generator",".","Notes","--","--","-","-","https",":","\/\/arxiv.org\/abs\/2104.03403"]
code: def __init__(
      self,
      loss_function=None,
      type="variable_importance",
      N=1000,
      B=10,
      processes=1,
      random_state=None,
  ):
      _B = checks.check_B(B)
      _type = checks.check_type(type)
      _random_state = checks.check_random_state(random_state)
      _processes = checks.check_processes(processes)
  
      self.loss_function = loss_function
      self.type = _type
      self.N = N
      self.B = _B
      self.random_state = _random_state
      self.processes = _processes
      self.result = pd.DataFrame()
      self.single_variable_importance = None
      self._hierarchical_clustering_dendrogram = None
  
file_path: DALEX/python/dalex/dalex/aspect/_model_triplot/object.py
imports: import numpy
  import pandas
  from copy import deepcopy
  import plotly.graph_objs
  from dalex import _theme, _global_checks
  from dalex._explanation import Explanation
  from .None import checks, plot, utils
label_desc: Use image node_id 1 to create a new ModelTriplot object from inherited base classes: Explanation with example: obj = ModelTriplot(loss_function, type, N, B, processes, random_state)