install r-base on ubuntu: sudo apt-get install -y r-base
download rstudio:
https://download1.rstudio.org/rstudio-1.0.153-amd64.deb
install gui tool(rstudio) for r language: sudo dpkg -i rstudio-***-amd64.deb
some examples for r language:
***
# library(plotrix)
# slices <- c(1,2,3,4)
# cc <- c(‘a‘, ‘b‘, ‘c‘, ‘d‘)
# pie3D(slices, labels = cc, explode = 0.1)
# library(scatterplot3d)
# scatterplot3d(iris[,1:2])
# library(ggplot2)
# qplot(1:1000, rnorm(1000))
***
时间: 2024-11-03 03:30:03