MATLAB Grader

As of Fall 2022, we now have a MATLAB Grader Moodle plug in. I am using this for the first time this Fall, but here are some tips I have based on what I've experienced so far. These may need to change as we get more experience with this plugin.

Please see the MATLAB Grader Workshop I did in the Teaching & Learning Seminar: https://ncsu.zoom.us/rec/share/4BDu95mp8vL_rMYBR4ReGSuCv0_GaWuqkJjj2V_XmeBOGboOrONHDLoDOjW-sJ0s.pTVdI0MRKvZCfNPZ.

If you would like access to the Moodle Project Site from that seminar (you can try sample problems), please write me and I will add you to the course.

As of this writing, I recommend doing most of the set-up and problem drafting in MATLAB Grader, not Moodle.

 

Preliminary steps

  • First, I would explore some of the demo courses located here, to see the functionality and if this is right for you.
  • Make a MathWorks account if you don't already have one. Use your NCSU credentials.
  • Go to MATLAB Grader and ADD COURSE. If you are planning to use the Moodle plugin, then I believe only you will use this course. (This course is just for creating assignments. Your Moodle link will create its own course later.)

 

Creating a homework set in MATLAB Grader

  • In your MATLAB Grader course, Click ADD ASSIGNMENT. Give it a name. Caution: You will add problems one-a-at-time to Moodle, even if they all come from the same problem set. (I think! TBD...)
  • Now under the assignment, click ADD PROBLEM. (I recommend experimenting first with the "Getting Started with MATLAB Grader" problems.) Get it all set up the way you like, make sure the assessment works, etc.

 

Back in Moodle...

  • When you have problem ready to add to Moodle, go to your course Moodle, click + Add an activity or resource, then MATLAB Grader. Give the first problem a name, and decide under the Grade tab how many points it's worth and where in the gradebook the item should go.
  • Save and display.
  • Now find your folder where you wrote the problem, find the problem, and click COPY. (You are creating a new copy of the problem which will go into your LMS folder.)
  • Pro-tip: In the top right corner of Moodle, click the drop-down menu, then Switch role to... Student. This will give you the student's view of the problem.

 

 

Tips from Ilse:

Execution Model: https://www.mathworks.com/help/matlabgrader/ug/assessments-for-script-based-learner-solutions.html

Once the student (learner) submits a solution, Matlab grader first runs the reference solution and the student's solution, and only then does it run the Assessment to evaluate the student's solution.

We need to distinguish two environments:
1) Composing the problem in the MathWorks Matlab Grader cloud
2) Importing and possibly editing the problem in NCState Moodle

In the MathWorks Matlab Grader cloud:

  • Editing: If your usual keyboard shortcuts do not work, then on an Apple machine, you can use
    command C : copy
    command V: paste
    command X: cut
    command S: save
  • The Reference solution does not have to contain  the same code as the Learner Template. The Reference solution only needs to compute the relevant quantities, that is all. However, it should do it in the same way as you would want the student to do it, to ensure consistency.
  • The Reference solution does not need comments and it should not do any of the plotting or printing in the Learner Template.
  • You may want to develop the Learner Template first, and afterwards populate the Reference Solution with only the relevant computations. Then figure out what you want to put in the assessment.
  • In order to edit a problem that has been "saved as final", click the blue "Set to Draft" Box. Then do the edits, and click the blue box "Save as Final".


In the NCState Moodle Activity "Matlab Grader":

  • You may have to link to your personal MathWorks account to  access your course content in the MathWorks Matlab Grader cloud.
  • To edit a problem, click the blue "Set to Draft" Box. This edit will only change the file in NCState Moodle, but not the corresponding file in the MathWorks Matlab Grader cloud.