Usage Arguments Details Value Examples
1 2 | get.grades(result, grades, thresholds, decay.gap = 86400 * 7,
decay.ratio = 0.2)
|
grades |
A named numeric vector. The name is the course name. The value is the grades associated with the course. |
decay.gap |
The duration of discounting the score if the student is late. Please see the details.
Specifying |
decay.ratio |
The amount of discounting of the score if the student is late. |
records |
The data from |
threshold |
A POSIXct vector. This is the deadline of the corresponding course / grades. |
If the student was late but he/she accomplished the course in decay.gap
seconds after the threshold timestamp,
then his/her score was multiplied by 1 - decay.ratio
.
The discount will become heavier and heavier until the ratio become 0 or less.
A data.frame whose column is:
student The classroom account of the student.
grades The total scores of the student.
comment The detailed score of the student.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | ## Not run:
# login first
records <- get.records()
result <- get.progress.table(records)
grades <- structure(c(0, 6, 0, 4, 0, 0, 6, 2, 2, 2, 2, 0, 4, 4, 4, 0, 6,
6, 3, 3, 3, 3), .Names = c("2017-NTUCSX:2nd-week", "2017-NTUCSX:2nd-week-hw",
"2017-NTUCSX:3rd-week", "2017-NTUCSX:3rd-week-hw", "DataScienceAndR:00-Hello-DataScienceAndR",
"DataScienceAndR:01-RBasic-01-Introduction", "DataScienceAndR:01-RBasic-02-Data-Structure-Vectors",
"DataScienceAndR:01-RBasic-03-Data-Structure-Object", "DataScienceAndR:01-RBasic-04-Factors",
"DataScienceAndR:01-RBasic-05-Arrays-Matrices", "DataScienceAndR:01-RBasic-06-List-DataFrame",
"DataScienceAndR:01-RBasic-07-Loading-Dataset", "DataScienceAndR:02-RDataEngineer-01-Parsing",
"DataScienceAndR:02-RDataEngineer-02-XML", "DataScienceAndR:02-RDataEngineer-03-JSON",
"DataScienceAndR:02-RDataEngineer-04-Database", "DataScienceAndR:02-RDataEngineer-05-Data-Manipulation",
"DataScienceAndR:02-RDataEngineer-06-Join", "DataScienceAndR:03-RVisualization-01-One-Variable-Visualization",
"DataScienceAndR:03-RVisualization-02-Multiple-Variables-Visualization",
"DataScienceAndR:03-RVisualization-03-ggplot2", "DataScienceAndR:03-RVisualization-04-Javascript-And-Maps"
))
thresholds <- c("2017-03-16 08:00:00", "2017-03-16 08:00:00", "2017-03-16 08:00:00",
"2017-03-23 08:00:00", "2017-03-16 08:00:00", "2017-03-16 08:00:00",
"2017-03-16 08:00:00", "2017-03-23 08:00:00", "2017-03-23 08:00:00",
"2017-03-23 08:00:00", "2017-03-23 08:00:00", "2017-03-16 08:00:00",
"2017-03-30 08:00:00", "2017-03-30 08:00:00", "2017-03-30 08:00:00",
"2017-03-16 08:00:00", "2017-04-06 08:00:00", "2017-04-06 08:00:00",
"2017-04-13 08:00:00", "2017-04-13 08:00:00", "2017-04-13 08:00:00",
"2017-04-13 08:00:00")
thresholds <- as.POSIXct(thresholds)
result.grades <- get.grades(result, grades, thresholds)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.