any text you write will be treated as text, not executable code
you can format text by surrounding it with special characters:
note that the above text will be formatted into a numbered list. You can also make bullet lists:
you can even include urls. rmarkdown help
lastly, you can write text chunks
these will be printed within a box to
your document with whatever formating you
like. *special characters* won't do anything.
you can add a code chunk using the following syntax
# everything you type in here works just like a regular r script
data(cars)
str(cars)
## 'data.frame': 50 obs. of 2 variables:
## $ speed: num 4 4 7 7 8 9 10 10 10 11 ...
## $ dist : num 2 10 4 22 16 10 18 26 34 17 ...
hist(cars$speed)
# note that you can evaluate your code chunk using the green arrow keys at the top right corner
you can also add snippets of r code to text using this syntax: the mean speed of cars was: 15.4.