forked from rdpeng/RepData_PeerAssessment1
-
Notifications
You must be signed in to change notification settings - Fork 0
/
PA1.html
339 lines (252 loc) · 47.8 KB
/
PA1.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
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
<!DOCTYPE html>
<!-- saved from url=(0014)about:internet -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta http-equiv="x-ua-compatible" content="IE=9" >
<title>Reproducible Research: Peer Assessment 1</title>
<style type="text/css">
body, td {
font-family: sans-serif;
background-color: white;
font-size: 12px;
margin: 8px;
}
tt, code, pre {
font-family: 'DejaVu Sans Mono', 'Droid Sans Mono', 'Lucida Console', Consolas, Monaco, monospace;
}
h1 {
font-size:2.2em;
}
h2 {
font-size:1.8em;
}
h3 {
font-size:1.4em;
}
h4 {
font-size:1.0em;
}
h5 {
font-size:0.9em;
}
h6 {
font-size:0.8em;
}
a:visited {
color: rgb(50%, 0%, 50%);
}
pre {
margin-top: 0;
max-width: 95%;
border: 1px solid #ccc;
white-space: pre-wrap;
}
pre code {
display: block; padding: 0.5em;
}
code.r, code.cpp {
background-color: #F8F8F8;
}
table, td, th {
border: none;
}
blockquote {
color:#666666;
margin:0;
padding-left: 1em;
border-left: 0.5em #EEE solid;
}
hr {
height: 0px;
border-bottom: none;
border-top-width: thin;
border-top-style: dotted;
border-top-color: #999999;
}
@media print {
* {
background: transparent !important;
color: black !important;
filter:none !important;
-ms-filter: none !important;
}
body {
font-size:12pt;
max-width:100%;
}
a, a:visited {
text-decoration: underline;
}
hr {
visibility: hidden;
page-break-before: always;
}
pre, blockquote {
padding-right: 1em;
page-break-inside: avoid;
}
tr, img {
page-break-inside: avoid;
}
img {
max-width: 100% !important;
}
@page :left {
margin: 15mm 20mm 15mm 10mm;
}
@page :right {
margin: 15mm 10mm 15mm 20mm;
}
p, h2, h3 {
orphans: 3; widows: 3;
}
h2, h3 {
page-break-after: avoid;
}
}
</style>
<!-- Styles for R syntax highlighter -->
<style type="text/css">
pre .operator,
pre .paren {
color: rgb(104, 118, 135)
}
pre .literal {
color: rgb(88, 72, 246)
}
pre .number {
color: rgb(0, 0, 205);
}
pre .comment {
color: rgb(76, 136, 107);
}
pre .keyword {
color: rgb(0, 0, 255);
}
pre .identifier {
color: rgb(0, 0, 0);
}
pre .string {
color: rgb(3, 106, 7);
}
</style>
<!-- R syntax highlighter -->
<script type="text/javascript">
var hljs=new function(){function m(p){return p.replace(/&/gm,"&").replace(/</gm,"<")}function f(r,q,p){return RegExp(q,"m"+(r.cI?"i":"")+(p?"g":""))}function b(r){for(var p=0;p<r.childNodes.length;p++){var q=r.childNodes[p];if(q.nodeName=="CODE"){return q}if(!(q.nodeType==3&&q.nodeValue.match(/\s+/))){break}}}function h(t,s){var p="";for(var r=0;r<t.childNodes.length;r++){if(t.childNodes[r].nodeType==3){var q=t.childNodes[r].nodeValue;if(s){q=q.replace(/\n/g,"")}p+=q}else{if(t.childNodes[r].nodeName=="BR"){p+="\n"}else{p+=h(t.childNodes[r])}}}if(/MSIE [678]/.test(navigator.userAgent)){p=p.replace(/\r/g,"\n")}return p}function a(s){var r=s.className.split(/\s+/);r=r.concat(s.parentNode.className.split(/\s+/));for(var q=0;q<r.length;q++){var p=r[q].replace(/^language-/,"");if(e[p]){return p}}}function c(q){var p=[];(function(s,t){for(var r=0;r<s.childNodes.length;r++){if(s.childNodes[r].nodeType==3){t+=s.childNodes[r].nodeValue.length}else{if(s.childNodes[r].nodeName=="BR"){t+=1}else{if(s.childNodes[r].nodeType==1){p.push({event:"start",offset:t,node:s.childNodes[r]});t=arguments.callee(s.childNodes[r],t);p.push({event:"stop",offset:t,node:s.childNodes[r]})}}}}return t})(q,0);return p}function k(y,w,x){var q=0;var z="";var s=[];function u(){if(y.length&&w.length){if(y[0].offset!=w[0].offset){return(y[0].offset<w[0].offset)?y:w}else{return w[0].event=="start"?y:w}}else{return y.length?y:w}}function t(D){var A="<"+D.nodeName.toLowerCase();for(var B=0;B<D.attributes.length;B++){var C=D.attributes[B];A+=" "+C.nodeName.toLowerCase();if(C.value!==undefined&&C.value!==false&&C.value!==null){A+='="'+m(C.value)+'"'}}return A+">"}while(y.length||w.length){var v=u().splice(0,1)[0];z+=m(x.substr(q,v.offset-q));q=v.offset;if(v.event=="start"){z+=t(v.node);s.push(v.node)}else{if(v.event=="stop"){var p,r=s.length;do{r--;p=s[r];z+=("</"+p.nodeName.toLowerCase()+">")}while(p!=v.node);s.splice(r,1);while(r<s.length){z+=t(s[r]);r++}}}}return z+m(x.substr(q))}function j(){function q(x,y,v){if(x.compiled){return}var u;var s=[];if(x.k){x.lR=f(y,x.l||hljs.IR,true);for(var w in x.k){if(!x.k.hasOwnProperty(w)){continue}if(x.k[w] instanceof Object){u=x.k[w]}else{u=x.k;w="keyword"}for(var r in u){if(!u.hasOwnProperty(r)){continue}x.k[r]=[w,u[r]];s.push(r)}}}if(!v){if(x.bWK){x.b="\\b("+s.join("|")+")\\s"}x.bR=f(y,x.b?x.b:"\\B|\\b");if(!x.e&&!x.eW){x.e="\\B|\\b"}if(x.e){x.eR=f(y,x.e)}}if(x.i){x.iR=f(y,x.i)}if(x.r===undefined){x.r=1}if(!x.c){x.c=[]}x.compiled=true;for(var t=0;t<x.c.length;t++){if(x.c[t]=="self"){x.c[t]=x}q(x.c[t],y,false)}if(x.starts){q(x.starts,y,false)}}for(var p in e){if(!e.hasOwnProperty(p)){continue}q(e[p].dM,e[p],true)}}function d(B,C){if(!j.called){j();j.called=true}function q(r,M){for(var L=0;L<M.c.length;L++){if((M.c[L].bR.exec(r)||[null])[0]==r){return M.c[L]}}}function v(L,r){if(D[L].e&&D[L].eR.test(r)){return 1}if(D[L].eW){var M=v(L-1,r);return M?M+1:0}return 0}function w(r,L){return L.i&&L.iR.test(r)}function K(N,O){var M=[];for(var L=0;L<N.c.length;L++){M.push(N.c[L].b)}var r=D.length-1;do{if(D[r].e){M.push(D[r].e)}r--}while(D[r+1].eW);if(N.i){M.push(N.i)}return f(O,M.join("|"),true)}function p(M,L){var N=D[D.length-1];if(!N.t){N.t=K(N,E)}N.t.lastIndex=L;var r=N.t.exec(M);return r?[M.substr(L,r.index-L),r[0],false]:[M.substr(L),"",true]}function z(N,r){var L=E.cI?r[0].toLowerCase():r[0];var M=N.k[L];if(M&&M instanceof Array){return M}return false}function F(L,P){L=m(L);if(!P.k){return L}var r="";var O=0;P.lR.lastIndex=0;var M=P.lR.exec(L);while(M){r+=L.substr(O,M.index-O);var N=z(P,M);if(N){x+=N[1];r+='<span class="'+N[0]+'">'+M[0]+"</span>"}else{r+=M[0]}O=P.lR.lastIndex;M=P.lR.exec(L)}return r+L.substr(O,L.length-O)}function J(L,M){if(M.sL&&e[M.sL]){var r=d(M.sL,L);x+=r.keyword_count;return r.value}else{return F(L,M)}}function I(M,r){var L=M.cN?'<span class="'+M.cN+'">':"";if(M.rB){y+=L;M.buffer=""}else{if(M.eB){y+=m(r)+L;M.buffer=""}else{y+=L;M.buffer=r}}D.push(M);A+=M.r}function G(N,M,Q){var R=D[D.length-1];if(Q){y+=J(R.buffer+N,R);return false}var P=q(M,R);if(P){y+=J(R.buffer+N,R);I(P,M);return P.rB}var L=v(D.length-1,M);if(L){var O=R.cN?"</span>":"";if(R.rE){y+=J(R.buffer+N,R)+O}else{if(R.eE){y+=J(R.buffer+N,R)+O+m(M)}else{y+=J(R.buffer+N+M,R)+O}}while(L>1){O=D[D.length-2].cN?"</span>":"";y+=O;L--;D.length--}var r=D[D.length-1];D.length--;D[D.length-1].buffer="";if(r.starts){I(r.starts,"")}return R.rE}if(w(M,R)){throw"Illegal"}}var E=e[B];var D=[E.dM];var A=0;var x=0;var y="";try{var s,u=0;E.dM.buffer="";do{s=p(C,u);var t=G(s[0],s[1],s[2]);u+=s[0].length;if(!t){u+=s[1].length}}while(!s[2]);if(D.length>1){throw"Illegal"}return{r:A,keyword_count:x,value:y}}catch(H){if(H=="Illegal"){return{r:0,keyword_count:0,value:m(C)}}else{throw H}}}function g(t){var p={keyword_count:0,r:0,value:m(t)};var r=p;for(var q in e){if(!e.hasOwnProperty(q)){continue}var s=d(q,t);s.language=q;if(s.keyword_count+s.r>r.keyword_count+r.r){r=s}if(s.keyword_count+s.r>p.keyword_count+p.r){r=p;p=s}}if(r.language){p.second_best=r}return p}function i(r,q,p){if(q){r=r.replace(/^((<[^>]+>|\t)+)/gm,function(t,w,v,u){return w.replace(/\t/g,q)})}if(p){r=r.replace(/\n/g,"<br>")}return r}function n(t,w,r){var x=h(t,r);var v=a(t);var y,s;if(v){y=d(v,x)}else{return}var q=c(t);if(q.length){s=document.createElement("pre");s.innerHTML=y.value;y.value=k(q,c(s),x)}y.value=i(y.value,w,r);var u=t.className;if(!u.match("(\\s|^)(language-)?"+v+"(\\s|$)")){u=u?(u+" "+v):v}if(/MSIE [678]/.test(navigator.userAgent)&&t.tagName=="CODE"&&t.parentNode.tagName=="PRE"){s=t.parentNode;var p=document.createElement("div");p.innerHTML="<pre><code>"+y.value+"</code></pre>";t=p.firstChild.firstChild;p.firstChild.cN=s.cN;s.parentNode.replaceChild(p.firstChild,s)}else{t.innerHTML=y.value}t.className=u;t.result={language:v,kw:y.keyword_count,re:y.r};if(y.second_best){t.second_best={language:y.second_best.language,kw:y.second_best.keyword_count,re:y.second_best.r}}}function o(){if(o.called){return}o.called=true;var r=document.getElementsByTagName("pre");for(var p=0;p<r.length;p++){var q=b(r[p]);if(q){n(q,hljs.tabReplace)}}}function l(){if(window.addEventListener){window.addEventListener("DOMContentLoaded",o,false);window.addEventListener("load",o,false)}else{if(window.attachEvent){window.attachEvent("onload",o)}else{window.onload=o}}}var e={};this.LANGUAGES=e;this.highlight=d;this.highlightAuto=g;this.fixMarkup=i;this.highlightBlock=n;this.initHighlighting=o;this.initHighlightingOnLoad=l;this.IR="[a-zA-Z][a-zA-Z0-9_]*";this.UIR="[a-zA-Z_][a-zA-Z0-9_]*";this.NR="\\b\\d+(\\.\\d+)?";this.CNR="\\b(0[xX][a-fA-F0-9]+|(\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)";this.BNR="\\b(0b[01]+)";this.RSR="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|\\.|-|-=|/|/=|:|;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~";this.ER="(?![\\s\\S])";this.BE={b:"\\\\.",r:0};this.ASM={cN:"string",b:"'",e:"'",i:"\\n",c:[this.BE],r:0};this.QSM={cN:"string",b:'"',e:'"',i:"\\n",c:[this.BE],r:0};this.CLCM={cN:"comment",b:"//",e:"$"};this.CBLCLM={cN:"comment",b:"/\\*",e:"\\*/"};this.HCM={cN:"comment",b:"#",e:"$"};this.NM={cN:"number",b:this.NR,r:0};this.CNM={cN:"number",b:this.CNR,r:0};this.BNM={cN:"number",b:this.BNR,r:0};this.inherit=function(r,s){var p={};for(var q in r){p[q]=r[q]}if(s){for(var q in s){p[q]=s[q]}}return p}}();hljs.LANGUAGES.cpp=function(){var a={keyword:{"false":1,"int":1,"float":1,"while":1,"private":1,"char":1,"catch":1,"export":1,virtual:1,operator:2,sizeof:2,dynamic_cast:2,typedef:2,const_cast:2,"const":1,struct:1,"for":1,static_cast:2,union:1,namespace:1,unsigned:1,"long":1,"throw":1,"volatile":2,"static":1,"protected":1,bool:1,template:1,mutable:1,"if":1,"public":1,friend:2,"do":1,"return":1,"goto":1,auto:1,"void":2,"enum":1,"else":1,"break":1,"new":1,extern:1,using:1,"true":1,"class":1,asm:1,"case":1,typeid:1,"short":1,reinterpret_cast:2,"default":1,"double":1,register:1,explicit:1,signed:1,typename:1,"try":1,"this":1,"switch":1,"continue":1,wchar_t:1,inline:1,"delete":1,alignof:1,char16_t:1,char32_t:1,constexpr:1,decltype:1,noexcept:1,nullptr:1,static_assert:1,thread_local:1,restrict:1,_Bool:1,complex:1},built_in:{std:1,string:1,cin:1,cout:1,cerr:1,clog:1,stringstream:1,istringstream:1,ostringstream:1,auto_ptr:1,deque:1,list:1,queue:1,stack:1,vector:1,map:1,set:1,bitset:1,multiset:1,multimap:1,unordered_set:1,unordered_map:1,unordered_multiset:1,unordered_multimap:1,array:1,shared_ptr:1}};return{dM:{k:a,i:"</",c:[hljs.CLCM,hljs.CBLCLM,hljs.QSM,{cN:"string",b:"'\\\\?.",e:"'",i:"."},{cN:"number",b:"\\b(\\d+(\\.\\d*)?|\\.\\d+)(u|U|l|L|ul|UL|f|F)"},hljs.CNM,{cN:"preprocessor",b:"#",e:"$"},{cN:"stl_container",b:"\\b(deque|list|queue|stack|vector|map|set|bitset|multiset|multimap|unordered_map|unordered_set|unordered_multiset|unordered_multimap|array)\\s*<",e:">",k:a,r:10,c:["self"]}]}}}();hljs.LANGUAGES.r={dM:{c:[hljs.HCM,{cN:"number",b:"\\b0[xX][0-9a-fA-F]+[Li]?\\b",e:hljs.IMMEDIATE_RE,r:0},{cN:"number",b:"\\b\\d+(?:[eE][+\\-]?\\d*)?L\\b",e:hljs.IMMEDIATE_RE,r:0},{cN:"number",b:"\\b\\d+\\.(?!\\d)(?:i\\b)?",e:hljs.IMMEDIATE_RE,r:1},{cN:"number",b:"\\b\\d+(?:\\.\\d*)?(?:[eE][+\\-]?\\d*)?i?\\b",e:hljs.IMMEDIATE_RE,r:0},{cN:"number",b:"\\.\\d+(?:[eE][+\\-]?\\d*)?i?\\b",e:hljs.IMMEDIATE_RE,r:1},{cN:"keyword",b:"(?:tryCatch|library|setGeneric|setGroupGeneric)\\b",e:hljs.IMMEDIATE_RE,r:10},{cN:"keyword",b:"\\.\\.\\.",e:hljs.IMMEDIATE_RE,r:10},{cN:"keyword",b:"\\.\\.\\d+(?![\\w.])",e:hljs.IMMEDIATE_RE,r:10},{cN:"keyword",b:"\\b(?:function)",e:hljs.IMMEDIATE_RE,r:2},{cN:"keyword",b:"(?:if|in|break|next|repeat|else|for|return|switch|while|try|stop|warning|require|attach|detach|source|setMethod|setClass)\\b",e:hljs.IMMEDIATE_RE,r:1},{cN:"literal",b:"(?:NA|NA_integer_|NA_real_|NA_character_|NA_complex_)\\b",e:hljs.IMMEDIATE_RE,r:10},{cN:"literal",b:"(?:NULL|TRUE|FALSE|T|F|Inf|NaN)\\b",e:hljs.IMMEDIATE_RE,r:1},{cN:"identifier",b:"[a-zA-Z.][a-zA-Z0-9._]*\\b",e:hljs.IMMEDIATE_RE,r:0},{cN:"operator",b:"<\\-(?!\\s*\\d)",e:hljs.IMMEDIATE_RE,r:2},{cN:"operator",b:"\\->|<\\-",e:hljs.IMMEDIATE_RE,r:1},{cN:"operator",b:"%%|~",e:hljs.IMMEDIATE_RE},{cN:"operator",b:">=|<=|==|!=|\\|\\||&&|=|\\+|\\-|\\*|/|\\^|>|<|!|&|\\||\\$|:",e:hljs.IMMEDIATE_RE,r:0},{cN:"operator",b:"%",e:"%",i:"\\n",r:1},{cN:"identifier",b:"`",e:"`",r:0},{cN:"string",b:'"',e:'"',c:[hljs.BE],r:0},{cN:"string",b:"'",e:"'",c:[hljs.BE],r:0},{cN:"paren",b:"[[({\\])}]",e:hljs.IMMEDIATE_RE,r:0}]}};
hljs.initHighlightingOnLoad();
</script>
</head>
<body>
<h1>Reproducible Research: Peer Assessment 1</h1>
<h1></h1>
<h2>Loading and preprocessing the data</h2>
<pre><code class="r">library(reshape2)
library(Hmisc)
</code></pre>
<pre><code>## Loading required package: grid
## Loading required package: lattice
## Loading required package: survival
## Loading required package: splines
## Loading required package: Formula
##
## Attaching package: 'Hmisc'
##
## The following objects are masked from 'package:base':
##
## format.pval, round.POSIXt, trunc.POSIXt, units
</code></pre>
<pre><code class="r">library(plyr)
</code></pre>
<pre><code>##
## Attaching package: 'plyr'
##
## The following objects are masked from 'package:Hmisc':
##
## is.discrete, summarize
</code></pre>
<pre><code class="r">library(lattice)
unzip("activity.zip")
myData <- read.csv("activity.csv")
# reshape and remove missing values
tmpMelt <- melt(myData, id = "date", measure.vars = "steps")
tmpCast <- dcast(tmpMelt, date ~ variable, sum)
steps.day <- tmpCast[complete.cases(tmpCast), ]
</code></pre>
<h2>What is mean total number of steps taken per day?</h2>
<pre><code class="r"># 1.Make a histogram of the total number of steps taken each day
hist(steps.day$steps, breaks = nrow(steps.day), main = "Histogram - Total Number of Steps Per Day",
xlab = "Steps Per Day", col = "green")
</code></pre>
<p><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAfgAAAH4CAMAAACR9g9NAAAAnFBMVEX9/v0AAAAAADkAAGUAOTkAOWUAOY8AZo8AZrUA/wA5AAA5ADk5AGU5OWU5OY85ZrU5j9plAABlADllAGVlOQBlOY9lZgBlZjllZmVltbVltf2POQCPOTmPOWWPjzmPtY+P27WP29qP2/21ZgC1Zjm1tWW124+1/rW1/tq1/v3ajzna24/a/rXa/tra/v39tWX924/9/rX9/tr9/v0fzbaVAAAANHRSTlP///////////////////////////////////////////////////////////////////8AS1ciZQAAAAlwSFlzAAALEgAACxIB0t1+/AAAEdZJREFUeJztnQ174zgRgC8tLKUcR7ILHCQLdzR8NUDz9f//G5ZsJ3asROOxspU67/s8kK5sjzTzxrKTi+3vjmCS7957APA+IN4oiDcK4o2CeKMg3iiINwrijYJ4oyDeKIg3CuKNgnijIN4oiDcK4o2CeKMg3iiINwrijYJ4oyDeKIg3CuKNgnijvJP4/eLx9Xg8rB5f679a1kt9zMNq5nkKhmv72S9my7rnK0GuLOixe549vDRhZ7NPb5KRuzUrgqvdWnYn3l18r3k9Jfeh+G64jvhK1ETxp8C1sSfJyBu5zRsmuGw2j3edincX7/+q9qDZ46s3VxVx05Sg+vfjvxaf3g6rhx+rgm3rsm1nv6raXzehHWT37Pe+OkATrtmsI94vc91VLfsqfjdi1fiPZh/e1Ptg07uP3wnsV/EdVpH/3Rl5PZ/8wyV0bBJrUnabrF1mg8j14LZu1Xq4fmzbe74RshBfv+E//a8u37rZb319f/HsxLul/61XetvOWob7Zi2+CVCLb2K/ncU//rGW3hF/jthMG1WYdbMPdjR3A7fi/dvv0B35/HgK0nZed9yKH0ZuBldNG+0WmyruOjg7JOLdxLeVdjk3O2o9Ye6e/f758LJ7rqqxmXnxT+1mj69uv3D1dqtchvWBTgFO82/95jqJ/+fz/EL8OWLV17zpvTkinHsfBq7ducD1yM+bzP3JxCmxY2eqD0RuBrepw9YleZIddbRkId7/qy3f1lejqoH/Y19P9S/tRk78ky9N2+pm07a8vqanAI2ferOO+Nf1w9/64s8R62qvXe+Np7af4yCwZ10PvR75aRMXZDObnxI7peyPVYPIXfH1cA+raorrnKYmJ4up3subNXvSNfF+nZP489shIr7drCt+v/jVUHwdcbT4ZroPiz8ldmyneh/mmvi1myOag9jm4afne57r5SHesT6ZGk71rkB1HYfiuwSm+nazrnh3duVn2qWP3xffneod534CU/2mPaM/TfX1Js1Uf0rs2BEfiHw+uWuH2/n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wPcZ9bWhTgycSLy7UUpC8dX05vafJmr/ZVrgyk8w6tTg/h11j1EfVvO7jDjPPd6zXha2x99j1PvF/HiXEed5jPdcObZNirm7zzG+Jz5l4N2zO1/M+BjvJqSEZ/VuGjv85bWJ2n+ZhKtUMOrU4O0xJO2oa+93GXG+n+MfXhJ/1Hbc/XN82lFv/MUzy4w/x0NpIN4oiDcK4o2CeKMg3iiINwrijYJ4oyDeKIg3CuKNgnijIN4oiDcK4o2CeKMg3iiINwrijWJCvLvE5fHmj5HrZ6XPg63LO4/ufbAgfr+o3G0+vd0S7399e3l5QvOb3A9p3oL4xurPi2q33y/8hcxf/up/CL1tH5bsV3HXn9bLd7/9vWuv3ynukpX6cuV1fWHch8CC+MOq/v2587j2VyHsF5/eto/+YpT6mgSv2F37Vi9vLmSoxVcTgb9c+fvX7fy4vTwclIoF8X7PfvDqnMFKt5u+D19fznN7ezRvljcHhfrlfPXz/g9vf097feD7YUP80e/OTry7kvmhNu4m7mc/458vfWuW98TXK7uDwuHrz3/4IDO9CfH+9gLuMtb6SsNj7bLZkbf+MHAS/6VjvHmp1nAzhPvH5k8fZaY3Id6fl7sLi+tjvBf55F6c9L74ZnlXfCvdnQG4/30QLIj3E3g1pR9W/qy++mv/+Uc/x697Z/XNqvXZgG89fY7fzGa//P3SXQv7bkkkxoT4AdobCux+l3gg7wfiR7B5+DAzvVHxgHirIN4oiDcK4o2CeKMg3iiINwrijYJ4oyDeKIg3CuKNgnijIN4oiDfK/wEx1w2xTZ/TXAAAAABJRU5ErkJggg==" alt="plot of chunk unnamed-chunk-2"/> </p>
<pre><code class="r">
# 2.Calculate and report the mean and median total number of steps taken per
# day
steps.day.mean <- mean(steps.day$steps)
steps.day.median <- median(steps.day$steps)
</code></pre>
<p>The mean total number of steps per day is 10766
The median total number of steps per day is 10765 </p>
<h2>What is the average daily activity pattern?</h2>
<pre><code class="r"># 1.Make a time series plot (i.e. type = 'l') of the 5-minute interval
# (x-axis) and the average number of steps taken, averaged across all days
# (y-axis)
cleantmp <- myData[complete.cases(myData), ]
tmp1Melt <- melt(cleantmp, id = c("date", "interval"), measure.vars = "steps")
avgsteps.interval <- dcast(tmp1Melt, interval ~ variable, mean)
plot(avgsteps.interval, type = "l", main = "Average Daily Activity Pattern",
xlab = "5-minute Daily Intervals", ylab = "Average Steps Taken Over All Days")
</code></pre>
<p><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAfgAAAH4CAMAAACR9g9NAAAAn1BMVEX9/v0AAAAAADkAAGUAOTkAOWUAOY8AZo8AZrU5AAA5ADk5AGU5OWU5OY85ZmU5ZrU5j485j9plAABlADllAGVlOQBlOY9lZjllZmVltf2POQCPOTmPOWWPZgCPj2WPj9qPtY+P27WP29qP2/21ZgC1Zjm1tWW124+1/rW1/tq1/v3ajzna24/a/rXa/tra/v39tWX924/9/rX9/tr9/v3QzINWAAAANXRSTlP/////////////////////////////////////////////////////////////////////AHy10AoAAAAJcEhZcwAACxIAAAsSAdLdfvwAABWuSURBVHic7Z2Pn6OoGYfL7HWaue30muze9ZK9Xq8X217H7k1++P//bRUUFAUDigq+3+ezO5NEeWF4AoIR84cCkOQPaxcArAPEEwXiiQLxRIF4okA8USCeKBBPFIgnCsQTBeKJAvFEgXiiQDxRIJ4oEE8UiCcKxBMF4okC8USBeKJAPFEgnigQTxSIJ0oa4u8nthud+HZgnGP7lQ9v/P9wHtmx0HaqnmTH9j792NUO+l4xkob46wvraPKglsP2nVc7Ebt5ZMwkr/NqHfvprO9gThsVaYjP2Y9VffI2KX7mVTu7n57+Vlb7pa78stV++O3w/K62cyrFF6613q9u8f89iZf2Wh48Rrkr/8l2fEeVqUhRvvqnVrKbyCwrn1Sh79UOPG2njL+ePvybTXj7hiYJ8ffTh/+87Li8sppvh1JdVrdhUdHPX0W7e34Xz755KXfKWm28bttlK7zV+8muPi+9ZHVrlXmIGKxSLMSrTKX4XSuZEl+H/r0lXi+j2MImHLECk4T468vuzptZ2XbOwv6Vy+UvNQdm7uj6Uu6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38MAcbEl+vY+QP+S/+ny9Cq1Rrv7hlbkuKb9Y819t/eP/XuSiMifgL+Z7/UylmXeM2FxsSL8iOGWO7R+J53/BUqy2qWxMUGe+vq+33L//84b3oiq8SVUswf//SSsEPE0+pud+eeP7zkfjP+qCt7Mv5AE919UX+477e2kskVuJ9+eW1laKoQqzx545nQ+LrdYz8oVE8b9f5B3mMr0ypUX295l3u/a1owPqbJlNH+3LiuG+l4KEgfkXqdYyFRTzf/tfPb/eTGKBXezbz+HLjH78/1nvX758mbZNIiBdvDJWi6vPX+7tHsSXx4bh+t3YJZgfiDeTJDdX8gXiiQDxRIJ4oEE8UiCcKxBMF4okC8USBeKJAPFEgnigQTxSIJwrEEwXiiQLxRPk/Ti9ZFGMA86IAAAAASUVORK5CYII=" alt="plot of chunk unnamed-chunk-3"/> </p>
<pre><code class="r">
# 2.Which 5-minute interval, on average across all the days in the dataset,
# contains the maximum number of steps?
interval.max <- avgsteps.interval$interval[which.max(avgsteps.interval$steps)]
</code></pre>
<p>The 5-minute interval, on average across all days in the dataset, that contains the maximum number of steps is 835</p>
<h2>Imputing missing values</h2>
<pre><code class="r">## calculate the total number of missing values in the dataset
miss.total <- sum(is.na(myData))
</code></pre>
<p>The total number of missing values in the dataset is 2304. </p>
<pre><code class="r"># Create a new dataset that is equal to the original dataset but with the
# missing data filled in. Replace with 5-minute averaged interval
myData2 <- merge(myData, avgsteps.interval, by = "interval")
na.steps <- is.na(myData2$steps.x)
myData2$steps.x[na.steps] <- myData2$steps.y[na.steps]
myData2 <- myData2[, c(1:3)]
# 4.Make a histogram of the total number of steps taken each day and
# Calculate and report the mean and median total number of steps taken per
# day. Do these values differ from the estimates from the first part of the
# assignment? What is the impact of imputing missing data on the estimates
# of the total daily number of steps?
steps.day2 <- aggregate(steps.x ~ date, data = myData2, FUN = sum)
hist(steps.day2$steps.x, breaks = nrow(steps.day2), main = "Total Number of Imputed Steps Per Day",
xlab = "Steps Per Day", col = "red")
</code></pre>
<p><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAfgAAAH4CAMAAACR9g9NAAAAnFBMVEX9/v0AAAAAADkAAGUAOTkAOWUAOY8AZo8AZrU5AAA5ADk5AGU5OWU5OY85ZrU5j485j9plAABlADllAGVlOQBlOY9lZgBlZjllZmVltbVltf2POQCPOTmPOWWPjzmPtY+P27WP29qP2/21ZgC1Zjm1tWW124+1/tq1/v3ajzna24/a/rXa/tra/v39tWX924/9/rX9/tr9/v3/AAAJ9/HAAAAANHRSTlP//////////////////////////////////////////////////////////////////wD/9XEwmgAAAAlwSFlzAAALEgAACxIB0t1+/AAAEIVJREFUeJztnYt647YRRiNv69jdppF2k6aRt01q9WI1Xd36/u9WAiRlUoTEGQiyQcw535fIS1FD4D8iSMqC+c0BTPLNezcA3gfEGwXxRkG8URBvFMQbBfFGQbxREG8UxBsF8UZBvFEQbxTEGwXxRkG8URBvFMQbBfFGQbxREG8UxBsF8UZBvFEQb5T3F79/mnkeXhetlscfd4sPL/XjbOnWrf8VKHLmiR7bx9ndc6foJTptaFty/7X9aTbzPw/WOcWtWRFc7dJzb0CO4lezoPgq6yvFt4UF4lcDI0fxtbGH0DqnNHL9u+3Mc7P5eLtvwfuLP7g90We69jH4N8LDYVMH1hHvn/vw4h07C5vZt0+zDy9rt9dUC//Z7IbrejfaP9391CbeKexXcUWHr67KtrX/W7ehreVf+nMr3rW2qvDv/jrHGm5cmTVvrPrNsnJyB82qe7Zxq9Z99RvfvNUbISPxq3rHr8XX+4NPuBH/4c+19I74FrdwVq/fVOlq7hXuiA+8+kR8r1ZbzYlt3wyhddqW161uxQ+b1fSsGjbaV6yruqvg6HAD8hG/ffQ7ePW/7ojcEf+vx/mJ+A8vToJ7TZXn3L/Yl6pXaw8e4cKBV8+Wx9p+1WOt7WO1eN2K9+5cq3rrHGs0w1ezoWaoDzSr6dm6bpP71/bxQXbISkE+4jc+Ef+u91m40HriX1Z3f++Lf/CLq9GzHibdC5sd2S1p953Twq3401evZ/O++GMtX+H15M7v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hre6XPg0uXN27d+2BB/G5RuVvff70k3n/79nR6QvOd3CLNWxDfWP11Ue32u4WfyPz5b/6L0Jv2Zsl+FTf/tH5++8cf3PL6neKmrNTTlVf1xLgisCB+/1R//9x5XPlZCLvF/dfNBz8ZpZ6T4BW7uW/1881Ehlp8NRD46cofXzbzw+b0cDBVLIj3e/adV+cMVrrd8L3/8vw6trdH8+b55qBQP7zOft79+PUfaecHvh82xB/87uzEu5nMd7VxN3A/+hH/depb83xPfL2yOyjsv/z6YyEjvQnx/s8LuGms9UzDQ+2y2ZE3/jBwFP+5Y7x5qNZwI4T7x/ovpYz0JsT783I3sbg+xnuRD+7BSe+Lb57vim+luzMA918hWBDvB/BqSN8/+bP66qfdp5/8GL/qndU3q9ZnA37p8Tp+PZv9/oelmwv7bp1IjAnxA2L/oMD2T4kb8n4gXsH6rpiR3qh4QLxVEG8UxBsF8UZBvFEQbxTEGwXxRkG8URBvFMQbBfFGQbxREG8UxBvl/5T/bjlAsmmxAAAAAElFTkSuQmCC" alt="plot of chunk unnamed-chunk-5"/> </p>
<pre><code class="r">
steps.day2.mean <- mean(steps.day2$steps.x)
steps.day2.median <- median(steps.day2$steps.x)
</code></pre>
<p>The mean total number of steps taken per day is 10766 </p>
<p>The median total number of steps taken per day is 10766</p>
<p>The imputed values changed slightly the median total number of steps taken per day. The mean value remained unchanged. </p>
<h2>Are there differences in activity patterns between weekdays and weekends?</h2>
<pre><code class="r"># 1.Create a new factor variable in the dataset with two levels - 'weekday'
# and 'weekend' indicating whether a given date is a weekday or weekend day.
myData2$date <- as.Date(myData2$date)
weekend <- c("Saturday", "Sunday")
myData2$daytype <- as.factor(sapply(myData2$date, function(x) ifelse(weekdays(x) %in%
weekend, "weekend", "weekday")))
# 2.Make a panel plot containing a time series plot (i.e. type = 'l') of the
# 5-minute interval (x-axis) and the average number of steps taken, averaged
# across all weekday days or weekend days (y-axis).
steps.daytype <- ddply(myData2, .(interval, daytype), summarize, steps.x = mean(steps.x))
xyplot(steps.x ~ interval | daytype, data = steps.daytype, layout = c(1, 2),
type = "l", xlab = "5-minute Intervals Over Day", ylab = "Number of Steps",
main = "Activity Patterns on Weekends and Weekdays")
</code></pre>
<p><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAfgAAAH4CAMAAACR9g9NAAABGlBMVEUAAAAAAC4AADoAAFIAAGYAM1IAM3MAOmYAOpAAXJEAZpAAZrYAgP86AAA6AC46ADo6AFI6AGY6MwA6M3M6OgA6Ojo6OmY6OpA6XJE6ZrY6gHM6gK86kJA6kNtmAABmAC5mADpmAFJmAGZmMwBmM3NmOgBmOjpmOpBmXFJmZjpmZmZmgHNmkJBmo8xmtrZmtttmtv+QMwCQMy6QM1KQOgCQOjqQOmaQXACQZgCQgFKQkGaQkLaQtpCQxZGQxcyQ27aQ29uQ2/+2XAC2XC62ZgC2Zjq2tma2xXO225C25ZG25cy2/7a2/9u2///bgC7bkDrb5czb/7bb/9vb////o1L/tmb/xXP/25D/5ZH/5a//5cz//7b//9v///+kVn4hAAAACXBIWXMAAAsSAAALEgHS3X78AAAa9klEQVR4nO2djZ/btnnHGdfNzhOudZptzprqGqdpuqXzJnvnbWk6d3a0NXFqy+lZPp9O/P//jQEkSIIkSJEEHoLk8/t97iS+PM8DiF/ihRQIRTHEUlHoDEBhBPBMBfBMBfBMBfBMBfBMRQz+eBmtShu2m/j24u6rfD1dkVsN3V5ESpuyW9Wqb0buPJcRorMrGV6+VFXKVF1WnyarXml1i+xfxOCvz6PSAd1GNniVrRq8Onqmgd23q5S3DCyD7ivnok7TH/heaS0U/C76KsElS748A9RrtFKfe5sckG2y8he19W8v5cHYR2vllB6LrVzZJ/yPqYHyVRGTukCWqn+O7vzP5d3/i5JTS55hxSmmbNbKJtsrpWJfn//L+UbuXedh8gWVKZnOxkggc1bJ/6vKkplGmjObVY+0cp/sc+pjUPowRKIFLz/Kd+er9KjIz/KXHPw+rQfvPM/Ar3byQGzTQp6DT4v+2V8N8NukMlinEdM9arO2TMvOVm88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