molsysmt.third_party.nglview.set_color#

molsysmt.third_party.nglview.set_color(view, color, selection='all', syntax='MolSysMT')[source]#

Setting uniform or custom color on representations in NGLWidget.

Parameters:
  • view (nglview.NGLWidget) – Target molecular viewer instance.

  • color (object) – Argument color.

  • selection (str, list, tuple, or numpy.ndarray, default='all') – Selection string or boolean/integer array specifying elements.

  • syntax (str, default='MolSysMT') – Selection syntax used to evaluate selection (e.g., ‘MolSysMT’, ‘MDTraj’).

  • versionadded: (..) – 1.0.0: