You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we're going to remove the idea of inconsequential differences as in #76, I think we should go all the way and even provide a grade_this_table() or grade_this_vector() function.
Following up with the comment #71 (comment) it would look something like
grade_this_table<-function(
expr,
correct="Message when correct",
incorrect="Message when incorrect",
...,
# all the arguments from tbl_grade_table() except object/expectedmax_diffs=3,
check_class=TRUE,
check_names=TRUE,
check_dimensions=TRUE,
check_groups=TRUE,
check_columns=TRUE,
check_column_class=check_columns,
check_column_values=check_columns
) {
# expr lets users add extra checks or grading code# ... prep check env and thingsfunction(check_env) {
grade_this({
# pass immediately if they're *exactly* the same
pass_if_equal(correct)
# check for problems with the table
tbl_grade_table(
# fill in values from grade_this_table()
)
# evaluate extra checks in `expr` here# finally, fail()
fail(incorrect)
})
}
}
The text was updated successfully, but these errors were encountered:
If we're going to remove the idea of inconsequential differences as in #76, I think we should go all the way and even provide a
grade_this_table()
orgrade_this_vector()
function.Following up with the comment #71 (comment) it would look something like
The text was updated successfully, but these errors were encountered: