Skip to content

Commit 58f9c56

Browse files
committed
Full first half content
1 parent 66ae1df commit 58f9c56

File tree

5 files changed

+774
-17
lines changed

5 files changed

+774
-17
lines changed

Diff for: 10_minutes_to.R

+14-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,11 @@
77
# Click back in Console tab on lower-left
88
# Notice blinking cursor
99

10+
# A quick note about comments in *script* files
1011
# <-- The pound/hash symbol means this line is a comment.
12+
3 + 4 # comments can be an the end of a line.
13+
# no code after a comment! 3 + 4
14+
1115

1216
#-----------------------------------------------
1317
## R as a calculator
@@ -29,7 +33,7 @@
2933
## Operators
3034
# + addition
3135
# - subtraction
32-
# * multipliation
36+
# * multiplication
3337
# / division
3438
# ^ or ** exponentiation
3539
# x %% y modulus
@@ -46,10 +50,10 @@
4650
# x | y x OR y
4751
# x & y x AND y
4852

49-
3 > 4
53+
3 > 4 # use run command instead of typing
5054
3 != 4
5155

52-
## Math functions / constants
56+
## Math and Stats functions / constants
5357
# log(x) natural log or in specified base
5458
# exp(x) exponential
5559
# pi value of pi
@@ -67,6 +71,13 @@ log(10) # function is log, argument is 10
6771
# but you do need to call functions.
6872

6973

74+
# !!! Switch to notebook by this point
75+
## - constant attention switching between console and script
76+
## - not visually interesting
77+
## - comment style explanations are stunted
78+
## - where is this going? how much is left?
79+
80+
7081
#-----------------------------------------------
7182
## Storing values in variables
7283
width = 20 # does not print anything (try ls() or objects())

0 commit comments

Comments
 (0)