Skip to content

Commit 7889585

Browse files
felixcheungshivaram
authored andcommitted
[SPARKR][DOCS] minor code sample update in R programming guide
## What changes were proposed in this pull request? Fix code style from ad hoc review of RC4 doc ## How was this patch tested? manual shivaram Author: Felix Cheung <[email protected]> Closes #14250 from felixcheung/rdocs2rc4. (cherry picked from commit 75f0efe) Signed-off-by: Shivaram Venkataraman <[email protected]>
1 parent 33d92f7 commit 7889585

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

docs/sparkr.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ if (nchar(Sys.getenv("SPARK_HOME")) < 1) {
5454
Sys.setenv(SPARK_HOME = "/home/spark")
5555
}
5656
library(SparkR, lib.loc = c(file.path(Sys.getenv("SPARK_HOME"), "R", "lib")))
57-
sc <- sparkR.session(master = "local[*]", sparkConfig = list(spark.driver.memory="2g"))
57+
sparkR.session(master = "local[*]", sparkConfig = list(spark.driver.memory = "2g"))
5858
{% endhighlight %}
5959
</div>
6060

@@ -115,7 +115,7 @@ specifying `--packages` with `spark-submit` or `sparkR` commands, or if initiali
115115

116116
<div data-lang="r" markdown="1">
117117
{% highlight r %}
118-
sc <- sparkR.session(sparkPackages = "com.databricks:spark-avro_2.11:3.0.0")
118+
sparkR.session(sparkPackages = "com.databricks:spark-avro_2.11:3.0.0")
119119
{% endhighlight %}
120120
</div>
121121

examples/src/main/r/RSparkSQLExample.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ write.df(df1, "data/test_table/key=1", "parquet", "overwrite")
144144
write.df(df2, "data/test_table/key=2", "parquet", "overwrite")
145145

146146
# Read the partitioned table
147-
df3 <- read.df("data/test_table", "parquet", mergeSchema="true")
147+
df3 <- read.df("data/test_table", "parquet", mergeSchema = "true")
148148
printSchema(df3)
149149

150150
# The final schema consists of all 3 columns in the Parquet files together

0 commit comments

Comments
 (0)