eliminate as.real from code  (deprecated in R 3)