1
vote
2answers
52 views

matplotlib 3d plot with changing labels

So I have a 3d live-updating graph! it only shows one point at a time so I can easily track the motion of the point! But here is the problem: No matter what I seem to do, the point is always placed ...
1
vote
2answers
89 views

Drawing average line in histogram (matplotlib)

I am drawing a histogram using matplotlib in python, and would like to draw a line representing the average of the dataset, overlaid on the histogram as a dotted line (or maybe some other color would ...
0
votes
0answers
55 views

matplotlib remove automatic scaling of axis by addition

I have a problem with the (automatic) scaling of the x-axis in the following plot. I don't want the +1.599e-6 because it is just very difficult to read. Does anyone know how to remove that? ...
1
vote
2answers
208 views

How to make X axis in matplotlib/pylab to NOT sort automatically the values?

Whenever I plot, the X axis sorts automatically (for example, if i enter values 3, 2, 4, it will automatically sort the X axis from smaller to larger. How can I do it so the axis remains with the ...
1
vote
1answer
135 views

python matplotlib changing default axis for image

I am in an interesting situation. I have the diagram's image with axis So when I try to plot this diagram wiht the next code: plt.figure("Ti Zr") ax = plt.subplot(111) im = ...
3
votes
2answers
621 views

Matplotlib axis labels: how to find out where they will be located?

I have written a routine to draw vertical cross sections from atmospheric model output. An example is shown below. What I would like to do, is to show two vertical axes: on the left I display presure ...
4
votes
2answers
117 views

Matplotlib: Is it possible to create an new axis with a given y-offset, without creating subplot?

With the help of sankey-toolbox in Matplotlib, we can plot sankey-diagrams automaticly: The position of a sankey-object is automaticly calculated based on the position of its prior-object and cannot ...
0
votes
0answers
43 views

wxPython joystick axis move does not generate an event

My program needs to use joystick axes as an absolute input. The problem is that under linux(i'm using Fedora 16) the movement of the axes does not generate a joystick event. Also this sometimes can ...
1
vote
1answer
169 views

Pygame: Mouse Specific Axis Detection

How can I detect ONLY the X axis, for example? maus_x = 0 maus_y = 0 pygame.mouse.get_pos(maus_x, maus_y) while not done: for event in pygame.event.get(): if event.type == ...
1
vote
1answer
43 views

How can I change the font size of tixks of axes object in matplotlib

I have a figure I added subfigure to (inset). I have used: fig = plt.figure() ax = fig.add_subplot(111) subA = fig.add_axes([0.4,0.14,0.2,0.2]) I now want to change the xtick font size of the ...
4
votes
3answers
606 views

matplotlib; fractional powers of ten; scientific notation

I deal with simulation data and have been using matplotlib a lot lately and have been encountering something (a bug?) that's annoying. I have been allowing matplotlib to automatically set the tick ...
2
votes
2answers
190 views

python/matplotlib - Specifying Parasite Axis Length

I am plotting data from several sources and need multiple x axes, preferably offset such as those seen in the link. I would very much like my x axes to have variable length, allowing me to put many ...
3
votes
1answer
204 views

How to remove relative shift in matplotlib axis

When I try to do a plot against a range with big enough numbers I get an axis with relative shift for all the ticks. For example: plot([1000, 1001, 1002], [1, 2, 3]) I get these ticks on axis of ...
4
votes
1answer
1k views

Rescaling axis in Matplotlib imshow under unique function call

I have written a function module that takes the argument of two variables. To plot, I had x, y = pylab.ogrid[0.3:0.9:0.1, 0.:3.5:.5] z = np.zeros(shape=(np.shape(x)[0], np.shape(y)[1])) for i in ...
4
votes
1answer
86 views

How to generate a clean x and y axis for a numpy matrix?

I am creating a distance matrix in numpy, with an out put as such: ['H', 'B', 'D', 'A', 'I', 'C', 'F'] [[ 0. 2.4 6.1 3.2 5.2 3.9 7.1] [ 2.4 0. 4.1 1.2 3.2 1.9 5.1] [ 6.1 4.1 0. ...
0
votes
1answer
80 views

How to have multiple y axis on a line graph in Python

I want to make a line graph with multiple sets of data on the same graph. But they all scale differently so will need individual y axis scales. What code will put each variable on a separate axis? ...
5
votes
1answer
437 views

matplotlib animated plot wont update labels on axis using blit

I am plotting data in a plot using wxPython where the data limits on the y- axis are changing with the data. I would like to change the axis dynamically without redrawing the whole canvas like ...
1
vote
1answer
404 views

Python matplotlib interval

I'm using matplotlib in Python and I made a histogram with bars. Now when the histogram appears only the multiples of 5 appear on the x-axis and the multiples of 1000 appear on the y-axis. For the ...
1
vote
1answer
1k views

matplotlib how to start ticks leaving space from the axis origin

I need to plot non-numeric data against dates as a simple line graph. I am using matplotlib. Here's some sample code. import matplotlib.pyplot as plt xticks=['Jan','Feb','Mar','April','May'] ...
6
votes
1answer
390 views

How to plot with x-axis at the top of the figure?

I would like to ask how to produce a plot similar to that in the figure below? Basically, how to have x-axis at the top of the figure. Thanks Image from: ...
1
vote
1answer
1k views

Python and plot() : how to limit the number of x-axis ticks (labels)

I have two lists, same size, one is y_data and one is x_data x_data is a time hh:mm:ss during day, in fact each minute each serie is 1440 long. problem is : fig = Figure(figsize=(4,3)) a = ...
3
votes
1answer
2k views

Setting an axis in matplotlib

I'm producing a graph in matplotlib and I would like to set the x-axis between 0-10000 but I do not want to change the y axis I want the graph to do that on it's own. Right now both axis are ...
0
votes
1answer
226 views

Is it possible to make different-sized ticks for graphs?

Let's say that I have a graph an axis with 25 ticks, and I want to make every fifth tick (0, 5, 10, 15, 20, 25) bigger than the other ticks to make reading the graph easier. (There is already number ...
3
votes
3answers
1k views

How to add constant-spaced ticks on axes whose lenghts vary? [Python]

To simplify my problem (it's not exactly like that but I prefer simple answers to simple questions): I have several 2D maps that portray rectangular region areas. I'd like to add on the map axes and ...
1
vote
1answer
285 views

Displaying an inverted vertical date axis

The chart I'm trying to make is a 2D-array with date as its vertical dimension. By convention, the dates should increase from the top down. Displaying the date the other way around works fine with ...
20
votes
2answers
8k views

Secondary axis with twinx(): how to add to legend?

I have a plot with two y-axes, using twinx(). I also give labels to the lines, and want to show them with legend(), but I only succeed to get the labels of one axis in the legend: import numpy as np ...
4
votes
1answer
1k views

Matplotlib Unicode axis labels using the Cairo renderer

I'm trying to generate a plot using Matplotlib with a non-Latin character (a "μ") in an axis label, like this: matplotlib.pyplot.xlabel(u'Sarcomere Length (μm)') I'm using the Cairo renderer on ...
6
votes
2answers
709 views

Intelligently calculating chart tick positions

Whatever I'm using matplotlib, Open-Flash-Charts or other charts frameworks I always end needing to find a way to set x/y scales limits and intervals since builtins are not enough smart (or not at ...
1
vote
1answer
400 views

How to put the axis for two subplots separately?

I am trying to have two sub-plots in the figure in the Python Script. But I am not able to set the axis separately according to my inputs. Can anybody help me to set the x-axis, y-axis for each of ...
1
vote
1answer
5k views

Hiding Axis Labels

I'm trying to hide the axis labels on the first subplot at 211. I'd like to label the figure, not just a subplot (reference: "Isub Event Characteristics"). How can I control font properties like size, ...

1 2
15 30 50 per page