2019独角兽企业重金招聘Python工程师标准>>>
R是功能强大的统计软件,和Lisp一样也有一个交互式的命令行环境,还有众多的扩展库,可以用来进行专业的统计分析。要在Common Lisp中方便的调用R的功能,可以试用rcl这个库。安装方法很简单,因为它已经纳入到quicklisp库中了:
(ql:quickload “rcl”)
使用:
* (use-package :rcl) T
* (r-init) T
* (r "R.Version") ("x86_64-pc-linux-gnu" "x86_64" "linux-gnu" "x86_64, linux-gnu" "" "2" "12.1" "2010" "12" "16" "53855" "R" "R version 2.12.1 (2010-12-16)") ((:NAMES "platform" "arch" "os" "system" "status" "major" "minor" "year" "month" "day" "svn rev" "language" "version.string"))
* (r "seq" 1 5) (1 2 3 4 5)
* (r "*" 2 (r "seq" 1 5)) (2 4 6 8 10)
* (r "summary" '(123 543 3242 8934 234 643)) (123.0d0 311.2d0 593.0d0 2286.0d0 2592.0d0 8934.0d0)