Skip to content
Prev 54044 / 398498 Next

Giving a first good impression of R to Social Scientists

Thomas Lumley wrote:
The usual way of teaching R seems to be bottom-up. Here's the command 
prompt, type some arithmetic, make some assignments, learn about 
function calls and arguments, write your own functions, write your own 
packages.

  Perhaps a top-down approach might help certain cases. People using 
point-n-click packages tend to use a limited range of analyses. Write 
some functions that do these analyses, or give them wrappers so that 
they get something like:

  > myData = readDataFile("foo.dat")
    Read 4 variables: Z, Age, Sex, Disease

  > analyseThis(myData, response="Z", covariate="Age")

   Z = 0.36 * Age, Significance level = 0.932

  or whatever. Really spoon feed the things they need to do. Make it 
really easy, foolproof.

  Then show them what's behind the analyseThis() function. How its not 
even part of the R distribution. How easy you made it for a beginner to 
do a complex and novel analysis. Then maybe it'll "click" for them, and 
they'll see how having a programming language behind their statistics 
functions lets them explore in ways not thought possible with the 
point-n-click paradigm. Perhaps they'll start editing analyseThis() and 
write analyseThat(), start thinking for themselves.

  Or maybe they'll just stare at you blankly...

Baz