thnx,
i did not know all about the sagehelp. but the ?? is a wonderfull feature.
I'll look at the code next, and i hope it helps me somehow.
gretz Johannes.
Am 04.07.2010 23:52, schrieb Justin C. Walker:
> Hi, Johannes,
>
> On Jul 4, 2010, at 07:24 , Johannes wrote:
>
>> i just tried to create a extended Version of LatticePolytope, but it did
>> not work.
>> I always get the following error:
>> Error when calling the metaclass bases function() argument 1 must be
>> code, not str.
>> i found out this is because LatticePolytope is not a class, but a
>> function.
>> otherwise, the type of LatticePolytope(somePoints) is given as:
>> sage.geometry.lattice_polytope.LatticePolytopeClass.
>> How can i extend this?
>> Where can i find informations about this class?
>
> I can't help with the details of the Lattice Polytope code, but this
> may help.  Since I'm not sure of your understanding of the Sage
> system, I'm not sure of how much you know, so this is basic info:
>
> In general, given a Sage (or Python) object 'x', typing 'x.[TAB]'
> (i.e., 'x.' followed by the TAB key) will give you a list of methods
> associated to 'x' (or to its type; also, not all listed items may be
> implemented for a given object).
>
> Also, typing "str[TAB]" will give you a list of all known (global)
> names beginning with "str".
>
> If you type something like "s1.polar?" (from your previous email),
> Sage will respond with whatever documentation is provided by the
> implementor of the "polar()" method for Lattice Polytopes.  With a
> double "??", you get documentation and possibly the code that
> implements it (if Sage can find it).  For this to work, "s1" must be
> the full name of an object, class, function, or method (sometimes
> 'str[tab]?' works wonders :-}).
>
> At the beginning of each of the latter output lists is a line
> beginning "File: ".  This line contains the full path to the source
> file where the code lives, so you can examine things like class
> definitions and function or method implementations.
>
> HTH
>
> Justin
>
> -- 
> Justin C. Walker, Curmudgeon at Large
> Institute for the Absorption of Federal Funds
> -----------
> My wife 'n kids 'n dogs are gone,
> I can't get Jesus on the phone,
> But Ol' Milwaukee's Best is my best friend.
> -----------
>
>

-- 
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to