Skip to Content
高效R语言编程
book

高效R语言编程

by Colin Gillespie, Robin Lovelace
August 2018
Intermediate to advanced
227 pages
4h 16m
Chinese
China Electric Power Press Ltd.
Content preview from 高效R语言编程
高效学习
195
帮助文件中另外一个有用的内容是 See Also:。在 optim() 帮助页中,它关
optimize()可能更合适该例。
阅读
R
源代码
R
是开源的。这意味着我们可查看源代码并检验所有函数。当然代码是复杂的,
直接进入到源代码中意义不大。
然而,留意
GitHub
上的
R
源代码镜像(
https://
github.com/wch/r-source/
)将有利于监视小的变动。这是一个切入到复杂代码
的好方法。类似地,检查类似 NCOL 函数的小型函数的源代码可获得很多有用
信息(例如 getFunction("NCOL"))。
跟踪
R
的未来变动的最简单办法是订阅
R
新闻组(
https://developer.
r-project.org/blosxom.cgi/R-devel/NEWS/
)。
很多
R
包在
GitHub
r-forge
上开放开发。选一些知名包并检查它们的源
代码。
drat
包(
https://github.com/eddelbuettel/drat
)是很好的入门包。
Dirk
Eddelbuettel
Rcpp
的作者)开发相对比较简单的包,仅包含几个函数。由
关键的
R
包作者之一给出关于软件开发的优秀指引。
RStudio IDE
提供了浏览
R
源代码的捷径:单击该函数而后按
F2
键,将在文
件编辑器中打开它的源代码。
该方法对
R
自有以及包函数有效,并对你在
R
脚本中(只要他在你的工程目录下)编写的函数也有效。
尽管阅读源代码可
能绕在其中,最好的办法是具体的问题环境下
,
例如“如何在我自己函数中将 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

数据科学之编程技术:使用R进行数据清理、分析与可视化

数据科学之编程技术:使用R进行数据清理、分析与可视化

迈克尔 弗里曼, 乔尔 罗斯
R数据科学

R数据科学

Hadley Wickham, Garrett Grolemund

Publisher Resources

ISBN: 9787519820855