I am having problems with the R Snippet nodes (1:1 and 2:1) converting from integer to double for the output table.
For example, the following bare-bones template will print 'integer' for typeof. But the output table has double ('numeric' in R).
<rgg> <![CDATA[ rOut <- read.table("integer_test.txt", sep="\t", head=T) print(typeof(rOut$id)) rOut ]]> </rgg>
It doesn't appear to be a problem with the R server, as the following code in the R Snippet (Remote), does return integers in the output table:
R<-read.table("integer_test.txt", sep="\t", head=TRUE) print(typeof(R$id)) # prints 'integer' R
Is there some way to force the R Snippet nodes to return integer type for the output table?
I am using 2.8.1 on Mountain Lion.