Converting inputs to data types suitable for analysis
Another aspect of data cleaning is investigating the input data and shaping it to conform to your analysis design needs. The third step of the SFCA approach is convert. Specifically, converting the data from one data type to another.
Converting between data types
The R environment stores data in one of the several data types. You will experience five different data types in the Bike Sharing Analysis Project:
Data type |
Explanation |
Example |
Numeric |
A number having a decimal value |
|
Integer |
A number without decimals |
|
Character |
A string variable |
|
Factor |
A categorical variable that has a character and integer representation |
|
Date |
A date or time in various formats |
|
Each data type has different properties consistent with definitions used in disciplines such as computer science, mathematics, and statistics. Some R...