similar to: foreign: write.xport

Displaying 20 results from an estimated 1000 matches similar to: "foreign: write.xport"

2007 Jun 04
3
test for nested factors
Is there a conventional way to test for nested factors? I.e., if 'a' and 'b' are lists of same-length factors, does each level specified by 'a' correspond to exactly one level specified by 'b'? The function below seems to suffice, but I'd be happy to know of a more succinct solution, if it already exists. Thanks, Tim. --- "%nested.in%" <-
2007 Jun 08
4
logical 'or' on list of vectors
Suppose I have a list of logicals, such as returned by lapply: Theoph$Dose[1] <- NA Theoph$Time[2] <- NA Theoph$conc[3] <- NA lapply(Theoph,is.na) Is there a direct way to execute logical "or" across all vectors? The following gives the desired result, but seems unnecessarily complex. as.logical(apply(do.call("rbind",lapply(Theoph,is.na)),2,"sum"))
2006 Apr 06
2
prevent reassignment of function names
Hi. I'm trying to find a systematic way to prevent assignment to names of existing functions. I've tried reassigning to the assignment operator, with mixed results. The function definition for "<-" below works as hoped for the demonstrated assignments to a and c. However, for the assignment based on the test function, it appears that the formal argument is not
2007 Sep 27
3
testing the contents of an environment
Suppose I want to delete everything in my working directory that is not a function. It seems that sapply(ls(),is.function) always returns FALSE, because ls() returns objects of mode character. How do I evaluate is.function(), not on a character string, but on the object that character string represents? Thanks, Tim
2007 Apr 05
1
Extent of time zone vulerability for POSIX date and time classes
Hi. I frequently convert date and time data to and from character representations. I'm frustrated with chron, because 'seconds' are required to create a time object (my input data never has seconds). More importantly, I cannot make chron print the format 12/30/2006 (which my output data requires). I really like the format flexibility of strftime() and strptime(), but of course
2009 May 30
2
degraded performance with rank()
Hi. I'm maintaining a package that creates an object that is essentially a classed version of numeric. I updated recently from 2.7.1 to 2.9.0, and merges involving my class suddenly took a huge performance hit. I've traced the problem to something near rank(). From NEWS, it seems rank() etc. changed in 2.8.0. Methods for xtfrm() are supposed to help, but I've had no success. There
2007 Feb 27
1
fitting the gamma cumulative distribution function
Hi. I have a vector of quantiles and a vector of probabilites that, when plotted, look very like the gamma cumulative distribution function. I can guess some shape and scale parameters that give a similar result, but I'd rather let the parameters be estimated. Is there a direct way to do this in R? Thanks, Tim. week <- c(0,5,6,7,9,11,14,19,39) fraction <-
2008 Feb 25
1
Read.xport function in package foreign
Hi All, Sorry that I didn't provide enough information. I've been trying to import SAS xport files that contain multiple files using package foreign's read.xport. I first attempted this back in 2005 and had problems. Some of files that were present in the SAS xport file weren't being created in R. I submitted my problem to the community:
2004 Nov 23
3
Problem with read.xport() from foreigh package (PR#7389)
Full_Name: Ruskin Chow Version: R 2.0.1 OS: Windows 2000 Submission from: (NULL) (203.169.154.66) Data imported from SAS using read.xport() in package foreign are converted to <NA> when the SAS data field consists of character strings that are only one character long. This is apparently a previously reported bug and perhaps fixed in some platform other than Windows (rw2001).Some
2001 Dec 03
0
Segfault in foreign:read.xport (PR#1192)
I get a segfault when trying to read a SAS transport file with rather long rows using read.xport from package foreign (version 0.4-7). The culprit seems to be these lines in xport_read in SASxport.c: 590 } else { 591 c = strchr(tmpchar, ' '); 592 *c = '\0'; 593
2013 Feb 02
1
setGeneric() gives "must supply skeleton" when checking package
r-devel, In a development version of the CRAN package metrumrg, I write ... require(reshape) setGeneric('cast') setOldClass(c('keyed','data.frame')) setMethod('cast','keyed', function ...) The result is satisfactory when sourcing the code directly, but when checking the package (which has 'reshape' as a dependency in the DESCRIPTION file) I get
2007 Oct 08
2
R and FDA trials
Yesterday I just noticed the new document on R and regulatory aspects for biomedical research posted at http://www.r-project.org/doc/R-FDA.pdf Coming from an institution that performs a large number of clinical trials for FDA and being an advocate of R myself, I have found that the following issues usually come up when discussing the use of R for FDA trials: 1. Most FDA submissions come down to
2005 Jul 14
3
read.xport
I am trying to import data from a SAS XPORT file that contains 24 SAS files. When I use the "read.xport" procedure only about 16 data frames (components) are created. Any suggestions? ************************************************************************* Gary A. Nelson, Ph.D Massachusetts Division of Marine Fisheries 30 Emerson Avenue Gloucester, MA 01930 Phone: (978)
2013 Apr 11
4
Understanding contents of packages
Colleagues During the transition to R3.0.0 (OS X), one of the packages that I used -- SASxport -- did not work until I used the "type=source" option in install.packages. This led to an adventure: 1. I downloaded the package source: SASxport_1.2.4.tar.gz 2. in the SASxport/R folder, I found all the functions that are part of the package. I became interested in whether I could
2002 Dec 20
1
read.xport and lookup.xport in foreign (PR#2385)
Under platform i686-pc-linux-gnu arch i686 os linux-gnu system i686, linux-gnu status major 1 minor 6.1 year 2002 month 11 day 01 language R and using foreign 0.5-8 I am encountering errors when using read.xport. Here's
2004 Mar 26
1
lookup.xport in foreign ignoring some datasets (PR#6701)
The Details. In the following version. > version _ platform i386-pc-linux-gnu arch i386 os linux-gnu system i386, linux-gnu status major 1 minor 8.1 year 2003 month 11 day 21 language R > lookup.xport ignores some datasets in sas export file. File "emptySasData3.xpt" (available at http://biostat.mc.vanderbilt.edu/tmp/emptySasData3.xpt) is a
2002 Apr 26
1
Problem with read.xport() from foreign package
I have found that data imported from SAS using read.xport() in package foreign (installed recently) does not match the original data, when the data consists of character strings that are only one character long. Here is an example. ---- SAS commands to create the data ---- options nocenter; data foo; a='a'; b='bb'; length c d $2; c='c'; d='
2001 May 05
1
read.xport bug of foreign pkg (PR#933)
Full_Name: Jorge A. Tomasevic Version: 1.2.2 OS: Win98 Submission from: (NULL) (146.83.23.177) As i'm not an "R-expert-user", i will describe what i do: i) open Rgui.exe ii) ivoke foreign library : >library(foreign) iii) i try to read an .xpt file (from Systat 9): >datos <- read.xport('ipoisson.xpt') iv) then the program crashes. Norton CrashGuard alerts the
2002 Mar 28
0
Enhancement request: lookup.xport() in library foreign
I installed the foreign library yesterday, and have successfully used the read.xport() function to get data from SAS. This is very helpful. SAS "date" and "datetime" variables become numeric variables, which is, of course, what they really are in SAS. Naturally, it is desirable to convert them to date/time objects in R. Looking at the documentation for the SAS transport
2010 Dec 28
4
Reading sas7bdat files into R
Hi All, I am trying to import a .sas7bdat file into R. I tried using Hmisc package's sasxport.get() function. temp <- sasxport.get("path\abcd.sas7bdat") I get an error that says "Error in lookup.xport(file) : file not in SAS transfer format" I am not familiar with SAS transfer format. Could somebody please clarify what is it that I am missing, Thanks for your