class_docstr: A Node instance is used for composing tree-based structures.
class_docstr_tok: ["A","Node","instance","is","used","for","composing","tree-based","structures","."]
code: def flag(self, flag: bool) -> None:
      if not isinstance(flag, bool):
          raise e.TypeError("`flag` should be a boolean")
  
      self._flag = flag
  
imports: from __future__ import annotations
  from typing import Any, Dict, List, Optional, Union
  import numpy
  import opytimizer.utils.constant
  import opytimizer.utils.exception
label_desc: Use image node_id 17 for calling the Node obj's underlying member method code with example usage: obj.flag(flag) without return types