Introduction to R Programming and RStudio, Exams of Nursing

A comprehensive overview of the fundamental concepts and features of the r programming language and the rstudio integrated development environment (ide). It covers topics such as the r console, running code, working with objects and data structures, logical operators, functions, and error handling. The document also discusses r packages, which extend the functionality of r, and introduces several useful functions for data exploration and visualization. By studying this document, students can gain a solid understanding of the basic tools and techniques required to start working with r and rstudio, which are widely used in various fields of data analysis, statistical modeling, and scientific computing.

Typology: Exams

2023/2024

Available from 08/26/2024

answerhub
answerhub 🇺🇸

4

(16)

5.4K documents

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
MBA777 - DARRAT EXAM 1 2024 WITH
100% ACCURATE SOLUTIONS
a programming language that runs computations while RStudio is an integrated development
environment (IDE) that provides an interface by adding many convenient features and tools. -
Answer✔✔R
Where you enter in commands. - Answer✔✔Console
The act of telling R to perform an act by giving it commands in the console. - Answer✔✔Running code
Where values are saved in R. We'll show you how to assign values to objects and how to display the
contents of objects. - Answer✔✔Objects
A series of values. These are created using the c() function, where c() stands for "combine" or
"concatenate." For example: c(6, 11, 13, 31, 90, 92). - Answer✔✔Vectors
Categorical data are represented in R as factors. - Answer✔✔Factors
like rectangular spreadsheets: they are representations of datasets in R where the rows correspond to
observations and the columns correspond to variables that describe the observations. - Answer✔✔Data
Frames
TRUE/FALSE statements and mathematical operators such as < (less than), <= (less than or equal), and !=
(not equal to). - Answer✔✔Boolean Algebra
& representing "and" as well as | representing "or." Ex: (2 + 1 == 3) & (2 + 1 == 4) returns FALSE since
both clauses are not TRUE (only the first clause is TRUE). On the other hand, (2 + 1 == 3) | (2 + 1 == 4)
returns TRUE since at least one of the two clauses is TRUE. - Answer✔✔Logical operators:
pf3

Partial preview of the text

Download Introduction to R Programming and RStudio and more Exams Nursing in PDF only on Docsity!

MBA777 - DARRAT EXAM 1 2024 WITH

100% ACCURATE SOLUTIONS

a programming language that runs computations while RStudio is an integrated development environment (IDE) that provides an interface by adding many convenient features and tools. - Answer✔✔R Where you enter in commands. - Answer✔✔Console The act of telling R to perform an act by giving it commands in the console. - Answer✔✔Running code Where values are saved in R. We'll show you how to assign values to objects and how to display the contents of objects. - Answer✔✔Objects A series of values. These are created using the c() function, where c() stands for "combine" or "concatenate." For example: c(6, 11, 13, 31, 90, 92). - Answer✔✔Vectors Categorical data are represented in R as factors. - Answer✔✔Factors like rectangular spreadsheets: they are representations of datasets in R where the rows correspond to observations and the columns correspond to variables that describe the observations. - Answer✔✔Data Frames TRUE/FALSE statements and mathematical operators such as < (less than), <= (less than or equal), and != (not equal to). - Answer✔✔Boolean Algebra & representing "and" as well as | representing "or." Ex: (2 + 1 == 3) & (2 + 1 == 4) returns FALSE since both clauses are not TRUE (only the first clause is TRUE). On the other hand, (2 + 1 == 3) | (2 + 1 == 4) returns TRUE since at least one of the two clauses is TRUE. - Answer✔✔Logical operators:

perform tasks in R. They take in inputs called arguments and return outputs. You can either manually specify a function's arguments or use the function's default values. - Answer✔✔Functions, (also called Commands)

  1. Errors, 2. Warnings, 3. Messages - Answer✔✔The 3 situations R will show red text in the console pane for when the code will not run. - Answer✔✔Errors R will try to explain the problem that may happen. Generally code will still work, but with some caveats.
  • Answer✔✔Warnings When the red text doesn't say 'error' or 'warning', this will appear. They are helpful diagnostics & they don't stop your code from working. You'll also see these when you install packages too using insall.packages. Think of this as a green traffic light, everything is fine. - Answer✔✔Messages extend the functionality of R by providing additional functions, data, and documentation. They are written by a world-wide community of R users and can be downloaded for free from the internet. Analogy - like apps you can download onto a mobile phone. - Answer✔✔R packages
  1. Click 'packages' tab > Click 'install' next to update > Type name of the package under 'Packages', click install
  2. typing install.packages("ggplot2") in the console pane of RStudio and pressing Return/Enter on your keyboard. - Answer✔✔Two Ways to Install an R Package