Re: [Rd] Error in loadNamespace(name) (PR#9464)
Thank you for your reply. There is some more information that may help your reproduce the error. The .RData file was generated under MSWindows. I started with an empty workspace and generated an object by y <- runif(200) or very similar. the quit, saving the workspace. (NTFS partition) I then logged out of Windows, logged into Lunix (Ubuntu Edgy Eft), cd'ed to where the .RData file lived and tried to start R. I have had the same experience with larger (real) workspaces. If I remove the .RData file there is no problem. Regards Ross Darnell Prof Brian Ripley wrote: > There is nothing here to reproduce. > It clearly depends on your .RData, which is not available to us. > Unless you can make it available, we cannot help. > > On Thu, 25 Jan 2007, [EMAIL PROTECTED] wrote: > >> Full_Name: Ross Darnell >> Version: 2.4.1 >> OS: Linux >> Submission from: (NULL) (130.102.133.33) >> >> >> [EMAIL PROTECTED]:~/Data$ ls -al .RData >> -rwxrwxrwx 2 root root 13551 2006-12-06 08:58 .RData >> [EMAIL PROTECTED]:~/Data$ R >> >> R version 2.4.1 (2006-12-18) >> Copyright (C) 2006 The R Foundation for Statistical Computing >> ISBN 3-900051-07-0 >> >> R is free software and comes with ABSOLUTELY NO WARRANTY. >> You are welcome to redistribute it under certain conditions. >> Type 'license()' or 'licence()' for distribution details. >> >> Natural language support but running in an English locale >> >> R is a collaborative project with many contributors. >> Type 'contributors()' for more information and >> 'citation()' on how to cite R or R packages in publications. >> >> Type 'demo()' for some demos, 'help()' for on-line help, or >> 'help.start()' for an HTML browser interface to help. >> Type 'q()' to quit R. >> >> Error in loadNamespace(name) : there is no package called 'lattice' >> Fatal error: unable to restore saved data in .RData >> >> [EMAIL PROTECTED]:~/Data$ R --no-restore-data >> >>> load(".RData") >> Error in loadNamespace(name) : there is no package called 'lattice' >> >> >> >> --please do not edit the information below-- >> >> Version: >> platform = i486-pc-linux-gnu >> arch = i486 >> os = linux-gnu >> system = i486, linux-gnu >> status = >> major = 2 >> minor = 4.1 >> year = 2006 >> month = 12 >> day = 18 >> svn rev = 40228 >> language = R >> version.string = R version 2.4.1 (2006-12-18) >> >> Locale: >> LC_CTYPE=en_AU.UTF-8;LC_NUMERIC=C;LC_TIME=en_AU.UTF-8;LC_COLLATE=en_AU.UTF-8;LC_MONETARY=en_AU.UTF-8;LC_MESSAGES=en_AU.UTF-8;LC_PAPER=en_AU.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_AU.UTF-8;LC_IDENTIFICATION=C >> >> >> >> Search Path: >> .GlobalEnv, package:stats, package:graphics, package:grDevices, >> package:utils, >> package:datasets, package:methods, Autoloads, package:base >> >> __ >> R-devel@r-project.org mailing list >> https://stat.ethz.ch/mailman/listinfo/r-devel >> > __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] [Fwd: Re: [R-downunder] Beware unclass(factor)] (PR#9641)
This is a multi-part message in MIME format. --040101030901070905010208 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit The following "issue" was found using > version _ platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major 2 minor 4.1 year 2006 month 12 day18 svn rev40228 language R version.string R version 2.4.1 (2006-12-18) > and discussed on the R-downunder mailing list. I hope I have provided enough info. I tried to look at the Bugs Tracking page but got--- The system encountered a fatal error * cannot open config file /home/sfe/r-bugs/jitterbug/R : No such file or directory * The last error code was: No such file or directory uid/gid=30/8 Regards Ross Darnell --040101030901070905010208 Content-Type: message/rfc822; name="Re: [R-downunder] Beware unclass(factor)" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="Re: [R-downunder] Beware unclass(factor)" Return-path: <[EMAIL PROTECTED]> Received: from mail2a.soe.uq.edu.au (mail2a.soe.uq.edu.au [130.102.3.87]) by MAILSTORE (The University of Queensland Central Mail System) with ESMTP id <[EMAIL PROTECTED]> for [EMAIL PROTECTED]; Mon, 30 Apr 2007 19:26:41 +1000 (EST) Received: from mailhub4.uq.edu.au (mailhub4.uq.edu.au [130.102.149.131]) by MAILSTORE (The University of Queensland Central Mail System) with ESMTP id <[EMAIL PROTECTED]> for [EMAIL PROTECTED]; Mon, 30 Apr 2007 19:26:41 +1000 (EST) Received: from customer-domains.icp-qv1-irony10.iinet.net.au (customer-domains.icp-qv1-irony10.iinet.net.au [203.59.1.145]) by mailhub4.uq.edu.au (8.13.8/8.13.8) with ESMTP id l3U9QcOd021380 for <[EMAIL PROTECTED]>; Mon, 30 Apr 2007 19:26:41 +1000 Received: from 203-173-2-10.dyn.iinet.net.au (HELO [192.168.0.2]) ([203.173.2.10]) by iinet-mail.icp-qv1-irony10.iinet.net.au with ESMTP; Mon, 30 Apr 2007 17:25:10 +0800 Date: Mon, 30 Apr 2007 19:25:09 +1000 From: John Maindonald <[EMAIL PROTECTED]> Subject: Re: [R-downunder] Beware unclass(factor) In-reply-to: <[EMAIL PROTECTED]> To: Ross Darnell <[EMAIL PROTECTED]> Cc: [EMAIL PROTECTED] Message-id: <[EMAIL PROTECTED]> MIME-version: 1.0 (Apple Message framework v752.3) X-Mailer: Apple Mail (2.752.3) Content-type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Content-transfer-encoding: 7bit X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgRTNUbLrQIKUGdsb2JhbAANj3wBASo X-IronPort-AV: i="4.14,469,1170601200"; d="scan'208"; a="80792155:sNHT7461584868" X-Sorbs: not_in_sorbs X-Spam-Score: 0 (), 5 = high X-UQ-Spam-Score: UQ-Spam-Score (0), 5 = high X-UQ-FilterTime: 1177925201 X-Scanned-By: MIMEDefang 2.58 on UQ Mailhub on 130.102.149.131 References: <[EMAIL PROTECTED]> Original-recipient: rfc822;[EMAIL PROTECTED] Observe the following > z <- model.frame(cbind(moths,(20-moths)) ~sex+ doselin,data=worms) > class(z$doselin) [1] "other" > levels(z$doselin) [1] "1" "2" "4" "8" "16" "32" > attributes(z$doselin) $levels [1] "1" "2" "4" "8" "16" "32" $class [1] "other" The problem surfaces in the call for model.frame() from predict.lm() when it is called by predict.glm(). This call is jumping to conclusions when it uses the presence of a levels attribute as an indication that doselin is a factor, ironic as it was the call that was initiated by glm that seems to have given the column doselin of the object returned by model.frame() the class "other". This seems to me to be a bug. The call to unclass() does not strip the levels attribute from doselin. (This is not, I think, the bug; rather the problem is in the model matrix that is created.) The column worms$doselin does though have class "integer", at least as far as the function class() is concerned. You can fix the problem by setting: worms$doselin <- as.vector(unclass(worms$Dose)) This strips off the levels attribute. In my view model.frame ought to have stripped the levels attribute from the column doselin in the object that it returned. I consider that this should be reported as a bug, or at least as an undesirable feature. John Maindonald email: [EMAIL PROTECTED] phone : +61 2 (6125)3473fax : +61 2(6125)5549 Centre for Mathematics & Its Applications, Room 1194, John Dedman Mathematical Sciences Building (Building 27) Australian National University, Canberra ACT 0200. On 30 Apr 2007, at 4:57 PM, Ross Darnell wrote: > Just an observation about the use of unclass() to generate codes > for factors. > > As an example take the dataset f
[Rd] Error in loadNamespace(name) (PR#9464)
Full_Name: Ross Darnell Version: 2.4.1 OS: Linux Submission from: (NULL) (130.102.133.33) [EMAIL PROTECTED]:~/Data$ ls -al .RData -rwxrwxrwx 2 root root 13551 2006-12-06 08:58 .RData [EMAIL PROTECTED]:~/Data$ R R version 2.4.1 (2006-12-18) Copyright (C) 2006 The R Foundation for Statistical Computing ISBN 3-900051-07-0 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. Natural language support but running in an English locale R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. Error in loadNamespace(name) : there is no package called 'lattice' Fatal error: unable to restore saved data in .RData [EMAIL PROTECTED]:~/Data$ R --no-restore-data > load(".RData") Error in loadNamespace(name) : there is no package called 'lattice' --please do not edit the information below-- Version: platform = i486-pc-linux-gnu arch = i486 os = linux-gnu system = i486, linux-gnu status = major = 2 minor = 4.1 year = 2006 month = 12 day = 18 svn rev = 40228 language = R version.string = R version 2.4.1 (2006-12-18) Locale: LC_CTYPE=en_AU.UTF-8;LC_NUMERIC=C;LC_TIME=en_AU.UTF-8;LC_COLLATE=en_AU.UTF-8;LC_MONETARY=en_AU.UTF-8;LC_MESSAGES=en_AU.UTF-8;LC_PAPER=en_AU.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_AU.UTF-8;LC_IDENTIFICATION=C Search Path: .GlobalEnv, package:stats, package:graphics, package:grDevices, package:utils, package:datasets, package:methods, Autoloads, package:base __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel