.yaxis.get_major_ticks():
tick.label1.set_color('blue')
# does not work (tick labels are not red):
for tick in ax2.yaxis.get_major_ticks():
tick.label1.set_color('red')
pp.show()
--
Christopher Brown, Ph.D.
Associate Research Professor
Department of Speech and Hearing Science
Arizona S
Hi Ben, Eric and Paul,
Paul's partial solution is actually exactly what I need. Thanks!
-Chris
On Friday, August 12, 2011 07:26:22 PM Benjamin Root wrote:
> On Friday, August 12, 2011, Christopher Brown wrote:
> > Thanks Ben,
> >
> > I should have been more clear. I
be misunderstanding
something.
-Chris
On Friday, August 12, 2011 05:57:17 PM Benjamin Root wrote:
> Yes, you are making it harder on yourself...
>
> On Friday, August 12, 2011, Christopher Brown wrote:
> > I feel like I'm doing this right, but it doesn't work.
ost recent call last):
File "", line 1, in
File "C:\Python27\lib\site-packages\matplotlib\figure.py", line 606,
in add_axes
assert(a.get_figure() is self)
AssertionError
--
Christopher Brown, Ph.D.
Associate Research Professor
Department of Speech and Hearing S
svg", transparent=True)
'''
ax.patch.set_facecolor(color)
lh = ax.get_legend()
if lh != None:
lh.legendPatch.set_facecolor(color)
--
Christopher Brown, Ph.D.
Associate Research Professor
Depa
ax2.set_xscale('log')
ax1.annotate("", (1,-30), (2000,-30),
arrowprops=dict(arrowstyle="-|>",fc="b", ec="b"))
ax2.annotate("", (100, 5), (2000, 5),
arrowprops=dict(arrowstyle="-|>",fc="
Hi List,
How can I change the (fore)color of a figure title (pp.title('Wow!'))
after it has been added to the figure? I can do this with axes labels
like this:
pp.gca().axes.xaxis.label.set_color(color)
--
Christopher Brown, Ph.D.
Associate Research Professor
Department of Speech a
>
> also, see this example,
>
> http://matplotlib.sourceforge.net/examples/pylab_examples/spine_placement_demo.html#pylab-examples-spine-placement-demo
>
> Regards,
>
> -JJ
>
>
>
> On Tue, Aug 18, 2009 at 5:18 PM, Christopher Brown wrote:
>> I have asked this question
I have asked this question before. How do I set the linewidth of the
axis frame? Long ago, I used gca().get_frame().set_linewidth(2). More
recently, I used gca().frame.set_linewidth(2), but this doesn't seem to
work anymore. I've tried gca().patch, to no avail. Any suggestions?
Thanks.
---
ld be more like how Matlab figures behave. Although they popup to the
foreground, you can continue typing and focus is correctly applied to
the console.
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizo
(self.figure.axes[0].bbox.width)
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona State University
--
___
Matplotlib-users mailing list
Matplotlib-users
= "X is: " + str(mouseevent.xdata) + "\nY is: " +
str(mouseevent.ydata)
QMessageBox.information(self, "Click!", msg)
I got some good tips on how to do this from
examples/event_handling/pick_event_demo.py
--
Christopher Bro
t from 3.3 mb to 84 kb. This was
an incredibly timely tip too, because I was just about to go to print
with my poster, which I did in Scribus, which would hang on the 3-4 mb
pdf figure. I was about to go to png, but now I don't have to. Thanks.
--
Christopher Brown, Ph.D.
Department of
toscale_on(False)) in case the user has zoomed.
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona State University
--
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco
same scripts were
working before, but adding draw() now does the trick.
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona State University
--
Create and Deploy Rich Internet Apps outside the browser
t_markeredgewidth(2)
...and I also can get invert_yaxis() (or xaxis) to work either.
I'm on windows, using 0.98.5, ang Qt4Agg backend. I get no warnings or
errors. Does anyone have any ideas?
--
Christopher Brown, Ph.D.
Department of Speech and Heari
Hi Michael,
MH> The Axes object has a method for turning on the frame:
MH> set_frame_on(). How do I set the thickness of the frame that
MH> appears?
I use:
plt.gca().get_frame().set_linewidth(2)
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona State U
.x0+bbox.width/2. # center
JL>
JL> ax.text(x, 0, "test", va="bottom", ha="center",
JL> transform=ax.transAxes) plt.draw()
JL> -
JL>
JL> Note that if you want save the figure, you need to save it with a
JL> same dpi, or save the f
Hi,
How can I get the position, in x coordinates/units, of the legend?
Specifically, I'd like to get the center of the legend box, because I
want to add some text that is centered-aligned with the legend. Thanks.
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Ar
a
JL> axes background.
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona State University
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based appl
y the
get_frame().set_linewidth() command stopped working, and only the ticks
are getting updated.
In [5]: matplotlib.__version__
Out[5]: '0.98.3'
In [6]: os.name
Out[6]: 'nt'
Any ideas about what I'm doing wrong?
--
Christopher Brown, Ph.D.
Department of Speech and
Hi Jae-Joon,
JL> I just had a quick look at this problem. And I'm posting a quick
JL> solution in case Christoper haven't dig it yet.
My figure looks great with these changes. Thank you very much!
--
Christopher Brown, Ph.D.
Department of Speech and Hearing Science
Arizona
Hi Users,
What is the best way to add a subscript to a tick label using the
default font?
--
Chris
-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/M
> This shouldn't happen if the font metrics are correct, since the
> label gets the bounding box of the tick labels and adjusts itself
> correctly.
This behavior is causing a problem for me. I have two figures with
different sets of yticklabels (100 vs 1000), and the ylabels are in
different
Hi Johann,
try:
a,b = ylim()
> I have a function, which I am plotting. I want to add a line positioned
> at, say, the mean of the function, so I want to do plot([x,x],[y0,y1]).
> In order to get y0, and y1, my brute force trial and error browsing of
> the API lead me to :
> y0=gca().yaxis.get_m
Hi John,
JH> or you can manually change this with
JH>
JH> fig.subplots_adjust(bottom=0.2)
Aha! I had been using rc('figure.subplot', bottom=0.2), but I was
looking for a better way. Thanks!
--
Chris
-
This SF.net email is
Hi Jouni,
JKS> Try setting the pdf.fonttype parameter in your matplotlibrc file to
JKS> 42 and see if the resulting file passes validation. Matplotlib
This produces a good-looking pdf. Unfortunately, It'll be a few weeks
before I can test it with the online figure check program, since the
that
Hi List,
I recently subjected some figures to an online 'quality analysis' done
by a journal I am submitting a paper to. The analysis stated that my
figures (created with mpl's pdf backend, and using whatever default
fonts are used) used type 3 fonts, and that I should use type 1 whenever
poss
Hi List,
I find the attached patch useful. It adds an argument (elinewidth) to
the errorbar function which is a linewidth analog to the ecolor
argument. It allows you to specify a linewidth for the errorbars, so
that it can be different from the plot linewidth. This is useful to me
because I
Hi Mike,
Your test pdf shows up properly in Foxit.
MD> So --- this would appear to be a bug in Foxit. Perhaps you could
MD> submit this problematic PDF to them.
I will do so, and I'll also include your description of the problem.
--
Chris
--
Hi mpl users,
I have noticed that when making a figure using the errorbar function, a
cap line will show up over a marker if they happen to fall on top of one
another. The line connecting the caps is (properly) hidden under the
marker. This behavior only occurs if the overlapping marker was pla
Hi Michael,
MD> I can't be of much help with Windows builds, unfortunately.
MD> However, for clarification, is this error from building pycairo or
MD> matplotlib? matplotlib *should* be able to bypass pkg-config if it
MD> isn't available.
The error occurred while building pycairo.
MD> > will
sing the wxagg backend, which yields the
same result (markeredgewidth is always 1 when viewing with foxit). I
will create a figure tonight from home (kubuntu) using the cairo
backend, then examine it tomorrow at work (windows/foxit) and report back.
--
Christopher Brown, Ph.D.
Department o
Christopher Brown wrote:
> With mpl 0.91.2, the markeredgewidth property does not seem to have an
> effect when using the pdf backend (seems to always be 1, regardless of
> what I set it to, and it seems to be fine with other backends). Here is
> a minimal example:
Interestingl
Hi List,
With mpl 0.91.2, the markeredgewidth property does not seem to have an
effect when using the pdf backend (seems to always be 1, regardless of
what I set it to, and it seems to be fine with other backends). Here is
a minimal example:
from matplotlib import use
#use('pdf') # <- Uncommen
Hi Brook,
FG> Can you give me a simple example to show how to set the figure's
FG> interactive property to on? I appreciate!
>>> import pylab
>>> pylab.ion()
--
Chris
-
This SF.net email is sponsored by: Microsoft
Defy a
Hi,
> Hi Mike,thanks for your reply. I tried f=figure() and pylab.close(f),
> but the figure can not be closed automatically. Seems that
> time.sleep(3) doesn't be called until I close the figure manually.
Maybe try setting the figure's interactive property to on?
--
Chris
---
37 matches
Mail list logo