-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLT-Client.html
148 lines (105 loc) · 4.59 KB
/
LT-Client.html
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!-- Widget scripts -->
<style>
#helpText {
display: flex;
justify-content: space-around;
}
.left {
margin: 20px;
width: 400px;
}
.right {
margin: 20px;
width: 400px;
}
</style>
<link href='https://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'>
<script>
function timeStamp() {
var now = new Date();
var date = [ now.getFullYear(), now.getMonth() + 1, now.getDate() ];
if( date[1] < 10 ) {
date[1] = "0" + date[1];
}
return date.join("-");
}
$(window).load(function() {
analytics.ready(function() {
var userId = analytics.user().id();
$( ".highcharts-title").css("display", "none");
['https://code.highcharts.com/highcharts.js',
'https://code.highcharts.com/highcharts-more.js',
'https://idxmooc.ewi.tudelft.nl/precalc/getData?userId=' + userId + '¤tDate=' + timeStamp()
].forEach(function(src) {
var elem = document.getElementsByTagName('footer')[0];
var script = document.createElement('script');
script.src = src;
script.async = false;
elem.appendChild(script);
$( ".highcharts-title").css("display", "none");
});
$( ".highcharts-title").css("display", "none");
});
});
</script>
<!-- Content -->
<div id="wrapper-widget" style="display: none;">
<!--The text and divs before the Learning Tracker should be HERE-->
<h1>Learning Tracker</h1>
<p>
In order to help you become more aware of your habits as a learner, we have created the <b>Learning Tracker</b>. Each week, the information presented in the chart below will be updated to reflect your behavior in the course.
</p>
<p id="indiv-LT" style="display: none">
The <b>Learning Tracker</b> allows you to become more aware of your own behavior patterns as a learner. By having a better self-awareness and frequently reflecting on your learning behavior, you will increase your chances of reaching your goals and passing the course!
</p>
<p id="social-LT" style="display: none">
The <b>Learning Tracker</b> allows you to compare your behavior to that of your most successful peers---those who have earned a passing grade in the course before. If you try your best to match your behavior to theirs, you will increase your chances of reaching your goals and passing the course!
</p>
<p id="instruct-LT" style="display: none">
The <b>Learning Tracker</b> allows you to compare your behavior to the instructor's recommendations. By trying your best to match your behavior to how the instructor thinks you should take the course each week, you will increase your chances of reaching your goals and passing the course!
</p>
<!-- Do not remove the "container" div -->
<div id="container" style="width: 600px; height: 500px; margin: 0 auto;"></div>
<div id="helpText">
<h2>Key:</h2>
<div class="left">
<h4>Average Time per Week</h4>
<p>The average amount of time each week (in hours) that you spend in the Pre-University Calculus course.</p>
<h4>Revisited Video Lectures</h4>
<p>The number of video lectures that you have watched more than one time. Revisiting video lectures is effective in improving your memory.</p>
<h4>Forum Contributions</h4>
<p>The number of times you have contributed to the course discussion forum.</p>
</div>
<div class="right">
<h4>Quiz Questions Attempted</h4>
<p>The amount of quiz questions you have submitted a response to.</p>
<h4>Proportion of Time Spent on Quiz Questions</h4>
<p>How much time you spend answering quiz question comapred to other course activities.</p>
<h4>Timeliness of Quiz Question Submissions</h4>
<p>The amount of time (in days) ahead of the deadline you tend to submit quiz questions. The highher this value is, the better, as it shows that you're not procrastinating.</p>
</div>
</div>
</div>
<script>
var titleRemove = setInterval(function(){ if ($( ".highcharts-title").css("display") === "block") {
$( ".highcharts-title").css("display", "none");
} else if ($( ".highcharts-title").css("display") === "none") {
stopFunction();
}
}, 100);
function stopFunction() {
clearInterval(titleRemove);
}
setTimeout(textGen(), 5000)
function textGen() {
var userid = analytics.user()._getId();
if (userid % 4 == 0) {
} else if (userid % 4 == 1) {
$( "#indiv-LT" ).css('display', 'block');
} else if (userid % 4 == 2) {
$( "#social-LT" ).css('display', 'block');
} else if (userid % 4 == 3) {
$( "#instruct-LT" ).css('display', 'block');
}
}
</script>