Hello, I have a for loop that generates data in R. With the IML program, I would like to analyze data in SAS from each iteration of the for loop in R. It would be helpful if someone could explain to me how to analyze data this way. Thanks [[alternative HTML version deleted]]
Hi Cheryl, Since your question is how to analyze the data and the data is being analyzed in SAS, my guess is that you will have to go to SAS for help on this (unless SAS makes a free R package that comes with a full distro of SAS so we can actually try IML..). Why not just create and analyze the data in R? First time seeing this: http://support.sas.com/rnd/app/studio/Rinterface2.html Cheers, Josh On Sun, Oct 30, 2011 at 5:02 PM, Cheryl Johnson <johnson.cheryl625 at gmail.com> wrote:> Hello, > > I have a for loop that generates data in R. With the IML program, I would > like to analyze data in SAS from each iteration of the for loop in R. It > would be helpful if someone could explain to me how to analyze data this > way. > > Thanks > > ? ? ? ?[[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >-- Joshua Wiley Ph.D. Student, Health Psychology Programmer Analyst II, ATS Statistical Consulting Group University of California, Los Angeles https://joshuawiley.com/
The SAS/IML documentation on calling R is at http://support.sas.com/documentation/cdl/en/imlug/64248/HTML/default/viewer.htm#r_toc.htm Other ways to get help include calling SAS Technical Support (it's free) and posting your question to the SAS/IML Discussion forum at http://communities.sas.com/community/sas_iml_and_sas_iml_studio I'd like to see an example of what you're trying to do, but here are few general ways to do this: 1) Call R in a loop from SAS/IML. At each iteration, generate each matrix or data frame, export it to a SAS matrix or data set, and do the analysis. 2) While the previous option is conceptually easy, it might be more efficient to generate all the data with a single call to R, export it all to SAS, and then use SAS to analyze each subset of the data. I don't usually monitor this R forum, so if you want further details might want to use one of the options in the first paragraph. -- View this message in context: http://r.789695.n4.nabble.com/How-to-use-IML-with-R-and-SAS-tp3954943p3955888.html Sent from the R help mailing list archive at Nabble.com.
I will respond off list since the issue is mostly related to SAS. Alan Mitchell, MSc Biostatistician alanm at crab.org -----Original Message----- From: Cheryl Johnson [mailto:johnson.cheryl625 at gmail.com] Sent: Sunday, October 30, 2011 5:02 PM To: r-help at r-project.org Subject: [R] How to use IML with R and SAS Hello, I have a for loop that generates data in R. With the IML program, I would like to analyze data in SAS from each iteration of the for loop in R. It would be helpful if someone could explain to me how to analyze data this way. Thanks [[alternative HTML version deleted]]