Re: [Rd] Underscores in package names

2019-08-16 Thread Kevin Wright
I've heard the arguments against dots in names many times. The t.test and data.frame examples have been repeated so often that it has become accepted as gospel. In my experience, evidence of any actual problems is fairly limited (almost non-existent). I've been happily using dots in function

Re: [Rd] Underscores in package names

2019-08-16 Thread Jan Gorecki
Thanks Abby and Martin, In every company I worked using R - 3 in total - there was at least one (up to ~10) processes designed (dev and implemented) to depend on current package naming scheme, having underscore as separator of package name and its version. From my experience I believe this is a

Re: [Rd] Underscores in package names

2019-08-15 Thread Abby Spurdle
> While > package names are not functions, using dots in package names > encourages the use of dots in functions, a dangerous practice. "dangerous"...? I can't understand the necessity of RStudio and Tiny-Verse affiliated persons to repeatedly use subjective and unscientific phrasing. Elegant,

Re: [Rd] Underscores in package names

2019-08-15 Thread Jim Hester
Martin, Thank you for discussing this amongst R-core and for detailing the R-core discussion here. Some specific examples where having underscores available would have been useful. 1. My primerTree package (2013) was originally primer_tree, but I had to change the name to camelCase to comply

Re: [Rd] Underscores in package names

2019-08-14 Thread Martin Maechler
> Duncan Murdoch > on Fri, 9 Aug 2019 20:23:28 -0400 writes: > On 09/08/2019 4:37 p.m., Gabriel Becker wrote: >> Duncan, >> >> >> On Fri, Aug 9, 2019 at 1:17 PM Duncan Murdoch > > wrote: >> >> On 09/08/2019 2:41 p.m.,

Re: [Rd] Underscores in package names

2019-08-12 Thread Stephen Ellison
n...@r-project.org] On Behalf Of neonira > Arinoem > Sent: 09 August 2019 20:39 > To: Ben Bolker > Cc: r-devel@r-project.org > Subject: Re: [Rd] Underscores in package names > > > Naming policies are always tricky. The one proposed by Hadley, as the one > proposed by G

Re: [Rd] Underscores in package names

2019-08-09 Thread robin hankin
Having written the 'lorentz' ,'Davies' and 'schwarzschild' packages, I'm interested in packages that are named for a particular person. There are (by my count) 34 packages on CRAN like this, with names that are the surname of a particular (real) person. Of these 34, only 7 are capitalized.

Re: [Rd] Underscores in package names

2019-08-09 Thread Duncan Murdoch
On 09/08/2019 4:37 p.m., Gabriel Becker wrote: Duncan, On Fri, Aug 9, 2019 at 1:17 PM Duncan Murdoch > wrote: On 09/08/2019 2:41 p.m., Gabriel Becker wrote: > Note that this proposal would make mypackage_2.3.1 a valid *package name*, > whose

Re: [Rd] Underscores in package names

2019-08-09 Thread Gabriel Becker
Duncan, On Fri, Aug 9, 2019 at 1:17 PM Duncan Murdoch wrote: > On 09/08/2019 2:41 p.m., Gabriel Becker wrote: > > Note that this proposal would make mypackage_2.3.1 a valid *package > name*, > > whose corresponding tarball name might be mypackage_2.3.1_2.3.2 after a > > patch. Yes its a silly

Re: [Rd] Underscores in package names

