Giter Site home page Giter Site logo

tidydataproject's Introduction

This repository is the tidy data project for class "Getting and Cleaning Data" on Coursera. The run_analysis.R file will give you the tidy data set with the average of each variable for each activity and each subject. The following we are going to describe how the script works:

  • We read the data into R in line 15 and line 1214 using the original file name.
  • Then line 6 and line 15 show appropriately labels the data set with descriptive activity names.
  • The measurements on the mean and standard deviation for each measurement are extracted in line 7~9. ("meanFreq()" is excluded)
  • Line 10 and line 16 contains variables subject, activity and the measurement we extract before.
  • Line 18 merges the training and the test sets to create one data set.
  • Data set for each subject and activity in line 19 and 21
  • The average of each variable in line 20 and 22 using sapply. (For each subject and activity not pair of them)
  • Line 23 output the final result.

The run_analysis.R file can be run as long as the Samsung data is in your working directory. A code book that describes the variables, the data, and any transformations or work that you performed to clean up the data called CodeBook.md.

tidydataproject's People

Contributors

shanekao avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.