Description
SparkR subset function throw error when only set "select" argument, it's easy to repreduce.
In SparkR:
> df <- suppressWarnings(createDataFrame(sqlContext, iris)) > subset(df, select=c("Sepal_Length", "Petal_Length", "Species")) Error in x[subset, select, ...] : error in evaluating the argument 'i' in selecting a method for function '[': Error: argument "subset" is missing, with no default
But in base R, the subset function works well with only specifying "select" argument:
> df <- iris > subset(df, select=c("Sepal.Length", "Petal.Length", "Species")) Sepal.Length Petal.Length Species 1 5.1 1.4 setosa 2 4.9 1.4 setosa 3 4.7 1.3 setosa 4 4.6 1.5 setosa 5 5.0 1.4 setosa ......