[QTI] Rounding outcome variables
Niall Barr
n.barr at admin.gla.ac.uk
Tue Jul 29 16:36:59 BST 2008
Hi all,
I'm trying to fix the (very broken) Moodle QTIv2 item export, so that it
generates valid QTI items that behave exactly the same as the Moodle
items. One thing Moodle does is round scores to 2 decimal places, so
that a score made by adding three parts each with a value of 0.33333
becomes 1.
Is there a neat way of doinf this, or do I need to do something like
this at the end of responseProcessing?
<setOutcomeValue identifier="SCORE">
<divide>
<round>
<product>
<variable identifier="SCORE"/>
<baseValue baseType="float">100</baseValue>
</product>
</round>
<baseValue baseType="float">100</baseValue>
</divide>
</setOutcomeValue>
(Unfortunatly this doesn't work in either of the item players I'm using
- bits are unimplemented in APIS (though it should only take an hour or
so to fix that) and R2Q2 doesn't seem to calculate <product> correctly.)
Niall
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /public/ims-qti/attachments/20080729/1aeeb599/attachment.html
More information about the IMS-QTI
mailing list