[LON-CAPA-users] two different questions, randomly selected

Ray Batchelor lon-capa-users@mail.lon-capa.org
Sat, 17 Sep 2005 00:34:28 -0700


Hi David,
                  I am not an expert on this... but since everyone else is 
probably enjoying the weekend, I will give you some suggestions.
                  If you want to code a single resource for this then 
<randomlist> should work, however it might be a good idea to include the 
different response code inside <block> tags...to be safe.

e.g. (cryptically)

<randomlist show="1">
<block>
<startouttext />Some problem statement.<endouttext />
<numericalresponse> 
</numericalresponse
<block>
<block>
<startouttext />Some other problem statement.<endouttext />
<numericalresponse> 
</numericalresponse
<block>
<block>
<startouttext />Yet another problem statement.<endouttext />
<numericalresponse> 
</numericalresponse
<block>
</randomlist>

This basically works fine alhthough there may be one or two caveats.

e.g. note the ABSENCE of <part> tags in the above example.

***********************************************************************************

However, there is  a different, non-coding way to achieve a similar effect by 
using the "Randompick " option in DOCS.  This feature essentially randomly 
chooses resources to be un-hidden within a folder.

e.g. Create a "New Folder" in DOCS and import into it any number of problem 
resources. Go back  up to the containing folder.  
For the 'New Folder" y ou should see, over on the right just after the "URL 
hidden" check box, a field called  "Randomly Pick".
Enter "1" into that field and click "store".

You will now have a folder in which, for each sudent, all the resources are 
hidden except for one randomly chosen one.

While I have used <randomlist> a lot in coding problems I have only 
experimented a few times with the randompick method, but I believe it works 
OK.

Hope this is of some use.

Cheers,
Ray

On Friday 16 September 2005 18:52, David Grayson wrote:
> Hi!  I'd like some help.
>
> Suppose I have two homework problems which are quite different.  They
> have a different number of responses required, and they have different
> option choices.
>
> How can I make Lon-Capa randomly display only ONE of them?
>
> <conceptgroup> and <randomlist> do not work as I expected them to, and
> they are very poorly documented in the manual.  Is there are better
> manual somewhere that foxuses on the XML programming?
>
> --David Grayson
> _______________________________________________
> LON-CAPA-users mailing list
> LON-CAPA-users@mail.lon-capa.org
> http://mail.lon-capa.org/mailman/listinfo/lon-capa-users

-- 
Raymond J. Batchelor PhD
Department of Chemistry
Simon Fraser University
V5A 1S6