Hi, I've been playing a lot with interact recently -- I *really* like it. While attempting to develop a step-at-a-time example of Newton-Raphson, a couple of things came to mind.
1. What do you think about a control that saves state between interactions, but does not give you any visible control widgets? I know you can save state using globals, but if this works without too much trouble, it might be cleaner. In fact, I have an implementation now that seems to work, that allows things like: @interact def _( a = save_state(i=0), b = ['Go'] ): a.i += 1 print 'i=', a.i 'a' does not appear as an interactive widget. Every time you press 'Go' you get the next number. Only minor testing do far, so I don't know about all the repercusions... 2. What about a similar kind of thing, but gives you access to all the controls, so perhaps your function could change default values, reposition sliders, etc. Perhaps something like @interact def _ ( f = sin(x), range=(0..20), controls=interact_controls() ): ... controls['range'].set_value(...) The value of controls could be a dictionary indexed by variable name ... If this has any worth, I could attempt a proof-of-concept in a couple of days. cheers neal -- Neal Holtz http://www.docuweb.ca/~nholtz Dept. of Civil and Environmental Engineering, Carleton University, Ottawa, Ontario, Canada K1S 5B6. [EMAIL PROTECTED] Key: http://www.docuweb.ca/~nholtz/pubkey.asc --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---