[R] translate SAS code

2007-05-22 Thread elyakhlifi mustapha
good morning,
I have some SAS code to translate in R code and when I export data from Excel 
to R I have to read formula writed as follow

C604=(C181/S181)*(100-C182)*(100/85)

or

if C325=. then C740=(C346/C103)*100| else C740=(C346/C325)*100

I find some difficulties to write a good program to read and calculate these 
formulas
there are several kinds of formulas there are with conditional and without 
conditional
can you help me please?
thanks.


  
_ 

[[alternative HTML version deleted]]

__
R-help@stat.math.ethz.ch 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.


Re: [R] translate SAS code

2007-05-22 Thread Adaikalavan Ramasamy
I am not sure if R can read formulas and if it does, it probably as 
characters. I would suggest you Copy and Paste Special (as values) onto 
a new sheet and save it a tab delimited files.


elyakhlifi mustapha wrote:
 good morning,
 I have some SAS code to translate in R code and when I export data from Excel 
 to R I have to read formula writed as follow
 
 C604=(C181/S181)*(100-C182)*(100/85)
 
 or
 
 if C325=. then C740=(C346/C103)*100| else C740=(C346/C325)*100
 
 I find some difficulties to write a good program to read and calculate these 
 formulas
 there are several kinds of formulas there are with conditional and without 
 conditional
 can you help me please?
 thanks.
 
 
   
 _ 
 
   [[alternative HTML version deleted]]
 
 __
 R-help@stat.math.ethz.ch 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.
 
 


__
R-help@stat.math.ethz.ch 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.