Alternative answer for a gapfill

7 views
Skip to first unread message

Martin Jones

unread,
Nov 25, 2022, 9:07:20 AM11/25/22
to Numbas Users
What is the purpose of the alternative answer in a gapfill type question? I was expecting to be able to enter alternative values for all the gaps, but this is not possible.

Scenario: students are entering a pair of coordinates. I would like to accept (x1,y1), (x2,y2) and also (x2,y2), (x1,y1) but not (x1,x2), (y1,y2), etc. What is the best way to achieve this?
n4.png
I guess a custom marking algorithm is needed. I notice that this contains an error in the alternative answer of a gapfill.
n5.png

Many thanks,
Martin

Martin Jones

unread,
Nov 25, 2022, 1:46:59 PM11/25/22
to Numbas Users
Quick follow-up. I have tried to use adaptive marking to achieve this instead. Please see https://numbas.mathcentre.ac.uk/question/133408/test-gapfill-with-alternative-answers/ for a basic example.

I have tried using the adaptive marking for the gapfill part type, and also on each individual gap. Nothing seems to give the result I want. Any suggestions would be welcome!

Martin

Christian Lawson-Perfect

unread,
Nov 28, 2022, 5:22:42 AM11/28/22
to numbas...@googlegroups.com
In general, alternative answers are for when you want to try marking the same answer with different part settings. The gap-fill part only really has one setting, "sort student's answers before marking", but you might also use it to try a different custom marking algorithm.

I think what you want to happen is best done with a custom marking algorithm: you could change the `gap_order` note in an alternative to mark the gaps in the order (x2,y2), (x1,y1). If the gaps are defined in the order x1,y1,x2,y2, you'd put this in a custom marking algorithm:

gap_order: [2,3,0,1]

I hope that helps!

--
You received this message because you are subscribed to the Google Groups "Numbas Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numbas-users...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/numbas-users/6bc40815-605c-410b-b7e7-a6864b5f7618n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages