Matplotlib.pyplot.rcdefaults() in Python Last Updated : 19 Apr, 2020 Comments Improve Suggest changes Like Article Like Report Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. There are various plots which can be used in Pyplot are Line Plot, Contour, Histogram, Scatter, 3D Plot, etc. matplotlib.pyplot.rcdefaults() Function The rcdefaults() function in pyplot module of matplotlib library is used to restore the rc params from Matplotlib's internal default style. Syntax: matplotlib.pyplot.rcdefaults() Parameters: This method does not accepts any parameter. Returns: This method does not return any value. Below examples illustrate the matplotlib.pyplot.rcdefaults() function in matplotlib.pyplot: Example 1: Python3 1== # implementation of the matplotlib function import matplotlib.pyplot as plt plt.subplot(211) plt.rc('font', weight ='bold') plt.rc('xtick.major', size = 5, pad = 7) plt.rc('xtick', labelsize = 15) plt.plot([1, 2, 3]) plt.text(0.4, 3.5, 'matplotlib.pyplot.rcdefaults() Example') plt.rcdefaults() plt.subplot(212) plt.plot([1, 2, 3]) plt.grid(True) plt.show() Output: Example 2: Python3 1== # implementation of the matplotlib function import matplotlib.pyplot as plt import numpy as np np.random.seed(19680801) plt.rcdefaults() fig, ax = plt.subplots() people = ('Geek1', 'Geek2', 'Geek3', 'Geek4', 'Geek5') y_pos = np.arange(len(people)) performance = 3 + 5 * np.random.rand(len(people)) error = np.random.rand(len(people)) ax.bar(y_pos, performance, xerr = error, align ='center') ax.set_yticks(y_pos) ax.set_yticklabels(people) ax.invert_yaxis() plt.grid(True) plt.title('matplotlib.pyplot.rcdefaults() Example') plt.show() Output: Comment More infoAdvertise with us Next Article Matplotlib.pyplot.rcdefaults() in Python S SHUBHAMSINGH10 Follow Improve Article Tags : Python Python-matplotlib Practice Tags : python Similar Reads Matplotlib.pyplot.rc() in Python Matplotlib is an amazing visualization library in Python for 2D plots of arrays. Matplotlib is a multi-platform data visualization library built on NumPy arrays and designed to work with the broader SciPy stack. matplotlib.pyplot.rc() matplotlib.pyplot.rc() function is used to the rc params. Groupin 3 min read Matplotlib.pyplot.sca() in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. There are various plots which can be used in Pyplot are Line Plot, Contour, Histogram, Scatter, 3D Plot, 1 min read Matplotlib.pyplot.ylabels() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. matplotlib.pyplot.ylabel() Function The ylabel() function in pyplot module of matplotlib library is used 2 min read Matplotlib.pyplot.xlabels() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. matplotlib.pyplot.xlabel() Function The xlabel() function in pyplot module of matplotlib library is used 2 min read Matplotlib.pyplot.sci() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. There are various plots which can be used in Pyplot are Line Plot, Contour, Histogram, Scatter, 3D Plot, 2 min read Matplotlib.pyplot.show() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. Sample Code - Python3 1== # sample code import matplotlib.pyplot as plt plt.plot([1, 2, 3, 4], [16, 4, 1, 2 min read Matplotlib.pyplot.yticks() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. Matplotlib.pyplot.yticks() Function The annotate() function in pyplot module of matplotlib library is use 2 min read Matplotlib.pyplot.xlim() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. There are various plots which can be used in Pyplot are Line Plot, Contour, Histogram, Scatter, 3D Plot, 2 min read Matplotlib.pyplot.ylim() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. matplotlib.pyplot.ylim() Function The ylim() function in pyplot module of matplotlib library is used to g 2 min read Matplotlib.pyplot.twiny() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. Pyplot is a state-based interface to a Matplotlib module which provides a MATLAB-like interface. Sample Code Python3 1== # sample code import matplotlib.pyplot as plt plt.plot([1, 2, 3, 4], [16, 4, 1, 8 2 min read Like