[R] Mac OSX Mavericks 10.9.3 Big Problem - New User

David Winsemius dwinsemius at comcast.net
Wed Jul 16 01:51:57 CEST 2014


On Jul 14, 2014, at 10:37 PM, Ryan Dallavia wrote:

> Thanks for your reply Jeff!
>
> install.packages('Lahman') was the first command typed and generated  
> the
> error leading to the var directory. Here's everything else that I've  
> got,
> per one of the how to ask a good question post.

There are binaries for pkg:Lahman at CRAN for both the SL and  
Mavericks versions of R for MacOS.

http://cran.r-project.org/web/packages/Lahman/index.html

We don't know what your default repository is. This is what I use:

 > getOption("repos")
                        CRAN
"http://cran.stat.ucla.edu"

>
>
> dput(Lahman)

Generally that would not be informative. The package is not an object  
in the workspace.


> Error in dput(Lahman) : object 'Lahman' not found

Your original error message suggested an error in spelling:

>>> Error: could not find function "intall.packages"


>
> I also ran the following . . .
>
>> sessionInfo()
> R version 3.1.1 (2014-07-10)
> Platform: x86_64-apple-darwin13.1.0 (64-bit)
>
> locale:
>
> [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
>
> attached base packages:
>
> [1] stats     graphics  grDevices utils     datasets  methods   base
>
> loaded via a namespace (and not attached):
> [1] tools_3.1.1

So this says that pkg:Lahman is not loaded at that time.


>
>
> I had been storing R commands, but now that I can't run any  
> meaningful commands
> related to my data, nothing is being stored at the moment.

Not sure what "storing R commands" means or what "can't run any  
meaning commands related to my data might mean either". You are not  
showing either code or error messages relating to this activity.


The message you got suggests that you _did_ install a package (perhaps  
SoDA?) in your .../User/Computer/Library/R/3.1/library/ directory. You  
can use this command to get a list of installed packages:

installed.packages()

For me that list is rather long (and is therefore omitted) but I  
suspect from your difficulties that you do not have very many  
contributed packages installed yet.

>
> Let me know if I need to provide anything else. Thanks for the input!

Less vague description. More code and error messages. This may or may  
not be a MacOS problem. It sould as though it is a problem with basic  
R commands to me. If it really is a MacOS installation problem, then  
this is the wrong mailing list.

PLEASE, stop sending HTML mail. This is a plain text mailing list.

-- 
David

>
> Cheers,
> RCD
>
>
> On Tue, Jul 15, 2014 at 12:13 AM, Jeff Newmiller <jdnewmil at dcn.davis.ca.us 
> >
> wrote:
>
>> Providing error messages without the inputs that provoked them  
>> leaves us
>> with only half a conversation to interpret. (For instance, what is  
>> with the
>> misspelling error?) It is also helpful when they are provided in the
>> sequence that they happened.
>>
>> I am going to make a wild guess that you loaded your previous  
>> variables,
>> perhaps automatically from the .RData file, but you don't remember  
>> which
>> packages to load to work with them. You only use the install.packages
>> function to get them into the R "library" directories (typically from
>> CRAN). You use the "library" or "require" functions to pull them into
>> memory each time you restart R to do some analysis. Usually it is  
>> best to
>> store the sequence of R statements that do your analysis in a .R  
>> file. You
>> can then just run all the commands in that file later when you have
>> forgotten how you did your analysis the first time.
>>
>> The fact that loading your variables from the .RData file does not  
>> also
>> reload the packages you need to do your analysis is a pain. I  
>> prefer to not
>> use RData files at all since the R file can both load those needed  
>> packages
>> and remind me how the analysis was done.
>>
>> You should read about how to ask clear questions, such as at [1],  
>> and read
>> the Posting Guide mentioned at the bottom of this email which  
>> points out
>> that you should post in plain text or we might not see what you see.
>>
>> [1]
>> http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example
>> ---------------------------------------------------------------------------
>> Jeff Newmiller                        The     .....       .....  Go  
>> Live...
>> DCN:<jdnewmil at dcn.davis.ca.us>        Basics: ##.#.       ##.#.  Live
>> Go...
>>                                      Live:   OO#.. Dead: OO#..   
>> Playing
>> Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
>> /Software/Embedded Controllers)               .OO#.       .OO#.   
>> rocks...1k
>> ---------------------------------------------------------------------------
>> Sent from my phone. Please excuse my brevity.
>>
>> On July 14, 2014 6:38:53 PM PDT, Ryan Dallavia <rcdall at gmail.com>  
>> wrote:
>>> Hello,
>>>
>>> I am new to this program. I initially installed both R and R  
>>> Studio 3
>>> months ago, easily and got a d-base icon from the package I  
>>> needed, and
>>> saw
>>> my tables in spreadsheet form in studio. Now, everything has
>>> disappeared on
>>> its own -seriously nothing changed.  When trying to get my package
>>> back, I
>>> get this:
>>>
>>> Error: could not find function "intall.packages"
>>> Installing package into ���/Users/Computer/Library/R/3.1/ 
>>> library���
>>> (as ���lib��� is unspecified)
>>> trying URL '
>>>
>> http://ftp.ussg.iu.edu/CRAN/bin/macosx/mavericks/contrib/3.1/SoDA_1.0-6.tgz
>> '
>>> Content type 'application/x-gzip' length 255365 bytes (249 Kb)
>>> opened URL
>>> ==================================================
>>> downloaded 249 Kb
>>> The downloaded binary packages are in
>>>
>>
>>> /var/folders/bd/7z7gw4w953sd0tmgsrhdqw680000gn/T//RtmpTAMQLx/ 
>>> downloaded_packages
>>>
>>> var is a private directory. Though I can pull individual tables from
>>> the
>>> package (Lahman), they are now unlinked. SQL and stat commands are
>>> rejected
>>> by R and Studio. I tried about 2 dozen methods of changing the
>>> directory,
>>> specifying .lib and libPaths, (at least the ones online I  
>>> understood),
>>> and
>>> nothing worked, I moved the package (Lahman) to an R directory,  
>>> but I
>>> did
>>> not see it, and there seems to be no way to turn it back into a  
>>> working
>>> d-base in the working dir complete with icon suggesting it is locked
>>> and
>>> loaded. I have tried clean installs of everything, yet R-Studio  
>>> seems
>>> to
>>> remember what I did last (I don't know how). I need this back the  
>>> way
>>> it
>>> was: a functioning d-base from Lahman package in R-Studio and R.
>>> Suggestions seriously needed. It seems unfixable, and the "var'  
>>> problem
>>> seems very rare. Thanks for reading this.
>>>
>>> Cheers,
>>> RCD
>>>
>>>      [[alternative HTML version deleted]]

>>
>>
>
> 	[[alternative HTML version deleted]]
>


David Winsemius, MD
Alameda, CA, USA



More information about the R-help mailing list