Skip to content

kklarsen/getting_and_cleaning_data_project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 

Repository files navigation

COURSE PROJECT

Getting and Cleaning Data (getdata-013)

April 2015

This repo provides my R code solution to Coursera's "Getting & CLeaning Data" Project. The project is based on Smartphone datasets from UCI (University of California,Irvine) Machine Learning Repository specificly measuring Human Activity by collecting data from sensors integrated in the Smartphone itself (i.e., Samsung Galaxy II S). The dataset shall be known as UCI HAR (UCI Human Activity Recognition) data or just the data.

A prerequisite for succesully running the R code is that the data has been installed/unzipped on to your directory. The code will look for the "./UCI HAR Dataset" directory within your working directory. If not found, the code will retreive the zip file and unzip the UCI HAR directory and file structure.

This repo contains one R-code script named run_analysis.Rin line with the Project's requirements. The run_analysis.R code will do the following;

  1. Code will retrieve/unzip UCI HAR Dataset unless it already has been installed/unzipped
  2. Reads the UCI HAR Datasets.
  3. Creates a "results" directory ("./results") where intermediate or final results can be written to.
  4. Consolidate all measurement data into 1 single data.frame
  5. Inserts explanatory measurement headers and corresponding variable labels (numeric as well as descriptive).
  6. Extracting a sub-set of measurements.
  7. Tidy the data-set (e.g., see also Hadley Wickham "Tidy Data" article).
  8. Several files are written to the "results" directory along the data tidying process.

Note: the requested final (tidy) file "tidy_mean.txt" can be found in the "./results" directory that was created by this code in the working directory.

My codebook.md will in more detail explain the R-code's functionality.

Reference: Davide Anguita, Alessandro Ghio, Luca Oneto, Xavier Parra and Jorge L. Reyes-Ortiz. A Public Domain Dataset for Human Activity Recognition Using Smartphones. 21th European Symposium on Artificial Neural Networks, Computational Intelligence and Machine Learning, ESANN 2013. Bruges, Belgium 24-26 April 2013.

About

Prepare tidy smartphone data based on Human Activity Data that can be used for later analysis.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages