Skip to main content
Filter by
Sorted by
Tagged with
2 votes
0 answers
84 views

I’m trying to reproduce the classic HSV color cone matplotlib in Python. The idea is to draw a 3D cone in HSV space, with two triangular internal faces removed so we can see the inside of the cone. ...
PortorogasDS's user avatar
1 vote
0 answers
100 views

I'm trying to place the camera at a particular pose (given as a 4x4 transformation matrix) with the camera looking along the +ve z-axis in a Matplotlib 3D plot. There are a few reference poses and a ...
dibyendu's user avatar
  • 563
5 votes
1 answer
114 views

I'm trying to draw a curved FancyArrowPatch to annotate an angle in a 3D plot. How do I get the arrow to curve, stay in the plane of the two lines, and span the whole angle? Based on https://...
troy's user avatar
  • 51
0 votes
1 answer
97 views

I am trying to create a 3D surface plot similar to the one shown below. view of 3D surface plot with defined z-bounds and added contour lines I have been able to have some luck with the basic pyplot ...
Chance Bowman's user avatar
0 votes
1 answer
90 views

I am plotting families of orbits in python using matplotlib and the add_subplots() routine: fig=plt.figure() ax=fig.add_subplots(projection='3d') I then loop through my list of [X,Y,Z] series and ...
Albannach5446's user avatar
1 vote
1 answer
54 views

I have 3d vertex position data (x,y,z), scalar values at each vertex v, and vertex indices for each triangle tri. If I were to draw the surface geometry itself, I could use plot_trisurf. If I were to ...
Hojin Cho's user avatar
  • 498
0 votes
0 answers
45 views

I have an issue where the 3D axis limits set in Matplotlib are not respected in the plot, as shown by the minimal working example below. It can be seen that the extent of the plot goes beyond zero, ...
LordCat's user avatar
  • 528
0 votes
0 answers
55 views

I think my problem is fairly simple. I've managed to find a way to plot my 3D surface against a set of discrete data points, but the issue now is that it is not clear to see whether the points lie ...
James's user avatar
  • 1
1 vote
0 answers
69 views

