##Summary
The provided scripts merge UCI HAR Dataset into a tidy data set and then calcuate an average of each measurement attribute grouped by Activity and Subject. The data set may be downloaded from
https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip
##Scripts
activityMethods.R - Implements function getActivity which looks up an activity name given an activity code.
run_analysis.R - Processes the UCI HAR Dataset and performs the following operations:
- Determines if target directory exists and exits if not
- Sets the working directory to the subdirectory where the data has been unzipped
- Loads the training data
- Loads the test data
- Load the activity labels
- Load the feature list
- Merges the training and test data via concatenation of rows
- Sets the column name of subjectmerged to "subject"
- Extracts the features and uses to set the column names of the x data
- Merges the activity list with the x data
- Merges x and y data
- Merges the subject list with the x and y data set by appending subject as the first column
Next, extracts the columns of interest for analysis
- Creates a list of the columns to include in the tidy set which will contain subject, activity, and the mean and std columns and groups means and standard deviation measurements.
- Subsets the selected columns into a new tidy set
- Calculates the average of each measurement for each subject and activity
- Outputs result to a file