<- "10.00"
fare <- "2.00"
tip <- "0.80" tax
Classwork 5
R Basics
Direction
- Open the Quarto document,
danl-200-quarto.qmd
. - Use
danl-200-quarto.qmd
as a template to answer the following questions.- Delete everything except for the YAML header.
- Shortcut for creating a code chunk
- Windows: Alt + Ctrl + I
- Mac: option + command + I
- To run a code code chunk:
- Click the play button in a code chunk at the top right corner.
- Shortcut:
- Windows: Ctrl + Shift + Enter
- Mac: command + shift + return
- To run a current line of code in a code chunk:
- Shortcut:
- Windows: Ctrl + Enter
- Mac: command + return
- Shortcut:
Question 1
In R, what are the different data types and data structures we discuss in our course? Provide an example of each.
Answer
Question 2
Write an R code that uses str_c()
function to print out the following message:
Answer
Question 3
- Read the following CSV file as an object,
tips
.https://bcdanl.github.io/data/tips_seaborn.csv
Answer
Question 4
- Use
DT::datatable()
for thetips
data.frame .
Answer
Question 5
- What are the minimum, minimum, median, mean and standard deviation of the
tip
variable in thetips
data.frame?
Answer
Discussion
Welcome to our Classwork 5 Discussion Board! 👋
This space is designed for you to engage with your classmates about the material covered in Classwork 5.
Whether you are looking to delve deeper into the content, share insights, or have questions about the content, this is the perfect place for you.
If you have any specific questions for Byeong-Hak (@bcdanl) or peer classmate (@GitHub-Username) regarding the Classwork 5 materials or need clarification on any points, don’t hesitate to ask here.
Let’s collaborate and learn from each other!