R Data StructuresLesson 22Free preview
R Data Frames
This lesson is part of R · All levels
Summary
This lesson paints a Data Frame which is the most fundamental data structure and is often used in data analysis in R. Data frames present data in the form of two-dimensional tables (lines and columns), where each column can have a different type of data. Readers will learn to create, filter, and summarize data frames with summary().
Key points
- Data frames are representations of two-dimensional tables with heterogeneous columns.
- It is created using the function 'data.frame(column1 = data1, column2 = data2,...)'
- Each column should have the same number of rows
- Columns can be accessed using the dollar sign '$' or square brackets '[[name]]'
- The 'summary()' and 'str()' functions display a summary of statistics and table structures
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.