Togglable input cells?

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Togglable input cells?

Benjamin Root-2
I am preparing for my tutorial for SciPy, and I want to avoid making a particular mistake I made last year, which was to have an exercise in the notebook for students to complete, but no "solution" available. I thought I would just type up the solution live, on-the-spot, but ended up making a complete fool of myself (it is all on YouTube, too...)

So, I was thinking of some sort of way to toggle an input cell that can reveal itself when I want to. I have seen some previous discussions on this topic, but I am not quite sure if they are what I am looking for. Note, I am completely clueless on how to add additional features, plugins, etc  to a notebook, and really am very bad at javascript. Of couse, I am open to other suggestions that others have done for their tutorials, so long as they are documented well, and is easy to distribute to students taking an introductory course.

Cheers!
Ben Root



_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Mark Voorhies-2
On 06/21/2014 03:46 PM, Benjamin Root wrote:

> I am preparing for my tutorial for SciPy, and I want to avoid making a
> particular mistake I made last year, which was to have an exercise in the
> notebook for students to complete, but no "solution" available. I thought I
> would just type up the solution live, on-the-spot, but ended up making a
> complete fool of myself (it is all on YouTube, too...)
>
> So, I was thinking of some sort of way to toggle an input cell that can
> reveal itself when I want to. I have seen some previous discussions on this
> topic, but I am not quite sure if they are what I am looking for. Note, I
> am completely clueless on how to add additional features, plugins, etc  to
> a notebook, and really am very bad at javascript. Of couse, I am open to
> other suggestions that others have done for their tutorials,

Low tech solution:
   Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
paste it in when you need it =)

--Mark

P.S. My experience is that if solutions to exercises are available (as
part of a distributed notebook, in slides, on the course website) at
least a few students will jump ahead rather than trying the exercise.
Not necessarily the end of the world, but it gets in the way of seeing
alternate solutions/etc...


so long as

> they are documented well, and is easy to distribute to students taking an
> introductory course.
>
> Cheers!
> Ben Root
>
>
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>


_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Aaron Meurer
My advice is to stay low tech. I tried a fancy thing
(ipython_doctester) at my scipy tutorial last year, and it was more
trouble than it was worth.

In this case, just make a separate notebook with solutions. The way I
do it is I make the solutions notebook and then when I am done I copy
it and clear out the answers.

Aaron Meurer

> On Jun 21, 2014, at 6:11 PM, Mark Voorhies <[hidden email]> wrote:
>
>> On 06/21/2014 03:46 PM, Benjamin Root wrote:
>> I am preparing for my tutorial for SciPy, and I want to avoid making a
>> particular mistake I made last year, which was to have an exercise in the
>> notebook for students to complete, but no "solution" available. I thought I
>> would just type up the solution live, on-the-spot, but ended up making a
>> complete fool of myself (it is all on YouTube, too...)
>>
>> So, I was thinking of some sort of way to toggle an input cell that can
>> reveal itself when I want to. I have seen some previous discussions on this
>> topic, but I am not quite sure if they are what I am looking for. Note, I
>> am completely clueless on how to add additional features, plugins, etc  to
>> a notebook, and really am very bad at javascript. Of couse, I am open to
>> other suggestions that others have done for their tutorials,
>
> Low tech solution:
>   Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
> paste it in when you need it =)
>
> --Mark
>
> P.S. My experience is that if solutions to exercises are available (as
> part of a distributed notebook, in slides, on the course website) at
> least a few students will jump ahead rather than trying the exercise.
> Not necessarily the end of the world, but it gets in the way of seeing
> alternate solutions/etc...
>
>
> so long as
>> they are documented well, and is easy to distribute to students taking an
>> introductory course.
>>
>> Cheers!
>> Ben Root
>>
>>
>>
>> _______________________________________________
>> IPython-dev mailing list
>> [hidden email]
>> http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev
_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Matthias Bussonnier
What about just having solution in a separate folder and just %load them ?

You can then just "publish" the folder at the end of tutorial, or even at beginning.

--
M


