Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Are there any official naming conventions for R?

Tags:

r

Most programming languages have official naming conventions for functions, parameters, classes, etc. Official here means that the conventions are issued by the organization behind the language.

Are there any official naming conventions for R?

I'm aware that naming conventions and R have been discussed before on stackoverflow, but that was some time ago and my question is not "what naming convention do you prefer?" but rather concerns whether official naming conventions exist.

like image 911
Rasmus Bååth Avatar asked Apr 04 '12 14:04

Rasmus Bååth


2 Answers

The R Developer Page contains "more or less finalized ideas and plans for the R statistical system" from R-core. It does not contain any information about naming conventions. A brief look at the core R code will confirm this.

like image 187
Joshua Ulrich Avatar answered Nov 07 '22 01:11

Joshua Ulrich


R-core have a coding standards guide, but this does not include variable naming conventions.

Bioconductor also has a coding standards guide, which recommends lowerCamelCase.

There are links to those and several other style-guides here.

like image 13
Richie Cotton Avatar answered Nov 07 '22 01:11

Richie Cotton