Displaying 20 results from an estimated 3000 matches similar to: "R Version Problem in using write.foreign+SAS"
2006 Dec 20
1
FW: R Version Problem in using write.foreign+SAS
Hi R experts,
I have a problem in Write.foreign command (SAS).
I have a data frame called d.
>d
Datetime
2006-12-01 00:00:00
2006-12-01 00:10:00
2006-12-01 00:20:00
2006-12-01 00:30:00
2006-12-01 00:40:00
>class(d$Datetime)
[1] "POSIXt" "POSIXct"
Then I tried with,
write.foreign(d,"Z:\\try_i.sas7bdat"," Z:\\try_i.sas
2006 Nov 24
1
Fwd: Dates Conversion/write.foreign
---------- Forwarded message ----------
From: Shubha Vishwanath Karanth <shubhak at ambaresearch.com>
Date: Nov 24, 2006 7:54 PM
Subject: Dates Conversion/write.foreign
To: Shubha Karanth <shubhakaranth at gmail.com>, Shubha Vishwanath
Karanth <shubhak at ambaresearch.com>
Hi R experts,
I need an urgent help...
I have an a dataframe caled idat. Below i give a snapshot
2006 Jul 13
1
writeForeignSAS and potential extensions
Dear R-devel,
I've made some potential extensions to writeForeignSAS
in 'foreign' that I wanted to pass along if anyone is
interested. I've attached the diff -u output against
the version found in foreign_0.8-15 and an .R file
with my changes. (In this .R file, the function is named
writeForeignSAS7 to simplify testing/comparisons.)
I've tried to alter the current
2007 Feb 13
5
Fatigued R
Hi R,
Please solve my problem...........
I am extracting Bloomberg data from R, in a loop. R is getting fatigued
by doing this process and gives some errors. I introduced sleep
function. Doing this sometimes I get the results and sometimes not. I
even noticed that if I give complete rest for R (don't open R window)
for 1 day and then run my code with the sleep function, then the
2008 Oct 13
2
SAS Data
Hello everybody,
I would like to read a SAS Data data1.sas7bdat in R! Is this possible?
Thank you a lot in advance ;),
Stefo
2019 Jun 04
1
foreign:::writeForeignSAS patch not released?
Hello,
In May 2018 there was some R-devel discussion about a bug in
foreign:::writeForeignSAS. See here:
https://stat.ethz.ch/pipermail/r-devel/2018-May/076220.html
and it resulted in a patch. See:
https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17256
And I see the changes in Subversion here:
https://svn.r-project.org/R-packages/trunk/foreign/R/writeForeignSAS.R
But I don't
2018 May 17
2
Patch for bug 17256 'possible bug in writeForeignSAS in the foreign library when string is NA'
Attached is a patch to fix https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=17256
'possible bug in writeForeignSAS in the foreign library when string is NA'
The patch
1. fixing the case where there were NA within a character column, and the case where all values are strings of length 0
2. general replacement of calls to `sapply` with `vapply` (and replacing any(is.na()) with
2006 Dec 02
4
Fwd: Urgent Help in Paste Command
Hi Experts,
I want to see my object as below:
'C:\Program Files\R\R-2.4.0\bin\Rgui.exe'
So I use the paste command. None of the below is working. Could anyone help
me on this?
> paste("'C:\Program Files\R\R-2.4.0\bin\Rgui.exe'")
[1] "'C:Program FilesRR-2.4.0\binRgui.exe'"
> paste("'C:","\","Program
2009 Jan 03
1
Bug report in foreign library (PR#13425)
here appears to be a bug in the foreign library. The following code used to
work, but now generates an error when 'package="SAS"' is specified:
ds <- read.csv("http://www.math.smith.edu/sasr/datasets/help.csv")
# running foreign package version 0.8-30
library(foreign)
# this works fine
write.foreign(ds, "foo", "bar", package="Stata")
#
2009 Feb 02
3
Problem with foreign package
I tried to use write.foreign() to export to SAS this morning and got an
error.
When I looked at the code for writeForeignSAS() I saw this line:
dfn < -df
which I think should be
dfn <- df
So, I tried to run update.packages() to see if there was an updated
version and got the following result.
> update.packages(c("foreign"))
Warning message:
In list.files(lib) :
2006 Nov 16
5
<RBloomberg Package Problem>
Hi R-Experts,
I'm currently using R 2.4.0 in Windows XP. I'm trying to download data
from Bloomberg using the package "RBloomberg", but it fails to install
the three needed packages "zoo", "chron" and 'Rbloomberg". Moreover I
am not able to find "RBloomberg" package as windows binary in CRAN
site as only for MAC it's given. Please
2006 Dec 19
1
Problem in Dates
Hi Experts,
I have a problem in Dates.
I have a zoo object called 'intra'. And the class of index(intra) is
("Chron" "Dates" "Time"). I need to put the index of this zoo object into a
data frame. So I used,
idat<-data.frame(Datetime=as.POSIXlt(index(intra),"GMT"))
But I get the values of 'idat' to be:
"01joulu2006
2009 Jan 24
1
Calling R from SAS
Can I call R from SAS? I tried the below command in SAS, but not
working...
OPTIONS XWAIT XSYNC;
X "C:\Program Files\R\R-2.7.1\bin\R.exe --no-save -quiet
<""C:\TEMPO\program.r""> ""C:\TEMPO\program.log""";
Had done this before and it was working perfect... But now, not...
Sorry if this query was supposed to be put in SAS mailing
2005 Nov 14
2
Using pakage foreign and to import SAS file
Hi,
I'm struggling with foreign to import a SAS file. The file, for lack of imagination, is d.sas7bdat and is in my root directory (c:\) under Windows XP. When I type
read.ssd("c:\\", "d")
which I think I'm suppose to enter, I get
SAS failed. SAS program at C:\DOCUME~1\Owner\LOCALS~1\Temp\Rtmp32758\file19621.sas
The log file will be file19621.log in the current
2008 May 15
1
Reading SAS data into R
Hi R,
Suppose that SAS dataset 'tsubset1' is stored in the path, "Z:/data".
Then I give the below read.ssd() command to read SAS dataset,
'tsubset1.sas7bat' into R.
> library(foreign)
> s=read.ssd("Z:/data","tsubset1",sascmd = "C:/Program Files/SAS/SAS
9.1/sas.exe")
> s
A B C
1 3 4 5
2 6 7 8
3 3 4 5
It reads
2006 Nov 21
1
R dataframe into a SAS dataset
Hi experts,
The below is the code I wrote for expoting an R dataframe into a SAS
data set. I get the below error. So, what is the problem? Could somebody
help me on this?
* write.foreign(x,"Z:\\new","Z:\\new",package="SAS")
Error in file(file, ifelse(append, "a", "w")) :
unable to open connection
In addition: Warning
2010 Oct 20
1
Problem exporting data using write.foreign
My question is about the write.foreign() command in the foreign
package. I use a command like the following to try and output data
and a code file to read my data into SAS.
write.foreign(data.frame.object, datafile="filepath",
codefile="filepath", package="SAS", dataname="myData")
With my data set, it gives the following error:
Error in
2006 Mar 28
0
Help with the code
library(survival) library(boot) data=NULL lambda=NULL result=NULL pat=rep(1:102,each=1) trt=rep(c(1,0),51) status=rep(1,102) site=rep(1:51, each=2) nr.datasets=100 seed=2006 beta=log(1/2) for (i in 1:51) { lambda[i]=1+((3-1)/50)*(i-1)} lambda1=rep(lambda, each=2) dummy=rep(c(exp(beta),1),51) elf=lambda1*dummy r=70 #the number of bootstrap replicates
2011 Nov 11
1
Formula variable help
I have an R script with the following applicable lines:
xshort <- window(s, start=st, end=ed)
. . .
xshort <- ts(xshort, frequency=1, start=1)
. . .
m1 <- m2 <- m3 <- m4 <- m5 <- m6 <- NULL
m1 <- tslm(xshort ~ trend)
I get an error:
Error in get(dataname) : object 'xshort' not found
When I do traceback() I get:
3: get(dataname)
2: tslm(xshort ~
2011 Sep 20
1
Data
Hey everybody,
i am using the rugarch-package and its great!
I have a pretty easy problem, but i just dont get it, so thanks if you can
help me.
Normally i use:
/
data(DATANAME)
spec = ugarchspec()
fit = ugarchfit(data = x[,1], spec = spec)
fit
slotNames(fit)
names(fit at fit)
coef(fit)
infocriteria(fit)
likelihood(fit)
nyblom(fit)
signbias(fit)
head(as.data.frame(fit))
head(sigma(fit))