Le 22 juin 2014 à 01:29, Aaron Meurer a écrit :

> My advice is to stay low tech. I tried a fancy thing
> (ipython_doctester) at my scipy tutorial last year, and it was more
> trouble than it was worth.
>
> In this case, just make a separate notebook with solutions. The way I
> do it is I make the solutions notebook and then when I am done I copy
> it and clear out the answers.
>
> Aaron Meurer
>
>> On Jun 21, 2014, at 6:11 PM, Mark Voorhies <[hidden email]> wrote:
>>
>>> On 06/21/2014 03:46 PM, Benjamin Root wrote:
>>> I am preparing for my tutorial for SciPy, and I want to avoid making a
>>> particular mistake I made last year, which was to have an exercise in the
>>> notebook for students to complete, but no "solution" available. I thought I
>>> would just type up the solution live, on-the-spot, but ended up making a
>>> complete fool of myself (it is all on YouTube, too...)
>>>
>>> So, I was thinking of some sort of way to toggle an input cell that can
>>> reveal itself when I want to. I have seen some previous discussions on this
>>> topic, but I am not quite sure if they are what I am looking for. Note, I
>>> am completely clueless on how to add additional features, plugins, etc  to
>>> a notebook, and really am very bad at javascript. Of couse, I am open to
>>> other suggestions that others have done for their tutorials,
>>
>> Low tech solution:
>>  Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
>> paste it in when you need it =)
>>
>> --Mark
>>
>> P.S. My experience is that if solutions to exercises are available (as
>> part of a distributed notebook, in slides, on the course website) at
>> least a few students will jump ahead rather than trying the exercise.
>> Not necessarily the end of the world, but it gets in the way of seeing
>> alternate solutions/etc...
>>
>>
>> so long as
>>> they are documented well, and is easy to distribute to students taking an
>>> introductory course.
>>>
>>> Cheers!
>>> Ben Root
>>>
>>>
>>>
>>> _______________________________________________
>>> IPython-dev mailing list
>>> [hidden email]
>>> http://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>> _______________________________________________
>> IPython-dev mailing list
>> [hidden email]
>> http://mail.scipy.org/mailman/listinfo/ipython-dev
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev

_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Benjamin Root-2
Hmm, I rather like this idea. It lets me keep the solutions packaged with the tutorials (which helps students who aren't taking the class), but keeps them "out-of-sight, out-of-mind". For the %load, can I do relative paths?

Cheers!
Ben Root


On Sun, Jun 22, 2014 at 9:31 AM, Matthias Bussonnier <[hidden email]> wrote:
What about just having solution in a separate folder and just %load them ?

You can then just "publish" the folder at the end of tutorial, or even at beginning.

--
M


Le 22 juin 2014 à 01:29, Aaron Meurer a écrit :

> My advice is to stay low tech. I tried a fancy thing
> (ipython_doctester) at my scipy tutorial last year, and it was more
> trouble than it was worth.
>
> In this case, just make a separate notebook with solutions. The way I
> do it is I make the solutions notebook and then when I am done I copy
> it and clear out the answers.
>
> Aaron Meurer
>
>> On Jun 21, 2014, at 6:11 PM, Mark Voorhies <[hidden email]> wrote:
>>
>>> On 06/21/2014 03:46 PM, Benjamin Root wrote:
>>> I am preparing for my tutorial for SciPy, and I want to avoid making a
>>> particular mistake I made last year, which was to have an exercise in the
>>> notebook for students to complete, but no "solution" available. I thought I
>>> would just type up the solution live, on-the-spot, but ended up making a
>>> complete fool of myself (it is all on YouTube, too...)
>>>
>>> So, I was thinking of some sort of way to toggle an input cell that can
>>> reveal itself when I want to. I have seen some previous discussions on this
>>> topic, but I am not quite sure if they are what I am looking for. Note, I
>>> am completely clueless on how to add additional features, plugins, etc  to
>>> a notebook, and really am very bad at javascript. Of couse, I am open to
>>> other suggestions that others have done for their tutorials,
>>
>> Low tech solution:
>>  Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
>> paste it in when you need it =)
>>
>> --Mark
>>
>> P.S. My experience is that if solutions to exercises are available (as
>> part of a distributed notebook, in slides, on the course website) at
>> least a few students will jump ahead rather than trying the exercise.
>> Not necessarily the end of the world, but it gets in the way of seeing
>> alternate solutions/etc...
>>
>>
>> so long as
>>> they are documented well, and is easy to distribute to students taking an
>>> introductory course.
>>>
>>> Cheers!
>>> Ben Root
>>>
>>>
>>>
>>> _______________________________________________
>>> IPython-dev mailing list
>>> [hidden email]
>>> http://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>> _______________________________________________
>> IPython-dev mailing list
>> [hidden email]
>> http://mail.scipy.org/mailman/listinfo/ipython-dev
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev

