On 03/24/2010 11:57 PM, Rob Beezer wrote:
m.apply_map(), I believe off-hand.
That's it. Not sure why I didn't see that. Sorry for the noise.
Maybe because it started with "apply", which isn't exactly the most
obvious word when you are looking for this option. It would be nice to
make tab completion smarter (implement some of the suggestions that have
come up in the past) to make some variant of tab look for options that
have "map" in them, rather than just insisting that they start with "map"
I thought you could do:
sage: m=matrix()
sage: m.*map*?
and get a list of all methods that had "map" in them, but now I'm
getting a traceback on this (maybe because it is a Cython object?)
This works:
sage: p=plot(x,0,1)
sage: p.*color*?
p.axes_color
p.axes_label_color
p.tick_label_color
Here is the traceback for m.*map*?
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
/home/jason/sage/local/lib/python2.6/site-packages/IPython/OInspect.pyc
in psearch(self, pattern, ns_table, ns_search, ignore_case, show_all)
607 tmp_res = list(list_namespace(ns,type_pattern,filter,
608 ignore_case=ignore_case,
--> 609 show_all=show_all))
610 search_result.extend(tmp_res)
611 search_result.sort()
/home/jason/sage/local/lib/python2.6/site-packages/IPython/wildcard.pyc
in list_namespace(namespace, type_pattern, filter, ignore_case, show_all)
146 for name,obj in nsdict.iteritems():
147
ns=list_namespace(obj,type_pattern,".".join(pattern_list[1:]),
--> 148
ignore_case=ignore_case,show_all=show_all)
149 for inner_name,inner_obj in ns.iteritems():
150 res["%s.%s"%(name,inner_name)]=inner_obj
/home/jason/sage/local/lib/python2.6/site-packages/IPython/wildcard.pyc
in list_namespace(namespace, type_pattern, filter, ignore_case, show_all)
134 if len(pattern_list)==1:
135
ns=NameSpace(namespace,name_pattern=pattern_list[0],type_pattern=type_pattern,
--> 136 ignore_case=ignore_case,show_all=show_all)
137 return ns.ns
138 else:
/home/jason/sage/local/lib/python2.6/site-packages/IPython/wildcard.pyc
in __init__(self, obj, name_pattern, type_pattern, ignore_case, show_all)
90 # thing. In particular, Traits use this pattern
91 try:
---> 92 kv.append((key,getattr(obj,key)))
93 except AttributeError:
94 pass
/home/jason/sage/local/lib/python2.6/site-packages/sage/structure/element.so
in sage.structure.element.Element.__getattr__
(sage/structure/element.c:2743)()
/home/jason/sage/local/lib/python2.6/site-packages/sage/structure/parent.so
in sage.structure.parent.getattr_from_other_class
(sage/structure/parent.c:3066)()
TypeError: descriptor '__weakref__' for 'Objects.element_class' objects
doesn't apply to 'sage.matrix.matrix_integer_dense.Matrix_integer_dense'
object
--
You received this message because you are subscribed to the Google Groups
"sage-edu" group.
To post to this group, send email to sage-...@googlegroups.com.
To unsubscribe from this group, send email to
sage-edu+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/sage-edu?hl=en.