Azzera filtri
Azzera filtri

MATLAB graders issues, i want to use one funtion from another problem

6 visualizzazioni (ultimi 30 giorni)
I am using MATLAB graders. In some assignments we want students to write a function which they will use in a following script. I can see where to add the functions file, but can't find it to include.

Risposta accettata

Cris LaPierre
Cris LaPierre il 18 Feb 2024
Modificato: Cris LaPierre il 18 Feb 2024
Each problem in MATLAB Grader is independent of the other problems. You can add external files to a problem for learners to use in their solutionk but it is not possible to link to their solution from a different problem.
I think the most robust approach here would be to have the students still write the function in one problem, but when it comes time to use the function in this problem, I would attach a p-coded function file. That way, the problem about the function can focus on assessing the function, and the problem that uses the function can focus on if it is used correctly knowing that the attached function file works correctly. This also allows learners who can't figure out how to create the function correctly to move on with the assignment.
If you truly want them to use their version of the function, then the only solution is to have your learners copy their function code and paste it in the new problem at the bottom of the script as a local funcion. See here.

Più risposte (0)

Categorie

Scopri di più su Entering Commands in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by