
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Rishikesh Kumar Rishi has Published 1156 Articles

Rishikesh Kumar Rishi
3K+ Views
To set the aspect ratio of a 3D plot in matplotlib, we can take the following steps−Using figure() method, create a new figure or activate an existing figure.Get the current axes, creating one if necessary, with projection='3d'.Create data points, R, Y and z, using numpy.Create a surface plot using R, ... Read More

Rishikesh Kumar Rishi
817 Views
To plot a Cartesian coordinate system in matplotlib, we can take the following Steps −Initialize a variable (N) with a value.Create random data points for x and y.Plot the points using scatter method with x and y data points.To display the figure, use show() method.Exampleimport numpy as np import matplotlib.pyplot ... Read More

Rishikesh Kumar Rishi
10K+ Views
To plot multiple X or Y axis, we can use twinx() or twiny() methods, we can take the following Steps −Using subplots() method, create a figure and a set of subplots.Plot [1, 2, 3, 4, 5] data points on the left Y-axis scales.Using twinx() method, create a twin of Axes ... Read More

Rishikesh Kumar Rishi
941 Views
To get empty tick labels before showing a plot in matplotlib, we can take the following Steps −Create a list of data points.Add a subplot to the current figure using subplot() method.Set ticks and ticklabels using set_xticks() method and set_xticklabels() method.To get the empty tick labels, use get_xticklabels(which='minor').To display the ... Read More

Rishikesh Kumar Rishi
776 Views
Gaussian filtering an image with NaN values makes all the values of a matrix NaN, which produces an NaN valued matrix.StepsCreate a figure and a set of subplots.Create a matrix with NaN value in that matrix.Display the data as an image, i.e., on a 2D regular raster, data.Apply Gaussian filter ... Read More

Rishikesh Kumar Rishi
919 Views
To change the figsize for mathshow, we can use figsize in figure method argument and use fignum in matshow() method.StepsCreate a new figure or activate an existing figure using figure() method.Create a dataframe using Pandas.Use matshow() method to display an array as a matrix in a new figure window.The argument ... Read More

Rishikesh Kumar Rishi
16K+ Views
To change the font size of ticks of a colorbar, we can take the following steps−Create a random data set of 5☓5 dimension.Display the data as an image, i.e., on a 2D regular raster.Create a colorbar with a scalar mappable object image.Initialize a variable for fontsize to change the tick ... Read More

Rishikesh Kumar Rishi
2K+ Views
To modify the outline color of a node in networkx, we can use set_edgecolor() method.StepsCreate a Pandas dataframe with from and to keys.Return a graph from Pandas DataFrame containing an edge list.Get the position of the nodes.Draw the nodes of the graph using draw_networkx_nodes().Set the outline color of the nodes ... Read More

Rishikesh Kumar Rishi
5K+ Views
To set the number of ticks in a colorbar, we can take the following steps−Create random data using numpyDisplay the data as an image, i.e., on a 2D regular raster.Make a colorbar using colorbar() method with an image scalar mappable object.Set the ticks and tick labels of the colorbar using ... Read More

Rishikesh Kumar Rishi
3K+ Views
To plot data into imshow() with custom colormap in matplotlib, we can take the following steps−Set the figure size and adjust the padding between and around the subplots.Create random data points using numpy.Generate a colormap object from a list of colors.Display the data as an image, i.e., on a 2D ... Read More