Closed manuparra closed 7 years ago
Use the next code for example in Linear Regression
dataset="/tmp/mtcars.csv" inputparameters=",na.action=na.omit" formula="mpg~disp" output="/tmp/model_lm.Rda" ro.r(""" dataset = read.csv(file="{0}", header = TRUE) resultfit = lm(formula="{1}", data=dataset,{2}) save(resultfit, file="{3}") """.format(dataset, formula, inputparameters, output))
Function ro.r(".....") will execute everything inside R code.
Done.
Use the next code for example in Linear Regression
Function ro.r(".....") will execute everything inside R code.