Formulas question - Single vs multiple parts

Formulas question - Single vs multiple parts

by Claire Eiffel -
Number of replies: 12

Hi Dominque!   My name is Claire and I am an instructor at School College.  I teach Economics as well as Marketing that involves the use of Derivatives to manage price/delivery risk for Commodities in general.  

I'm not sure if I have the right person as I am trying to get some help with the Formulas Question type in Moodle.  

Are you the Lead Maintainer now as shown on the moodle info board?  If so I could sure use some help in sorting out how to setup the grading variables/criteria for multiple answer questions in the Formulas question format!

Thanks for considering my message!

Claire

Average of ratings: -
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Hello Claire,

Yes, I am now the lead maintainer, that is, until someone else wants to take the place. I will be happy to try to help you. Usually people post their question on the Moodle quiz forum [right here](https://moodle.org/mod/forum/view.php?id=737) so that it is useful to the whole community. I therefore invite you to do so. However, if you are uncomfortable doing so, I can respond privately.

Best regards,

Dominique
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Hi Dominique!  Thank you for your quick reply and for your offer to help!   My question setups could be a bit complex for the community but I don't mind asking/sharing there if you determine that it is the best place to share/get results! 

I have spent quite a bit of time setting up two different Formulas based questions with an Economic theme.  One is a table with 36 calculations while another is working off of a graph image.  

I have everything working perfectly (I think) except moodle will NOT grade the questions properly!   I was hoping to get moodle to generate scores out of the total possible (24/36, 32/36 etc) but it seems that it is either ALL or NONE!   I have watched a few videos and reviewed a few forums but I can't seem to find the right fix! 

The odd thing is that in the graph question - while in the preview mode - it marks the question perfectly BUT when I preview it and try the question in a practice quiz it is either all right or all wrong and nothing in between!   This just seems odd to me .... 

I don't quite understand how the grading variables and grading criterion work.  

I am trying to make this happen:

criterion1 = _0 == a;
criterion2 = _1 == b;
criterion3 = _2 == c;

0.3*criterion1 + 0.5*criterion2 + 0.2*criterion3

or

Ans1=_0;
Ans2=_1;
Ans3=_2;

(_relerr<1)*((_0==(dd-bb)/(cc-aa))*.1+(_1==dd/cc)*.2+(_2==ii/bb)*.7)

or
 
(_relerr<1)*((_0=Ans1)*.1+(_1=Ans2)*.2+(_2=Ans3)*.7)

I suspect it is something simple that I am overlooking.   (I hope)

Attached are a few files to help with figuring this out ...
  • moodle questions - quizzes/exams
  • moodle demo question - with just three calculation variables to manage - table setup
  • excel file to use as a key for the 36 question worksheet - or it can be used for the 3 question setup to evaluate the logic
I started these updates last fall - but then had to leave the fixes and do manual marking for these couple of questions on the exams!  Now I have a bit more time to try to figure out the exact fix! 

Thanks for considering this moodle Formulas question formatting issue!   If there is a friendly way to 'ask' about how to do this in the forum just let me know!  
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Hello Claire,

I will look at it this week.

Best regards,

Dominique
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Sounds GREAT! Much appreciated! I am looking forward to learning more about moodle coding and how to solve the question/grading issue!
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Hello Claire,

If you put all questions in the same Part, the score will always be either 0 or 1, unless you use a grading criterion. It may take a bit longer to set up, but I suggest that you put each question in its own part. This will give you a lot more flexibility.

Set quizzes in Adaptive mode which will allow students to answer one (or more) question at a time.

In your demo quiz, you can assign different weights to different parts and you won't need a grading criterion.

By the way, (_relerr<1)*(...) will make the score equal to either 0 or 1 because _relerr<1 is a Boolean which can only take a value of 0 or 1. Also, I'm not sure, but _relerr<1 probably means no error.

I also suggest that the answer is not "round(a,2)" but simply "a". On the other hand, the feedback, if there is one, should be "round(a,2)".

We can discuss this on Zoom if you wish.

Best regards,

Dominique
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Thank you for your comments and suggestions. Much appreciated. I would be interested in setting up/using the criterion technique since students compute all the values in that large table and then enter them into moodle.

Separate questions for each 'slot' would likely be cumbersome - especially with 36 'boxes' to fill in.

I have done this on the mini worksheet with only three calculations but I can't get moodle to grade each answer independently.

Grading Variables were set like this:

criterion1 = _0 == a;
criterion2 = _1 == b;
criterion3 = _2 == c;

Grading criterion were set like this:

0.5*criterion1 + 0.2*criterion2 + 0.3*criterion3

With this setup moodle seems to ONLY mark the first entry. YET - once and a while it will do 2/3 but it is not consistent via coding or changes.

Does the criterion setup look correct? I have attached the question below with the criterion setup.
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Claire,

I don't know your exact needs and don't mind helping you with the grading criterion but, in my opinion, you should consider placing each question in a separate part. Use the parts' placeholders {#1}, {#2}, etc. in the main question text to place each part in the table (by the way, try to clean up your code, you will benefit in the long run).

See the attached file for the demo question with separate parts.

It looks awfully long to set up 36 parts, but in fact it's just tedious and it will only take you ten minutes. You won't have to wrestle with the grading criterion, each answer will get its own correct answer green check mark or incorrect answer red cross, and you will easily assign different weights to the parts.

Dominique
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Hi WOW! I now understand what you mean by using the MAIN question setup for place holders vs the part area 1 that I was using! I'm excited to review your suggestions in detail and to investigate your file with the suggested edits!

THANKS for making time to help/share and be creative! I'll likely let you know tomorrow how these edits work!

With much thanks,

Claire
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Sounds good!

If you don't like the separate parts, we'll do the grading criterion, but again, in my opinion, separate parts will be easier and more flexible.
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Good morning Dominique! GREAT NEWS! Your suggestion to move the table to the main question area and then set up 'parts' worked perfectly!

I did not realize how the 'main question' set up worked in a formula based question! The videos that I watched suggested it was not needed and that a person could go right into 'part 1' to setup the question instead!

So - I have now moved the table up, re-coded the answer 'parts' and PRESTO .... it works perfectly!

** The only small glitch was that I had an extra 'part' and I wasn't sure how to delete it! eg I needed 12 but had 13 on the list ... is there an easy way to delete a 'part' of the formula question setup?

Again - THANKS for all the suggestions and for making time to demo a file on 'how to'!

cheers,

Claire
In reply to Claire Eiffel

Re: Formulas question - Single vs multiple parts

by Dominique Bauer -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Hello Claire,

Yes. To delete a part, you must blank the part, that is to say, clear all the fields of the part.

Can you tell me which video you watched?

Best regards,

Dominique
In reply to Dominique Bauer

Re: Formulas question - Single vs multiple parts

by Claire Eiffel -
Hi Dominique! Thank you again for all your suggestions and for your help! Lots and LOTS of great news here! I have been able to edit SEVERAL of my Formulas based questions to reflect what we discussed! The revisions are working perfectly!

HOW simple the edits were too! Sure - there was some repetitive editing but that worked just fine! I now have most of my practice quizzes and exam questions reworked and ready to go! So again - thank you!

** Regarding the deletion of the extra 'part' in the question - I figured what you suggested should work but moodle was doing otherwise! I had deleted everything (but maybe I missed one item) yet moodle kept giving me an error message! oh well! I simply added one more blank to fill in in the table for the practice quiz so no harm done at all ... and then proceeded carefully for the longer versions for the exams!

Regarding the video - here is the link: . At the 1:45-2:15 mark is where Dr Cormac Quigley discusses the use of the 'main question' area. His comments steered me away from using the main question area .... oops! Oh well!

Happy to help with more feedback and comments etc .... if needed!

With much appreciation,

Claire