A

Admin • 833.24K Points
Coach

Q. Which method is used to add a legend to the plot?

  • (A) plt.legend()
  • (B) plt.addlegend()
  • (C) plt.setLegend()
  • (D) plt.label()
  • Correct Answer - Option(A)
  • Views: 27
  • Filed under category Matplot Lib
  • Hashtags:

Explanation by: Admin

plt.legend() adds a legend to the plot when labels are provided in the plot call.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.