2019-08-09 Thread Ben Bolker
Ugh, but not *as* ambiguous as the proposed example (you can still split unambiguously on "_"; yes, you could split on "last _" in Gabriel's example, but ...) On 2019-08-09 4:17 p.m., Duncan Murdoch wrote: > On 09/08/2019 2:41 p.m., Gabriel Becker wrote: >> Note that this proposal would make

Re: [Rd] Underscores in package names

2019-08-09 Thread Duncan Murdoch
On 09/08/2019 10:23 a.m., Jim Hester wrote: To be clear, I'd be happy to contribute code to make this work, with the changes mentioned by Duncan and elsewhere in the codebase, if someone on R-core was interested in reviewing it. You seem to have ignited a lot of discussion. Just to add my own

Re: [Rd] Underscores in package names

2019-08-09 Thread Duncan Murdoch
On 09/08/2019 2:41 p.m., Gabriel Becker wrote: Note that this proposal would make mypackage_2.3.1 a valid *package name*, whose corresponding tarball name might be mypackage_2.3.1_2.3.2 after a patch. Yes its a silly example, but why allow that kind of ambiguity? CRAN already has a package

Re: [Rd] Underscores in package names

2019-08-09 Thread neonira Arinoem
Yes Brian. That's currently possible. I am not speaking of what is currently possible but of the rules we should enforce, using both strict compliance for new rules and lazy compliance for older packages Le ven. 9 août 2019 à 21:35, Brian G. Peterson a écrit : > On 2019-08-09 14:27, neonira

Re: [Rd] Underscores in package names

2019-08-09 Thread Gabriel Becker
Neonira, On Fri, Aug 9, 2019 at 12:27 PM neonira Arinoem wrote: > I do not follow you Gabriel. Package name must not use digit numbers. > Tarbal will use them, taken from the DESCRIPTION file, version field. > I was referring to Jim Hester's original proposal, which AFAIU was just to add "_"

Re: [Rd] Underscores in package names

2019-08-09 Thread neonira Arinoem
Naming policies are always tricky. The one proposed by Hadley, as the one proposed by Google, are usable but not optimal according to most common needs, that are 1. Name a package 2. Name a class 3. Name a function 4. Name a parameter of a function 5. Name a variable My approach is the

Re: [Rd] Underscores in package names

2019-08-09 Thread Brian G. Peterson
On 2019-08-09 14:27, neonira Arinoem wrote: I do not follow you Gabriel. Package name must not use digit numbers. Tarbal will use them, taken from the DESCRIPTION file, version field. That's why I consider the weird case name you presented as irrelevant, and not to be considered. ggplot2 ?

Re: [Rd] Underscores in package names

2019-08-09 Thread neonira Arinoem
I do not follow you Gabriel. Package name must not use digit numbers. Tarbal will use them, taken from the DESCRIPTION file, version field. That's why I consider the weird case name you presented as irrelevant, and not to be considered. Le ven. 9 août 2019 à 20:41, Gabriel Becker a écrit : >

Re: [Rd] Underscores in package names

2019-08-09 Thread Gabriel Becker
On Fri, Aug 9, 2019 at 11:05 AM neonira Arinoem wrote: > Won't it be better to have a convention that allows lowercase, dash, > underscore and dot as only valid characters for new package names and keep > the ancient format validation scheme for older package names? > Validation isn't the only

Re: [Rd] Underscores in package names

2019-08-09 Thread Tobias Verbeke
> Creeping code complexity ... > > I like to think that the cuteR names will have a Darwinian > disadvantage in the long run. FWIW Hadley Wickham argues (rightly, I > think) against mixed-case names: > http://r-pkgs.had.co.nz/package.html#naming. Good development environments will offer content

Re: [Rd] Underscores in package names

2019-08-09 Thread Ben Bolker
Creeping code complexity ... I like to think that the cuteR names will have a Darwinian disadvantage in the long run. FWIW Hadley Wickham argues (rightly, I think) against mixed-case names: http://r-pkgs.had.co.nz/package.html#naming. I too am guilty of picking mixed-case package names in

Re: [Rd] Underscores in package names

2019-08-09 Thread neonira Arinoem
Won't it be better to have a convention that allows lowercase, dash, underscore and dot as only valid characters for new package names and keep the ancient format validation scheme for older package names? This could be implemented by a single function, taking a strictNaming_b_1 parameter which

Re: [Rd] Underscores in package names

2019-08-09 Thread Gabriel Becker
Hi Jim, While its true that it wouldn't be *particularly *hard^^ to adapt the base code to change this, there is certainly a non-zero amount of user/package code that relies on the well-defined package tarball naming scheme as well. I know because I've written some myself in switchr/GRAN* but I

Re: [Rd] Underscores in package names

2019-08-09 Thread Kevin Wright
Please, no. I'd also like to disallow uppercase letters in package names. For instance, the cuteness of using a capital "R" in package names is outweighed by the annoyance of trying to remember which packages use an upper-case letter. On Thu, Aug 8, 2019 at 9:32 AM Jim Hester wrote: > Are

Re: [Rd] Underscores in package names

2019-08-09 Thread Jim Hester
To be clear, I'd be happy to contribute code to make this work, with the changes mentioned by Duncan and elsewhere in the codebase, if someone on R-core was interested in reviewing it. Jim On Thu, Aug 8, 2019 at 11:05 AM Duncan Murdoch wrote: > > On 08/08/2019 10:31 a.m., Jim Hester wrote: > >

Re: [Rd] Underscores in package names

2019-08-08 Thread Duncan Murdoch
On 08/08/2019 10:31 a.m., Jim Hester wrote: Are there technical reasons that package names cannot be snake case? This seems to be enforced by `.standard_regexps()$valid_package_name` which currently returns "[[:alpha:]][[:alnum:].]*[[:alnum:]]" Is there any technical reason this couldn't

[Rd] Underscores in package names

2019-08-08 Thread Jim Hester
Are there technical reasons that package names cannot be snake case? This seems to be enforced by `.standard_regexps()$valid_package_name` which currently returns "[[:alpha:]][[:alnum:].]*[[:alnum:]]" Is there any technical reason this couldn't be altered to accept `_` as well, e.g.