I have create a nsR.c module for aolserver with limit function, since R can compile as a share library, so I can provide loadable module for aolserver. Now I can call R function from tcl. I do not have enough resource to develop the module, if anyone feel interesting , you can take the source code an continue improve it.
you can ferform function call like this:
set x [nsR log1p 1.5]
set x [nsR expml 2]
set x [nsR gamma 10]