Current this is my code for XY axis: import numpy as np import matplotlib.pyplot as plt def plot_with_tricontourf_customized(dfs, figures_organizer, figsize_setting, list_points_mean, ...
PTQuoc's user avatar
  • 1,093
0 votes
1 answer
75 views

I want to display the minor z ticks on an Axes3D plot without minor gridlines. The starting figure looks like this: The code is here: import numpy as np import matplotlib from matplotlib.figure ...
Python_Learner's user avatar
2 votes
2 answers
94 views

How do I turn off the major x axis grid from this axes? This code below works on 2d plots to hide the major x gridlines. On 3d plots it doesn't seem to do anything. I prefer to use general axes ...
Python_Learner's user avatar
0 votes
0 answers
28 views

I want to recreate figures like this by using Matplotlib, how would I do so? The second figure is hard to create using drawn lines; I'd like a helical spiral from the tip of the vector along z', so ...
codephantom's user avatar
0 votes
0 answers
53 views

I have latitude and longitude coordinates in UTM with some data associated with them in a .csv file. I want to make a 3d bar graph with the height's representing an area's associated data value. I ...
user29146195's user avatar
0 votes
0 answers
25 views

I am trying to plot a simple 3D surface (just for testing). It appears to me that the surface does not correspond with the data matrix (defined as the sum of two input vectors using the Numpy add....
Peter's user avatar
  • 1
0 votes
1 answer
57 views

The following code results in a figure saved with large white spaces around it, while there is enough space to stretch the axes. import matplotlib.pyplot as plt import numpy as np X = np.arange(-5, 5,...
Liris's user avatar
  • 1,546
1 vote
1 answer
135 views

I am trying to plot a two series of data in 3d as lines but cant find a good example of how to structure the data to do this in python. My example data is: x = np.array([[1,1,1,1,5,1,1,1,1], [4.5,5,5,...
Radika Moonesinghe's user avatar
1 vote
1 answer
101 views

I want to plot a sequence of three colormaps in a 3D space, with a line crossing all the planes of the colormaps, as shown in the figure below. https://i.sstatic.net/65yOib6B.png To do that, I am ...
Bruno Augusto Veloso's user avatar
0 votes
1 answer
88 views

Basically I have this code: import matplotlib.pyplot as plt import numpy as np from itertools import product, combinations fig = plt.figure() ax = fig.add_subplot(1,1,1,projection='3d') but that ...
Joan Venge's user avatar
  • 334k
1 vote
1 answer
117 views

I tried to replicate the following code to create 3D bar charts: https://pythonprogramming.net/3d-bar-chart-matplotlib-tutorial/ The idea behind the code below is to compute the Likelihood ratio of ...
Alan's user avatar
  • 171
0 votes
1 answer
68 views

ImportError: DLL load failed while importing _cext: The specified module could not be found. It says that it fails to import the matplotlib.pyplot as plt. I've checked the Matplotlib uninstalled and ...
Yopi's user avatar
  • 1
0 votes
1 answer
25 views

I want to plot a kind of torus in such a way: def flux2cart(RHO, PHI, THETA): XX = (R0 + DEL0*(1.0-RHO**2) + RHO*A0* np.cos(THETA) - RHO*A0*DELTA*np.sin(THETA)**2)*np.cos(PHI) YY ...
George's user avatar
  • 1
0 votes
1 answer
54 views

I'm trying to plot Cartopy tiles as a surface for my 3D scatter at z=0. To achieve this, I've created a 2D figure for the map data using the extents of my coordinates. The 2D figure looks correct. It ...
Charbel Abdallah's user avatar
0 votes
2 answers
70 views

I'm trying to set the scale of a plot to logarithmic, using the code below. When plotting without the log scale, it gives me a correct plot. for it, folder in enumerate(norm_folder_list): fig = ...
Entangled Being's user avatar
0 votes
0 answers
28 views

I am trying to animate in 3D an arm represented by 2 segments (3 points A, B and C of which I have 3D coordinates in a numpy array (shape (n,3))). Only the arm at instant t (between 0 and n) should be ...
Paul Dst's user avatar
0 votes
0 answers
52 views

I would like to plot a colorbar next to an image plotted with plot_surface in a 3d plot, such that the colorbar also rotates with the plot_surface image when the 3d axes are rotated. So far, my code ...
user avatar
1 vote
1 answer
43 views

I don't understand why the color of the regression plane is not the same. Here the code and output: import numpy as np import pandas as pandas import statsmodels.api as sm import matplotlib.pyplot as ...
Basir Touati's user avatar
0 votes
0 answers
76 views

After getting the 2D plot by using ax.view_init function like the following question: Rotate 3d plot to look like 2d plot (no perspective) How can I change and resize the photo with the same behavior ...
fpga's user avatar
  • 19
0 votes
1 answer
37 views

I'm answering module on image processing and I wanted to show how the values of a given 2D image change based on the intensity of the values of each pixel. The only thing is that I can't seem to ...
Ken Azurin's user avatar
0 votes
0 answers
34 views

I am following the 3D surface (colormap) from Matplotlib tutorial in order to plot $f(x,y)=(y-x)^2+x^{5}$. import matplotlib.pyplot as plt from matplotlib import cm from matplotlib.ticker import ...
Oromion's user avatar
  • 129
-1 votes
1 answer
35 views

I'm trying to scatter a dataset in 3D and for each point using a scalar variable as a color, to visualize better some phenomena. In order to keep things simple, suppose i want that each point plotted ...
user23885488's user avatar
0 votes
1 answer
172 views

I'm trying to make a 3d plot with python that shows an image at a certain level and certain specific points as a stem plot (basically the image is a sort of 2d map and the stem plots represent the ...
mmonti's user avatar
  • 316
1 vote
1 answer
309 views

Here to ask a question about the basic matplotlib 3d plotting tools. Now, let me make some dummy data to explain my issue: import numpy as np import matplotlib.pyplot as plt x = np.linspace(-1, 1, ...
mmonti's user avatar
  • 316
0 votes
1 answer
568 views

I grab this image from the matplotlib documentation page on "mplot3d View Angles": Based on the documentation, it seems that the method view_init() should have three arguments: elev (short ...
beginner's user avatar
0 votes
1 answer
140 views

I came to this problem when I tried to adjust the limits of the axis in the 3D animation. It seemed that the range of the limits on the screen is not what I want, but the output of the limits on the ...
beginner's user avatar
0 votes
1 answer
95 views

I am trying to plot this: https://100.datavizproject.com/data-type/viz4/ Using matplotlib. I have got this far: import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D import numpy as ...
ruthpozuelo's user avatar
0 votes
0 answers
57 views

I am trying to do the graph, but I want to shade the area below the graph to to reach the (x,y)--plane. So I just want shaded plane along the z-axis. On my plot I can see, that this 'shading' is just ...
blahblah's user avatar
0 votes
1 answer
173 views

I have attached a graph: This is a graph from excel I want to create the same graph using code in matplotlib. I checked online for 3d graphs but didn't get anything similar to this. This is the data ...
user avatar
2 votes
1 answer
7k views

When using matplotlib in jupyter notebook in VS code the Z-label of my 3D plot is cut off. I also used the example code from the official matplotlib documentation: import matplotlib.pyplot as plt ...
Tanne's user avatar
  • 131
0 votes
1 answer
61 views

I have a 3D matrix from simulating four random variables during 6 hours 2000 times: # Display the shape of the matrix_outputs array print(matrix_outputs.shape) (2000, 86400, 4) the first term is the ...
K. Rincon's user avatar
0 votes
1 answer
104 views

datadata.csv(Pandas DataFrame) Item Action Cost Item1 UK 100 Item2 USA 425 Item3 China 4587 Item4 USA 1234 Item5 China 1705 Item6 USA 870 Item7 China 1578 Item8 UK 3721 ...
Eric's user avatar
  • 1
0 votes
0 answers
261 views

I'm working on a project in C++ where I need to create a 3D graph to visualize and update real-time data. Initially, I attempted to use the matplotlibcpp library to draw the 3D graph, but I could not ...
Drad Wing's user avatar
4 votes
0 answers
236 views

Orthogonal Projection I can use the proj_type='ortho' argument to get an isometric projection which will use the following projection matrix: def _ortho_transformation(zfront, zback): # note: w ...
gewa's user avatar
  • 51
0 votes
1 answer
157 views

I want to plot the intensity over a sphere using plot_surface. The problem is, that it is not possible for me to normalize the color and to set the colobar correctly. All solutions I found in the ...
FilouUms's user avatar
1 vote
1 answer
54 views

When I adjust the position slider, for example pdfReader X,Y,Z, the point(pdfReader) in the plot won't be updated accordingly. Instead, I would see <Figure size 640x480 with 0 Axes> in my ...
user22773661's user avatar
0 votes
2 answers
716 views

I want to create/draw a 3D RGB Cube with possibility to rotate it. Something like this: I assumed that matplotlib would be a good option to create it, because it has built-in rotation function. I ...
rzymski's user avatar
-1 votes
1 answer
487 views

I am trying to draw a scene like in the picture below using Python matplotlib, but I got stuck on drawing the infinite line (the black & dotted one in the picture). In 2D, this line can be drawn ...
Matej's user avatar
  • 830
1 vote
1 answer
188 views

I'm currently doing a visualization task where I want to display a video within a 3D plot using matplotlib animation class. The purpose is to visualize feature tracking within the image. I have a ...
cody's user avatar
  • 11
0 votes
0 answers
23 views

I am trying to figure out how to make a tight box around my 3 plots to use it in a Latex document. I think it has to do with the 3d plots but I am not sure why this happens and what to do. #Load data ...
user296811's user avatar
2 votes
1 answer
88 views

I have a simple problem, wherein I have a training set of 80 points and a testing set of 20 points, which I am plotting against their corresponding values of bearing stress on the z axis, where the x ...
atharvanaik's user avatar
-1 votes
1 answer
510 views

import matplotlib.pyplot as plt from mpl_toolkits.basemap import Basemap import numpy as np plt.style.use('dark_background') fig = plt.figure() ax = plt.axes(projection='3d') x = np.arange(1,11) y = ...
doughstone's user avatar

1
2 3 4 5
8