docs: def plot_legend(ax, no_legend=True, legend_arg=None):
      """
      Function that defines the legend options
      of a matplotlib plot.
  
      Args:
          ax: matplotlib axes
          no_legend (bool): Defines the presence of a legend in the figure
          legend_arg (dict): Addition arguments for matplotlib.legend() call
      """
      legend_arg = dict_if_none(legend_arg)
  
      if not no_legend:
          ax.legend(**legend_arg)