Guys, sorry to miss this very interesting conversation, but I'll be out of town for work during the next week, and I should really be going to prepare the luggage right now! ;) My flight departs in 12 hours, and I should sleep a little bit as well.
Hopefully, I'll catch on this next week Enjoy!! Maurizio On 27 Feb, 21:05, Robert Bradshaw <rober...@math.washington.edu> wrote: > I do know that matplotlib works with dynamic backends, so I would > imagine it would be able to do the job without a constantly poling > the server. > > On Feb 27, 2009, at 11:59 AM, Kenny wrote: > > > > > I think I'm missing the point, is a canvas matplolib backend able to > > work > > as client side plotting render?? I've seen the @interact method and > > with it I > > was able to change the zoom level moving a slider, that is quite > > enough, > > but it has a drawback, every time you move the slider the client will > > request the > > server a new image, and it is quite slow. > > > Don't hesitate to reply even if you don’t agree with my position, If > > somebody > > will show me a simple way to have a client side matplotlib I will be > > happy to > > work on that! > > > On 27 Feb, 20:51, Robert Bradshaw <rober...@math.washington.edu> > > wrote: > >> On Feb 27, 2009, at 9:27 AM, Tom Boothby wrote: > > >>> In an ideal world, all graphics objects would have the ability to > >>> render themselves in FLOT. There are currently some issues with > >>> this: > > >>> 1) FLOT doesn't appear to be able to make shapes -- circles, > >>> polygons, etc. > >>> 2) Graphics objects have an additive structure: (circle + text + > >>> plot).show() works great for now > >>> 3) FLOT doesn't support logarithmic or polar plotting > > >> It would be nice if FLOT was used at a lower level (e.g. the > >> discussion of a matplotlib backend), that way everything that works > >> now will seemlessly work with FLOT too, rather than having to support > >> things one at a time. > > >>> The first thing I would do would be to add a FLOT rendering > >>> option to > >>> plot.show() -- this should be pretty easy, given my adaptation of > >>> your > >>> code in > > >>>http://groups.google.com/group/sage-devel/browse_thread/thread/ > >>> 91c424ccb670ed4b/2ffcf542cfeaeb64 > > >>> If you want to take a crack at it, Maurizio, I welcome you to. > >>> If you > >>> get stuck, drop me a line; if you give up, definitely tell me > >>> because > >>> I want to see this happen badly enough to write it myself. :) > > >>> On Fri, Feb 27, 2009 at 2:37 AM, Jason Grout > >>> <jason-s...@creativetrax.com> wrote: > > >>>> Maurizio wrote: > >>>>> I have another question. > >>>>> What do you think about the SAGE functions that are going to use > >>>>> FLOT? > > >>>> After we have an spkg, I think we should add a 'flot' option to the > >>>> viewer argument of the show command that would show the plot using > >>>> FLOT > >>>> if FLOT is installed. Is this the sort of thing that you are > >>>> thinking? > >>>> Then the user would be able to do: > > >>>> p=plot(x*sin(x), (x,-2,2)) > >>>> show(p, viewer='flot') > > >>>> and a FLOT chart would pop up. > > >>>> Jason > > >>>>> In my opinion, simply providing a FLOT spkg that adds the > >>>>> javascript, > >>>>> will not provide any additional feature to the users, because all > >>>>> the > >>>>> people that would have been capable to write the js powered > >>>>> functions > >>>>> from scratch wouldn't have been any problem in downloading and > >>>>> using > >>>>> manually the latest revision of FLOT (or FLOTR, or any other > >>>>> preferred > >>>>> js plot package). > > >>>>> On the contrary, if we start providing also, let's say, two simple > >>>>> FLOT powered plot SAGE functions, and do a little advertising > >>>>> on the > >>>>> wiki (for example), we will get much greater results in terms of > >>>>> user > >>>>> benefits, and even in long term support of the package, because > >>>>> many > >>>>> more people would be exposed to the usage of the basic functions, > >>>>> and > >>>>> there is a lot of people capable of writing complex SAGE plotting > >>>>> functions, that don't want to deal too much with writing > >>>>> javascript > >>>>> functions from scratch. > > >>>>> In fact, my enabler in this case has been the Kenny's experience > >>>>> with > >>>>> javascript and stuff, because I wouldn't be capable of doing > >>>>> this by > >>>>> myself (even though I already did the bode plot function for > >>>>> matplotlib). > > >>>>> What do you think? > > >>>>> In case you agree, we would really appreciate some feedback about > >>>>> how > >>>>> to speedup a bit the SAGE functions. > > >>>>> Regards > > >>>>> Maurizio > > >>>>> On 26 Feb, 11:56, Jason Grout <jason-s...@creativetrax.com> wrote: > >>>>>> Maurizio wrote: > >>>>>>> Hi all, > >>>>>>> as you know, Kenny and me recently worked on a notebook demo to > >>>>>>> show > >>>>>>> the possibility to include a javascript enhanced plot package > >>>>>>> (namely > >>>>>>> FLOT) into the SAGE notebook. > >>>>>>> The demo is currently hosted at:http://www.sagenb.org/pub/285/ > >>>>>>> As you can see, this is just a proof of concept. > >>>>>>> <b>Do any of you have suggestions about features that you would > >>>>>>> like > >>>>>>> to have in another demo? </b> If that can help in convincing the > >>>>>>> community to adopt this package, we would be available to > >>>>>>> produce > >>>>>>> another example notebook. > >>>>>>> Has anybody here ever worked on javascript and SAGE interaction > >>>>>>> code? > >>>>>>> We would appreciate some help. > >>>>>>> As you can see here: > >>>>>>>http://groups.google.com/group/sage-devel/browse_thread/thread/ > >>>>>>> 91c424... > >>>>>>> Some discussion already went on about this, and it seems that a > >>>>>>> lot of > >>>>>>> people have been positively impressed by the demo, so it seems > >>>>>>> reasonable to not let this chance to include this package to go > >>>>>>> away > >>>>>>> without any result. > >>>>>> I think the next step might be to make an optional spkg for > >>>>>> theflot > >>>>>> code. You can probably just take one of the existing javascript > >>>>>> spkgs > >>>>>> (say, the tinymce spkg or the jsmath spkg) and modify it > >>>>>> slightly by > >>>>>> puttingflotin the src/ directory and changing the > >>>>>> documentation. If > >>>>>> you are comfortable trying this, here are instructions: > > >>>>>> 1. Download the jsmath spkg > >>>>>> 2. Extract the spkg (you can do this with tar xjvf > >>>>>> jsmath-3.6a.p0.spkg) > >>>>>> 3. Change the directory name toflot-VERSION_NUMBER > >>>>>> 4. Change the code in the src directory and change the > >>>>>> directories > >>>>>> mentioned in the spkg-install file > >>>>>> 5. Change the documentation in the SPKG.txt file > >>>>>> 6. Delete the existing .hg directory in theflot-VERSION_NUMBER > >>>>>> directory to get rid of the repository for the jsmath spkg > >>>>>> 7. Create a new hg repository for theflotspkg by doing sage -hg > >>>>>> init > >>>>>> inside of theflot-VERSION_NUMBER directory > >>>>>> 8. commit the spkg-install and SPKG.txt files (do "sage -hg add > >>>>>> spkg-install" and "sage -hg add SPKG.txt", then "sage -hg > >>>>>> commit" and > >>>>>> type a brief message, like "initial version") > >>>>>> 6. do "sage -spkg DIRECTORY" > >>>>>> 7. post the resultingflot-VERSIONNUMBER.spkg > > >>>>>>> Please, note that the working demo has been developed in just > >>>>>>> few > >>>>>>> hours, and we are already working with it on a daily basis, > >>>>>>> so it > >>>>>>> seems pretty functional and stable, and it is also easy to > >>>>>>> maintain > >>>>>>> and further enhance. > >>>>>>> Anyway,FLOTis actively developed, so it could be a good idea to > >>>>>>> later contact its developers to take advantage of their help, > >>>>>>> or at > >>>>>>> least of their knowledge: > >>>>>>>http://groups.google.com/group/flot-graphs > >>>>>>> Regards > >>>>>>> Kenny and Maurizio --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---