Just try to type in some simple calculations in the console:
2*2
2^10
sqrt(16)
16^(1/2)
The following line should install package install.packages("package_name")
If this does not work:
Select all repositories in “packages” menu or by calling setRepositories()
If still does not work - use Bioconductor installation:
source("http://bioconductor.org/biocLite.R")
biocLite("rgl")
Function always have ()
when it is called. Try to type
log(100)
There are several ways to set function parameters
log(100, base=10) # full parameter name
log(100, b=10) # distinctive part of a parameter name
log(100, 10) # no parameter name. The order defines
In R the vast majority of functions is well-annotated. Try some variants.
#
is a comment character. The code after #
is ignoredhelp("sqrt") # help on "sqrt" function
?sqrt # ...the same...
?round
??round # fuzzy search for "round" in all help topics
apropos("plot") # propose commands with the word "plot" inside name
There are some demos as well. They are quite old (and majority - ugly), but still we can see them.
demo() # show available demos
demo("image") # start demo "image"
demo(persp)
demo(plotmath)