similar to: Concatenating data frames in R versus SAS

Displaying 20 results from an estimated 4000 matches similar to: "Concatenating data frames in R versus SAS"

2012 Aug 24
1
if then in R versus SAS
I am new to R and I have the following SAS statements: if otype='M' and ocond='1' and entry='a.Prop' then MOC=1; else MOC=0; How would I translate that into R code? Thanks in advance -- View this message in context: http://r.789695.n4.nabble.com/if-then-in-R-versus-SAS-tp4641225.html Sent from the R help mailing list archive at Nabble.com.
2012 May 22
2
Best way to locate R executable from within R?
Hi, I'd like to spawn of a new R process from within R using system(), e.g. system("R -f myScript.R"). However, just specifying "R" as in that example is not guaranteed to work, because "R" may not be on the OS's search path. What is the best way, from within a running R, to infer the command (basename or full path) for launching R in way that it works on
2012 Oct 10
3
How to replicate SAS by group processing in R
Hello, I am trying to re-code all my programs from SAS into R. In SAS I use the following code: proc sort data=upper; by tdate stock_symbol expire strike; run; data upper1; set upper; by tdate stock_symbol expire strike; if first.expire then output; rename strike=astrike; run; on the following data set: tdate stock_symbol expiration strike 9/11/2012 C 9/16/2012
2012 Nov 15
3
Can you have a by variable in Lag function as in SAS
Hello, I want to use lag on a time variable but I have to take date into consideration ie I don't want days to overlap ie: I don't want my first time of today to match my last time of yeterday. In SAS I would use : data x; set y; by date tim; previous=lag(tim); if first.date then do; previous=.; end; run; How can I do something similar in R? I can't find
2020 Jun 29
2
-specs=/usr/lib/rpm/redhat/redhat-hardened-ld woes
In the rgdal package, configure.ac has had : ${LDFLAGS=`"${RBIN}" CMD config LDFLAGS`} at least since 2012, so picking up LDFLAGS known to the R version installed. Very recently, users installing rgdal from source with R installed from RPM are seeing problems, such as those reported in this thread: https://stat.ethz.ch/pipermail/r-sig-geo/2020-June/028251.html The diagnosis by
2009 Oct 09
0
Make error, fails to install base packages (e.g., 'method')
I am trying to build R-2.9.2 from source on a Slax Linux distribution. The only warnings from configure related to the production of the html. However, a series of errors occurs at the end of 'make': ----------- make[2]: Entering directory `/root/Desktop/Rbin/src/library' mkdir -p -- ../../library make[3]: Entering directory `/root/Desktop/Rbin/src/library/profile' building
2006 Jun 04
1
foxGUIb v0.7 (for FXRuby 1.6)
dear (FX)Ruby hackers, lyle has released FXRuby 1.6.0 some days ago. so it was a good opportunity for me to fix some more bugs and release annother version of foxGUIb which is tested against FXRuby 1.6.0. the most interesting feature Fox1.6 brings to you is unicode support. (see foxGUIb/test/unicode_test_japanese.rbin) thanks for all the feedback and the bug reports. enjoy ;) -- henon
2020 Jun 29
1
-specs=/usr/lib/rpm/redhat/redhat-hardened-ld woes
On Mon, 29 Jun 2020 at 11:24, I?aki Ucar <iucar at fedoraproject.org> wrote: > > On Mon, 29 Jun 2020 at 10:21, Roger Bivand <Roger.Bivand at nhh.no> wrote: > > > > In the rgdal package, configure.ac has had : ${LDFLAGS=`"${RBIN}" CMD > > config LDFLAGS`} at least since 2012, so picking up LDFLAGS known to the R > > version installed. Very
2006 Feb 18
1
file.info() on WinXP/NTFS > 2Gb
Hi, on WinXP Pro SP2 with NTFS, I noticed that file.info() under Rv2.2.1pat (2006-02-09) does not report the correct file size if the file is >= 2^31 bytes (2GB). Is this problem known? Is this related to the note in ?file.info: "Some (broken) systems allow files of more than 2Gb to be created but not accessed by the 'stat' system call. Such files will show up as non-readable
2012 Sep 13
1
Paasing values to sqlQuery like SAS macro
Hello, We lost our SAS licence & I am busy transfering my old SAS programs to R environment. I am very new to R. In 1 program I was creating SAS macro vars & passing them into a SQL query to run against the server. There are 3 variables firm, begindt, enddt. # of values for each varies month to month. Is there anyway I could do the same thing in R & pass the afore mentioned values
2004 Jun 07
1
Xtable giving an interesting problem
I'm using the current version of xtable for 1.9.0 and I have an interesting error: Error in match.names(clabs, names(xi)) : names don't match previous names: F value, Pr(>F) In addition: Warning message: longer object length is not a multiple of shorter object length in: clabs == nmi This is produced in the following manner: >data.trans <-
2007 Mar 05
3
Rbind with data frames -- column names question
As part of my work, I am trying to append matrices onto data frames. Naively I assumed that when rbinding a data.frame and matrix, the matrix would be coerced and appended, keeping the names from the data frame. Clearly, I am not fully understanding the process by which rbind works. Example code: > A<-data.frame(1,1,1); names(A)=letters[1:3] ; B<-matrix(0,2,3) > rbind(A,B)
2011 Aug 30
1
R crash
Dear users, By running the script below, R crashes systematically at the last command, namely dev.off(), on Windows 7, but not on Windows XP. I therefore don't provide a reproducible example and do not really extract the relevant parts of the script because it has most likely nothing to do with the script itself. I can do it though if you think it might be relevant. R crashes on Windows
2012 Aug 31
2
Conditional merging in R & if then statement
1)I am wandering how the following SQL statement can be written in R language w/o using sqldf: create table detail2 as select a.* from detail a, pdetail b where a.TDATE=b.TDATE and (a.STIM >= b.STIM and a.STIM <=b.MAXTIM) 2) when try if then in R it only applies to the 1st row & not to whole dataset like in SAS. How do you get round that? in SAS: data summary; set all1;
2006 Mar 16
1
Re: rcov 0.2.0 - code coverage tool for Ruby
On 3/14/06, David Holroyd <ruby-talk@badgers-in-foil.co.uk> wrote: > On Wed, Mar 15, 2006 at 02:23:04AM +0900, Mauricio Fernandez wrote: > > On Tue, Mar 14, 2006 at 09:27:14AM +0900, David Holroyd wrote: > > > On Wed, Mar 01, 2006 at 01:31:11AM +0900, Mauricio Fernandez wrote: > > > > Source code, additional information, screenshots... available at > >
2012 Nov 30
5
subset data frame by variable with missing value
Hello, I have a variable in a data frame that contains NA values. I just want to subset so that I get the obs where that variable is missing. In SAS I would do: data missing; set test; if myvalue=' '; run; How can I perform this simple task in R? Thanks in advance for your help. -- View this message in context:
2008 Jan 13
1
Trying to write Merge for more data.frames - Error in match.names(clabs, names(xi))
Dear list members, I would like to merge multiple dataframes and seems that this task is going to be required quite often, so I decided to write a simple (pseudo)recursive merge. I started with the case when dataframes are merged by rows (0). But there is a problem when a dataframe to be merged in the step n has some items that are not in previous ones. Then I get "Error in match.names(clabs,
2013 Apr 03
5
Can package plyr also calculate the mode?
I am trying to replicate the SAS proc univariate in R. I got most of the stats I needed for a by grouping in a data frame using: all1 <- ddply(all,"ACT_NAME", summarise, mean=mean(COUNTS), sd=sd(COUNTS), q25=quantile(COUNTS,.25),median=quantile(COUNTS,.50), q75=quantile(COUNTS,.75), q90=quantile(COUNTS,.90), q95=quantile(COUNTS,.95), q99=quantile(COUNTS,.99) )
2012 Sep 18
4
Conditional operations in R
Hello, I am a newbie to R coming from SAS background. I am trying to program the following: I have a monthly data frame with 2 variables: client pct_total A 15% B 10% C 10% D 9% E 8% F 6% G 4% I need to come up w/ a monthly list of clients that make 50% or just above it every month so I can pass them to the rest of the program.
2006 Apr 06
1
rbind
Hi list, I have been trying to pileup dataframes with different column names using rbind. I am getting the following error message. I was wondering if there is a way to go around this minor problem? Error in match.names(clabs, names(xi)) : names don't match previous names: G Thanks indeed for your information Regards Mahdi -- ----------------------------------- Mahdi Osman (PhD)