Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/p10ns11y/tidygetdat-012
Getting and Cleaning Data Course Project
https://github.com/p10ns11y/tidygetdat-012
Last synced: 8 days ago
JSON representation
Getting and Cleaning Data Course Project
- Host: GitHub
- URL: https://github.com/p10ns11y/tidygetdat-012
- Owner: p10ns11y
- Created: 2015-03-22T22:25:52.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-03-24T03:33:08.000Z (over 9 years ago)
- Last Synced: 2023-02-26T10:01:40.402Z (over 1 year ago)
- Language: HTML
- Size: 57.2 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.html
Awesome Lists containing this project
README
code{white-space: pre;}
pre:not([class]) {
background-color: white;
}if (window.hljs && document.readyState && document.readyState === "complete") {
window.setTimeout(function() {
hljs.initHighlighting();
}, 0);
}.main-container {
max-width: 940px;
margin-left: auto;
margin-right: auto;
}
code {
color: inherit;
background-color: rgba(0, 0, 0, 0.04);
}
img {
max-width:100%;
height: auto;
}Tidygetdat-012
Getting and Cleaning Data Course Project
How the code works
- It first merges the training and test data sets into one using ‘merge’ function
- To extract only mean and standard deviation, ‘grep’ function used over features.txt and the extracted names used on X - 561 vector features
‘gsub’ function used to name activities in the data set descriptively
- using ‘names’ property , variables are appropirately labled
‘cbind’ function helps to merge the activity ,subject , extracted features into single dataframe
Finally, using ‘melt’ and ‘dcast’ the required tidy data is created
// add bootstrap table styles to pandoc tables
$(document).ready(function () {
$('tr.header').parent('thead').parent('table').addClass('table table-condensed');
});(function () {
var script = document.createElement("script");
script.type = "text/javascript";
script.src = "https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML";
document.getElementsByTagName("head")[0].appendChild(script);
})();