Create Formula Grade Items

You can use a formula grade item to define a formula that calculates a grade item’s value based on other grade items. When you create a formula, you specify which grade items you want included in the formula and the relationships between them. An example of a simple formula is one that calculates the sum of a number of grade items. A more complicated formula is one that drops the minimum or maximum value from a set of grade items.

The following limitations apply to formula grade items:

  • Formula grade items can belong to a category. The organization of text items within the category does not impact the calculation of the category those grades items are in. The totals off these categories do not contribute to the final grade.
  • Formula grade items do not contribute to the calculated final grade in a points-based or weighted-based grade book. You can only calculate the final grade with formula grade items using the Formula grading system.
  • All of the grade items you want to include in the formula grade item must be created before you create the formula item
  • Formula grade items cannot be associated with course objects such as Assignments, Discussions, and Quizzes. Only numeric grade items can be associated with course objects.
Formula Editor Grade Item

Features of the Formula Editor

Formula area

The formula area is where the formula text displays. The equals sign (=) at the start of the formula cannot be deleted. A cursor shows your position in the formula.

Cursor placement

Use the cursor placement icons to move the cursor forwards and backwards in the formula. You can also move the cursor by clicking on the new location with your mouse. There are four options:

  • << – Move cursor to start of formula
  • < – Move cursor back one element
  • > – Move cursor forward one element
  • >> – Move cursor to end of formula

Grade item parameters

To view what grade items you can insert as a parameter in your formula, use the Grade Item drop-down list. You can insert Numeric, Pass/Fail, Selectbox, and Formula  type grade items. You cannot reference the formula grade item you are defining or a final grade.

To view the values associated with the grade item you want to use in the formula, use the Grade Item Value drop-down list. There are three options:

  • Points Received – The grade the user achieved. For example, 7 (out of 10 points).
  • Max Points – The maximum points available for the grade item. For example, 10 points.
  • Percent –  The percent grade the user achieved. For example, 70%.

When using the weighted system, category and grade item weights are ignored in formula calculations.

Dropped grade items and bonus grade items are calculated the same as other grade items.

Functions

The Function drop-down list contains a list of functions that you can use in your calculation formula:

  • MAX – Calculates the maximum (largest) value in a set of values.
  • MIN – Calculates the minimum (smallest) value in a set of values.
  • SUM –  Calculates the sum (total) of a set of values.
  • AVG – Calculates the average for a set of values by adding all the values and dividing by the total number of values.
  • IF – Operates as a Boolean statement that returns either the value set as true or as false. You must define the condition (Boolean statement), true (then) value, and false (else) value.
  • NOT – Operates as a Boolean statement that returns the value set as true if the condition is false and as false if the condition is true.

You can embed functions within functions.

The Start, Next Term, and End  options are used to define elements of a function:

  • Start – Starts the function selected in the Function drop-down list with an opening bracket ({).
  • Next Term – Inserts a comma to separate grade items or parts of a Boolean statement.
  • End – Ends the function with a closing bracket (}).

Operators

Operators are usually used in conjunction with at least one grade item.


  1. On the nav bar, click the Assessment menu, then select Grades.
    Grades on Nav Bar
  2. Then click Manage Grades.
    Manage Grades
  3. Click the New button and select Item.
    New Grade Item
  4. Select Formula.
    Formula Grade Item
  5. Enter the grade item Name.
    Name
  6. (Optional) Enter a Short Name for the item if you’d like. The Short Name is only visible to users with access to the grade book.
    Short Name
  7. (Optional) Use the Category drop down menu to select a category if you’d like the grade item to belong to a category.
    Select Category Grade Item
  8. (Optional) Enter a Description if you’d like to share additional information about the grade item. Learn about how to use the HTML Editor to Format Course Content. By default, the Description field is collapsed, so you may need to click Show Description to expand it. Select whether or not to Allow users to view grade item description.
    grade item description
  9. Enter the Max Points possible for the grade item. If the grade item belongs to a category, this option may be grayed out depending on the category settings. To review and change the category settings you must edit the category.
    Max Points Numeric Grade
  10. (Use the Formula Editor to enter a formula for calculating the Points Received. This is how your students will be graded. Use the Validate and Preview buttons to determine the if the formula is valid and how the grades will appear for students. Click Insert when you are done creating the formula.
    Enter Formula
  11. Check the box under Can Exceed if students will have the option of earning more than the maximum points possible for this grade item.
    Can Exceed
  12. Use the Grade Scheme drop down menu to select a custom Grade Scheme if you have previously created one.
    Select Grade Scheme
  13. (Optional) Click the Add Rubric button to attach a rubric to the grade item. It is recommend that you create the rubric first in the Rubrics tool.
    Add Rubric to grade item
  14. (Optional) Override the system’s Display Options by checking the box next to the display option(s) you’d like the category to have. By default, Display Options is collapsed, so you may need to click Show Display Options to expand it. You can review the system’s Display Options by going to Course Display Options within Settings.
    numeric grade item display options
  15. Click one of the Save options at the bottom of the screen to save your changes:
    • Save and Close: Saves any changes and returns you to the Manage Grades screen.
    • Save and New: Saves any changes and allows you to begin creating a new grade item/category.
    • Save: Saves any changes and stays on the same screen.
    • Cancel: Delete grade item and return to the Manage Grades screen
      Save Options

Formula Editor Validation Errors

The following are errors you might encounter while using the Formula Editor.
ErrorDescriptionExamples
Unexpected [token_type]

For example, Unexpected operator
The formula contains a function component in an unexpected location = 5=/1
= (5+1)2

Unbalanced parenthesesThe formula contains an opening or closing bracket without a corresponding bracket5+1)
Missing end of functionThe formula contains an unclosed function= SUM{[Item1.Points], [Item2.Points]
Unexpected function endThe formula contains a closing bracket for a function that does not relate to a function= [Item1.Points]/2}
Invalid number of operator parametersThe formula contains an invalid number of operator parameters= [Item1.Points] +
Invalid number of function parameters The formula contains an invalid number of function parameters = SUM{}
= IF{[Item1.Points]<2,5}

Numeric value expectedA Boolean statement or operator was entered in place of a numeric value= IF{5<2,1 OR 1,4}
= SUM{1 = 2,3,4}

Boolean value expectedA Boolean statement was not entered for a condition IF {MIN{4,5},100,0}
= NOT{4}

Invalid terminalThe formula contains an incorrectly used terminal= [Item1.Points] + 3.2.5