_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev


_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Matthias Bussonnier

Le 22 juin 2014 à 17:39, Benjamin Root a écrit :

> Hmm, I rather like this idea. It lets me keep the solutions packaged with the tutorials (which helps students who aren't taking the class), but keeps them "out-of-sight, out-of-mind". For the %load, can I do relative paths?

WRT current kernel working directory, I think so.
You can even use URL.
--
M

>
> Cheers!
> Ben Root
>
>
> On Sun, Jun 22, 2014 at 9:31 AM, Matthias Bussonnier <[hidden email]> wrote:
> What about just having solution in a separate folder and just %load them ?
>
> You can then just "publish" the folder at the end of tutorial, or even at beginning.
>
> --
> M
>
>
> Le 22 juin 2014 à 01:29, Aaron Meurer a écrit :
>
> > My advice is to stay low tech. I tried a fancy thing
> > (ipython_doctester) at my scipy tutorial last year, and it was more
> > trouble than it was worth.
> >
> > In this case, just make a separate notebook with solutions. The way I
> > do it is I make the solutions notebook and then when I am done I copy
> > it and clear out the answers.
> >
> > Aaron Meurer
> >
> >> On Jun 21, 2014, at 6:11 PM, Mark Voorhies <[hidden email]> wrote:
> >>
> >>> On 06/21/2014 03:46 PM, Benjamin Root wrote:
> >>> I am preparing for my tutorial for SciPy, and I want to avoid making a
> >>> particular mistake I made last year, which was to have an exercise in the
> >>> notebook for students to complete, but no "solution" available. I thought I
> >>> would just type up the solution live, on-the-spot, but ended up making a
> >>> complete fool of myself (it is all on YouTube, too...)
> >>>
> >>> So, I was thinking of some sort of way to toggle an input cell that can
> >>> reveal itself when I want to. I have seen some previous discussions on this
> >>> topic, but I am not quite sure if they are what I am looking for. Note, I
> >>> am completely clueless on how to add additional features, plugins, etc  to
> >>> a notebook, and really am very bad at javascript. Of couse, I am open to
> >>> other suggestions that others have done for their tutorials,
> >>
> >> Low tech solution:
> >>  Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
> >> paste it in when you need it =)
> >>
> >> --Mark
> >>
> >> P.S. My experience is that if solutions to exercises are available (as
> >> part of a distributed notebook, in slides, on the course website) at
> >> least a few students will jump ahead rather than trying the exercise.
> >> Not necessarily the end of the world, but it gets in the way of seeing
> >> alternate solutions/etc...
> >>
> >>
> >> so long as
> >>> they are documented well, and is easy to distribute to students taking an
> >>> introductory course.
> >>>
> >>> Cheers!
> >>> Ben Root
> >>>
> >>>
> >>>
> >>> _______________________________________________
> >>> IPython-dev mailing list
> >>> [hidden email]
> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev
> >>
> >>
> >> _______________________________________________
> >> IPython-dev mailing list
> >> [hidden email]
> >> http://mail.scipy.org/mailman/listinfo/ipython-dev
> > _______________________________________________
> > IPython-dev mailing list
> > [hidden email]
> > http://mail.scipy.org/mailman/listinfo/ipython-dev
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev

