class_docstr: Categorical Distribution 
class_docstr_tok: ["Categorical","Distribution"]
docstr: Constructor 
code: def __init__(self, categories, p):
      """Constructor"""
      super(Categorical, self).__init__()
      self.cat = list(categories)
      self.k = len(categories)
      self.p = np.array(p)
      self.dim = 1
      self.domain = domains.IntegralDomain([[1, self.k]])
  
imports: from __future__ import absolute_import
  import numpy
  from .distribution import Discrete
  from ..exd import domains
label_desc: Use image node_id 1 to create a new Categorical object from inherited base classes: Discrete with example: obj = Categorical(categories, p)