sparse input support in R