Category "matplotlib"

Draw relation in matplotlib [closed]

I have a relation such as 'x^3 + y^3 + z^3 - c = 0'. c is constant and would be any number, and of course the equation may be changed. How can

How to plot data from UDP stream coming from F1 2019 game, my lineplot comes up blank

I have this below code in which I am getting data packets from UDP from the game. However, when running this code I am getting a blank plot, I want to plot Spee

Display count on top of seaborn barplot

I have a dataframe that looks like: User A B C ABC 100 121 OPEN BCD 200 255 CLOSE BCD 500 134 OPEN DEF 600 1

Python, Spherical Plot- Color Scaling

I'm pretty new with python. For the past two days I have been trying to figure out how to scale the color of a 3d plot (Antenna Radiation Pattern) with matplotl

SymmetricalLogLocator not working with Contourf in Matplotlib

I have data in which values are ranging from small negative values to positive 1000. Since the minimum and maximum differ by large scales, I first set locator a

FileNotFoundError: [Errno 2] No such file or directory: 'latex': 'latex' (Python 3.6 issue)

I'm trying to use the latex interpreter for figure labels. I generate my figures using the matplotlib library. I am having trouble finding an answer to this co

How to write combinations of English words and Greek letters in matplotlib?

import matplotlib.pyplot as plt import numpy as np x = np.array([tau for tau in range(365)]) y = np.random.normal(0,1, 365) plt.plot(x,y) plt.xlabel(r"$\tau$")

Changing axis label size in Seaborn catplot [duplicate]

I am trying to enlarge the x-axis labels (that is 'onshore', 'offshore', and 'solar'), along with rotating them. But whenever I increase the s

ValueError: hist method requires numerical columns, nothing to plot

I was going through a tutorial, but as I was running the code in an IDE, an error occurred. The link to the tutorial is here: https://thecleverprogrammer.com/20

matplotlib savefig of multiple subplots without displaying

I have an array of images which I have reshaped as size (28, 28, 3) of 100 images. I want to save the plot which the below code generates, but without display

Removing axis labels matplotlib

I have this image and I don't know how to remove the axis labels from the top and right hand side. I have tried: ax.spines['right'].set_visible(False) ax.s

Is there a way to show multiple continously moving dots on a 2D graph?

For my master thesis i am researching dqn behaviour by recreating a hunter and prey enviroment. This enviroment is 2D and should fit around 1000 dots that are c

How to add data labels to seaborn barplot? [duplicate]

I have the following code to produce a bar plot in seaborn import pandas as pd import matplotlib.pyplot as plt import seaborn as sns df = pd

Drawing zone over plt.imshow

I'm plotting some .tiff images using GDAL and matplotlib. Currently images look like the one in the example and I would like to mark a zone over the image.I hav

Input contains NaN, infinity or a value too large for dtype('float64') but i've manually changed Nan values in my database to equal 0

I've been having trouble with my regression formula. my dataset hasn't got any Nan values as I went through my database and replaced any blank cells with the va

Input contains NaN, infinity or a value too large for dtype('float64') but i've manually changed Nan values in my database to equal 0

I've been having trouble with my regression formula. my dataset hasn't got any Nan values as I went through my database and replaced any blank cells with the va

Pandas subplot date ticks appear unevenly spaced with irregular time series

I created this example after seeing the issue multiple times. This helped me realize that the problem comes when plotting the time series of a data frame with i

How to line plot timeseries data on a bar plot

I have the following data frame: data = {'date': ['3/24/2020', '3/25/2020', '3/26/2020', '3/27/2020'], 'Total1': [133731.9147, 141071.6383, -64629.74024

Minimum value of plt.pause()

I'm using matplotlib's pause function. https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.pause.html What is the range of the value which is acceptable

How can I draw a line in a python plot indicating 1 standard deviation?

I have a plot from a data frame, I want to to draw a line indicating one standard deviation from the mean like in the picture below. I know how to add text in