R Programming Basics and Data Structures

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/47

flashcard set

Earn XP

Description and Tags

A comprehensive set of vocabulary flashcards covering R programming basics, including mathematical and logical operators, data types, data structures, control flow (loops and conditionals), and the apply family of functions.

Last updated 5:37 PM on 7/6/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

48 Terms

1
New cards

seq()

A function used to define numeric sequences using arguments such as from, to, and by.

2
New cards

%/%

The mathematical operator for integer division.

3
New cards

%%

The mathematical operator for modulo (remainder) division.

4
New cards

NaN

An indicator representing an undefined value or 'Not a Number.'

5
New cards

NA

An indicator representing a missing value.

6
New cards

NULL

An indicator representing an empty set or object.

7
New cards

%*%

The mathematical operator used for matrix multiplication.

8
New cards

xor()

A logical function representing the 'exclusive or' operation.

9
New cards

&& and ||

Logical operators that can only be used to compare inputs of length 11.

10
New cards

& and |

Logical operators used to compare elements of two vectors component-wisely.

11
New cards

typeof()

A function used to check the internal data type of an object.

12
New cards

logical

A data type representing Boolean values: TRUE and FALSE.

13
New cards

character

A data type used for character strings, such as "text".

14
New cards

factor

A data type used for texts, strings, or numbers that represent categories.

15
New cards

integer

A data type specifically for whole numbers, such as 33.

16
New cards

double (numeric)

A data type for integers or real numbers, such as 2×exp(1)-2 \times \exp(1).

17
New cards

complex

A data type for complex numbers, such as 21i2 - 1i.

18
New cards

as.character()

A function used to convert an object to a character data type.

19
New cards

Vector

A basic data structure in R that does not allow mixing of different data types.

20
New cards

rep()

A function used to replicate elements of vectors, including arguments for 'times' and 'each'.

21
New cards

matrix()

A function used to define a matrix, with options for nrow, ncol, and byrow.

22
New cards

cbind()

A function used to combine objects by columns.

23
New cards

rbind()

A function used to combine objects by rows.

24
New cards

dim()

A function that returns the dimensions (number of rows and columns) of a matrix or data frame.

25
New cards

solve(X)

A function used to calculate the inverse of a matrix XX.

26
New cards

t(X)

A function used to calculate the transpose of a matrix XX.

27
New cards

array()

A data structure that can contain an arbitrary number of dimensions.

28
New cards

list()

A flexible data structure that can contain elements of different data types and structures.

29
New cards

data.frame

The central data structure for data sets, consisting of a list of vectors of the same length.

30
New cards

str()

A function that returns the internal structure of a data object.

31
New cards

subset()

A function used to create a subset of a data frame based on logical conditions.

32
New cards

identical()

A function used to check whether two objects are exactly equal.

33
New cards

order()

A function that returns a permutation to rearrange an argument into ascending or descending order.

34
New cards

any()

A logical operation that returns TRUE if at least one component of a logical vector is TRUE.

35
New cards

all()

A logical operation that returns TRUE if all components of a logical vector are TRUE.

36
New cards

which()

A function that returns the indices of each component where a logical condition is TRUE.

37
New cards

function()

The keyword used to define a custom function with specified parameters.

38
New cards

return()

A statement used to explicitly specify the value that a function should return.

39
New cards

… (dots)

An argument used in function definitions to allow an unspecified number of expected arguments.

40
New cards

if … else

A conditional statement used to execute specific command sequences based on a logical condition.

41
New cards

ifelse()

A vectorized version of the if-else statement used for vector-valued evaluation of conditions.

42
New cards

for loop

A loop structure used to repeat commands when the exact number of iterations is known.

43
New cards

while loop

A loop structure used to repeat operations as long as a specific condition remains TRUE.

44
New cards

repeat loop

A loop structure that repeats an instruction sequence until a break condition is encountered.

45
New cards

apply()

A function that applies another function to the margins (rows or columns) of an array or matrix.

46
New cards

lapply()

A function that applies another function component-wise to a list, data set, or vector and returns a list.

47
New cards

sapply()

A function that behaves like lapply() but returns the output as a vector or a matrix.

48
New cards

tapply()

A function that applies another function to each group of values defined by unique factor levels.