_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev
Reply | Threaded
Open this post in threaded view
|

Re: Togglable input cells?

Jason Moore
We've used the %load solution for two tutorials now and it works pretty well. See here for examples: https://github.com/pydy/pydy-tutorial-pycon-2014, solutions are in the exercise_solutions directory. The main issue is that you can't "run all" to check whether the complete notebook runs because only the %load cell runs, not the output, so testing the complete notebooks requires lots of manual ctrl-entering.


Jason
moorepants.info
+01 530-601-9791


On Sun, Jun 22, 2014 at 11:57 AM, Matthias Bussonnier <[hidden email]> wrote:

Le 22 juin 2014 à 17:39, Benjamin Root a écrit :

> Hmm, I rather like this idea. It lets me keep the solutions packaged with the tutorials (which helps students who aren't taking the class), but keeps them "out-of-sight, out-of-mind". For the %load, can I do relative paths?

WRT current kernel working directory, I think so.
You can even use URL.
--
M

>
> Cheers!
> Ben Root
>
>
> On Sun, Jun 22, 2014 at 9:31 AM, Matthias Bussonnier <[hidden email]> wrote:
> What about just having solution in a separate folder and just %load them ?
>
> You can then just "publish" the folder at the end of tutorial, or even at beginning.
>
> --
> M
>
>
> Le 22 juin 2014 à 01:29, Aaron Meurer a écrit :
>
> > My advice is to stay low tech. I tried a fancy thing
> > (ipython_doctester) at my scipy tutorial last year, and it was more
> > trouble than it was worth.
> >
> > In this case, just make a separate notebook with solutions. The way I
> > do it is I make the solutions notebook and then when I am done I copy
> > it and clear out the answers.
> >
> > Aaron Meurer
> >
> >> On Jun 21, 2014, at 6:11 PM, Mark Voorhies <[hidden email]> wrote:
> >>
> >>> On 06/21/2014 03:46 PM, Benjamin Root wrote:
> >>> I am preparing for my tutorial for SciPy, and I want to avoid making a
> >>> particular mistake I made last year, which was to have an exercise in the
> >>> notebook for students to complete, but no "solution" available. I thought I
> >>> would just type up the solution live, on-the-spot, but ended up making a
> >>> complete fool of myself (it is all on YouTube, too...)
> >>>
> >>> So, I was thinking of some sort of way to toggle an input cell that can
> >>> reveal itself when I want to. I have seen some previous discussions on this
> >>> topic, but I am not quite sure if they are what I am looking for. Note, I
> >>> am completely clueless on how to add additional features, plugins, etc  to
> >>> a notebook, and really am very bad at javascript. Of couse, I am open to
> >>> other suggestions that others have done for their tutorials,
> >>
> >> Low tech solution:
> >>  Stage the "hidden" cell content elsewhere (e.g., an emacs buffer) and
> >> paste it in when you need it =)
> >>
> >> --Mark
> >>
> >> P.S. My experience is that if solutions to exercises are available (as
> >> part of a distributed notebook, in slides, on the course website) at
> >> least a few students will jump ahead rather than trying the exercise.
> >> Not necessarily the end of the world, but it gets in the way of seeing
> >> alternate solutions/etc...
> >>
> >>
> >> so long as
> >>> they are documented well, and is easy to distribute to students taking an
> >>> introductory course.
> >>>
> >>> Cheers!
> >>> Ben Root
> >>>
> >>>
> >>>
> >>> _______________________________________________
> >>> IPython-dev mailing list
> >>> [hidden email]
> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev
> >>
> >>
> >> _______________________________________________
> >> IPython-dev mailing list
> >> [hidden email]
> >> http://mail.scipy.org/mailman/listinfo/ipython-dev
> > _______________________________________________
> > IPython-dev mailing list
> > [hidden email]
> > http://mail.scipy.org/mailman/listinfo/ipython-dev
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>
> _______________________________________________
> IPython-dev mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-dev

_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev


_______________________________________________
IPython-dev mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-dev