Skip to content

newworldorder/gettingandcleaningdata

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Getting and Cleaning Data Course Project

Requirements

Overview

  1. Put run_analysis.R and the unzipped UCI dataset folder in the same working directory
  2. In R, enter the following commands
> source('run_analysis.R')
> result <- make_tidy()
  • To observe the dataset of interest enter the following command
> result$d2 

Function Description

  • make_tidy(dir = "UCI HAR Dataset/") assumes the directory name (dir) is unchanged. If an absolute path is provided, the function can be run from anywhere on the filesystem.
  • make_tidy combines the data and test set X values (measurements), y values (activity labels), subject identifiers into a single table keeping only those X values that correspond to a mean or standard deviation. The y values are replaced with the character representations in activity_labels.txt This data frame is stored result$d1.
  • make_tidy for each valid (activity label, subject id) pair computes the mean for each measurement still in result$d1. The names of these columns have been modified to be prepended with MEAN_ to indicate they correspond to means. The result of this computation is stored in result$d2.

Fields in New Dataset (result$d2)

  • activity corresponds to the verbal description of the activity label
  • subject corresponds to the subject responsible for producing the data in a given row
  • MEAN_* corresponds to the mean of measurements from the original UCI that corresponded to means or standard deviations. (see UCI HAR Dataset/features.txt for the features containing case insensitive mean and std strings in the name)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages