Code R for Course Project
This scrip perform:
-
Download data from https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip
-
Merges the training and the test sets to create one data set. write data to X.txt, y.txt, subject.txt (code: #1 Subjects,#1 Labels, #1 SET).
-
Extracts only the measurements on the mean and standard deviation for each measurement. Write data to Mean_std.txt (code: #2 Feature, Mean and std).
-
Uses descriptive activity names to name the activities in the data set(step3) and Appropriately labels the data set with descriptive variable names(step4). (code: #4 Variable name, #3 Activity name). For convinient, step 4 should be performed before step 3). Write data to Activity_named_data_sets.txt.
-
From the data set in step 4, creates a second, independent tidy data set with the average of each variable for each activity and each subject. Write data to second_data_set.txt (code : #5 second tidy Data set).
You can run each line to see how it work.