[R] FW: can't get package boot to load

Gary Smith gary.smith28 at comcast.net
Sat Jan 31 20:48:00 CET 2009


Changing 
library(RODBC,boot)
to
	library(RODBC)
	library(boot)
seems to have solved the problem.

  _____  

_____________________________________________
From: Gary Smith [mailto:gary.smith28 at comcast.net] 
Sent: Saturday, January 31, 2009 12:55 PM
To: 'r-help at R-project.org'
Subject: can't get package boot to load

Hi,
I am new to R and I'm totally confused by this problem.  I'm trying to load
data and run a simple correlation using corr() in the boot package.
Yesterday my code worked.  Today it can't find the function corr().  I've
tried searching the web and haven't found the root of my problem.  Apologies
if I've missed the obvious.
My code is simple:

install.packages('RODBC')
install.packages('boot')
library(RODBC,boot)
setwd("C:/Documents and Settings/Gary Smith/My Documents/Blog/")
data = odbcConnectExcel("LafferCurve2.xls")
mydata = sqlFetch(data,"Data")
n=23
m=73
gnp=mydata[[3]][n:m]
incTaxFirst=mydata[[7]][n:m]
corr(cbind(gnp,incTax))

Here are the console messages:

> install.packages('RODBC')
Warning: package 'RODBC' is in use and will not be installed
> install.packages('boot')
trying URL
'http://cran.stat.ucla.edu/bin/windows/contrib/2.8/boot_1.2-35.zip'
Content type 'application/zip' length 779420 bytes (761 Kb)
opened URL
downloaded 761 Kb

package 'boot' successfully unpacked and MD5 sums checked

The downloaded packages are in
        C:\Documents and Settings\Gary Smith\Local
Settings\Temp\RtmpRT1RUh\downloaded_packages
updating HTML package descriptions
> library(RODBC,boot)
> setwd("C:/Documents and Settings/Gary Smith/My Documents/Blog/")
> data = odbcConnectExcel("LafferCurve2.xls")
> mydata = sqlFetch(data,"Data")
> n=23
> m=73
> gnp=mydata[[3]][n:m]
> incTaxFirst=mydata[[7]][n:m]
> corr(cbind(gnp,incTax))
Error: could not find function "corr"
Using search(), I see:
[1] ".GlobalEnv"        "package:RODBC"    
 [3] "package:stats"     "package:graphics" 
 [5] "package:grDevices" "package:utils"    
 [7] "package:datasets"  "package:methods"  
 [9] "Autoloads"         "package:base"     

Typing "install.packages('boot')" at the prompt gets me the same result.

Thanks for any help.

Gary
_______________________________________
"Accept no assertions without evidence."  --Goompah wisdom from "Omega" by
Jack McDevitt--
________________________________________
"Nature is complete because it does not serve itself."  --"Tao De Jing" by
Lao Tze--



More information about the R-help mailing list