Created
May 11, 2021 16:24
-
-
Save florisvanvugt/b48390ea1112a1823ae1dff907a68f0a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Source: https://fep.umontreal.ca/a-propos/enseigner-a-la-fep/pedagogie/evaluation-des-apprentissages/ | |
num2let <- data.frame( | |
seuil=c(0,.345,.495,.535,.565,.595,.645,.695,.725,.765,.795,.845,.895), | |
lettre=c('F','E','D','D+','C-','C','C+','B-','B','B+','A-','A','A+')) | |
findlet <- function(val) { | |
## Convert numeric grade into letter grade | |
if (is.na(val)) { return ("NA") } | |
selseuil <- max(subset(num2let,seuil<=val)$seuil) | |
return(num2let[ num2let$seuil==selseuil,'lettre'][[1]]) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment