From pauljohn32 at gmail.com  Mon Jun 20 18:30:20 2011
From: pauljohn32 at gmail.com (Paul Johnson)
Date: Mon, 20 Jun 2011 11:30:20 -0500
Subject: [Rd] requesting a mentor for R development
Message-ID: <BANLkTi=eHgitd8d==e18hpXvZTPTTdZgJg@mail.gmail.com>

I'd like to learn the process of revising R functions & packages and
then submitting proposed patches to the R Core team.  Would someone be
willing to mentor me through one example?

For starters, consider an example.  I'd like to revise the t.test
function to return the stderr value to the user.  We only need to
change the "rval" in the third-from-the end line of
stats:::t.test.default.

Change this:

 rval <- list(statistic = tstat, parameter = df, p.value = pval,
        conf.int = cint, estimate = estimate, null.value = mu,
        alternative = alternative, method = method, data.name = dname)
    class(rval) <- "htest"
    return(rval)

To this:

 rval <- list(statistic = tstat, parameter = df, stderr=stderr, p.value = pval,
        conf.int = cint, estimate = estimate, null.value = mu,
        alternative = alternative, method = method, data.name = dname)
    class(rval) <- "htest"
    return(rval)

Here is where I need help.

1. What other changes in the R code & documents would be required for
consistency?

2. How does R Core Team expect/accept patches?
I do understand a bit about SVN and CVS.  I think I could mark this up
and make a diff, but I'm uncertain about the details.

3. How would I best  prepare a suggestion like this so as to get it
accepted into R?

If somebody will raise a hand, I'm willing to do the work to learn.

pj
-- 
Paul E. Johnson
Professor, Political Science
1541 Lilac Lane, Room 504
University of Kansas



[Rd] requesting a mentor for R development
Paul Johnson