Which Matplotlib function sets axis labels?
-
A
plt.label()
-
B
plt.xlabel()/plt.ylabel()
Correct answer
-
C
plt.axis_label()
-
D
plt.set_label()
Correct answer
B. plt.xlabel()/plt.ylabel()
18 views
Explanation
plt.xlabel() and plt.ylabel() set labels for the x-axis and y-axis respectively.
Doubts & discussion
Not sure why the answer is B? Ask here and get an explanation.
Ask a doubt about this MCQ