Documentation / WirisQuizzes

  • Demos
  • Visit our website
  • Contact us
  • MathType

    • Wiris Quizzes

      • Learning Lemur

        • CalcMe

          • MathPlayer

            • Store FAQ

              • VPAT for the electronic documentation

                • MathFlow

                  • BF FAQ

                    • Home
                    • Wiris Quizzes
                    • Validation Options
                    • Grading functions
                    • Grading functions

                    Keep arguments as strings

                    Reading time: 1min

                    As mentioned in the previous section, it's possible to transfer all the assertions you can handle inside WirisQuizzes Studio to a grading function. You just need to select the Unevaluated option and use the corresponding notation.

                    Unfortunately, there is one exception regarding this transfer process. To track trailing zeros, the Precision assertion needs to transfer the student's answer as a string.

                    Thus, you will need to select the String in case you want to create a grading function where checking the number of significant figures or decimal places is required. Let's imagine, with a formative perspective, that we want only to accept answers with a random absolute error and between 2 and 4 significant figures.

                    The corresponding grading function will require the student's answer to satisfy the error condition to receive some grade, which will only be the full mark if it also has between 2 and 4 significant figures.

                    Tip

                    Notice there are two particularities regarding the notation in this type of grading function:

                    As the student's answer is transferred as a string, we need to evaluate it before comparing it with another value. We need to use the expression() command for this purpose.

                    The _check_precision() command requires four arguments: the student's answer, the minimum and maximum number of significant figures or decimal values the answer must have, and a boolean to indicate if we want to check significant figures (true) or decimal places (false). You can see more details here.

                    Thus, we will be able to answer with any value inside the acceptance interval between 2 and 4 significant figures.

                     

                    Was this article helpful?

                    Yes
                    No
                    Give feedback about this article

                    Related Articles

                    • Testing
                    • semantics/annotation/annotation-xml

                    Making people’s STEM work more meaningful

                    MathType

                    • MathType for Office Tools
                    • MathType for Mac
                    • MathType for Microsoft 365
                    • MathType for Google Workspace
                    • MathType for LMS
                    • MathType for XML Editors
                    • Arabic notation
                    • Our products accessibility
                    • MathType is online

                    WirisQuizzes

                    Learning Lemur

                    Solutions for Education

                    • Blackboard Learn
                    • Brightspace by D2L
                    • Canvas
                    • Google Classroom
                    • Moodle
                    • Schoology

                    Solutions for Publishing Houses

                    Solutions for Technical Writers

                    Solutions for Chemistry

                    Integrations

                    • HTML Editors
                    • MathType in WordPress

                    Pricing

                    Company

                    Careers

                    Blog

                    Contact Us

                    Buy Now

                    Plugin Downloads

                    © Wiris 2025

                    • Cookie Settings
                    • Cookie Policy
                    • Terms of Use
                    • Privacy Policy / GDPR
                    • Student Data Privacy
                    • Compliance
                    • Powered by Helpjuice
                    Expand