diff --git a/index.Rmd b/index.Rmd
index a21ca8e..69a6671 100644
--- a/index.Rmd
+++ b/index.Rmd
@@ -81,7 +81,7 @@ p1 <- rPlot(x = list(var = "countrycode", sort = "value"), y = "value",
color = 'gender', data = women, type = 'bar')
# Step 3. add a second layer for men, displayed as points
-p1$layer2(x = "countrycode", y = "value", color = 'gender',
+p1$layer(x = "countrycode", y = "value", color = 'gender',
data = men, type = 'point', size = list(const = 3))
# Step 4. format the x and y axis labels
diff --git a/index.html b/index.html
index 705c176..5427f1a 100644
--- a/index.html
+++ b/index.html
@@ -87,7 +87,7 @@
Bar Plot
color = 'gender', data = women, type = 'bar')
# Step 3. add a second layer for men, displayed as points
-p1$layer2(x = "countrycode", y = "value", color = 'gender',
+p1$layer(x = "countrycode", y = "value", color = 'gender',
data = men, type = 'point', size = list(const = 3))
# Step 4. format the x and y axis labels
diff --git a/index.md b/index.md
index fe7badb..0e81f91 100644
--- a/index.md
+++ b/index.md
@@ -78,7 +78,7 @@ p1 <- rPlot(x = list(var = "countrycode", sort = "value"), y = "value",
color = 'gender', data = women, type = 'bar')
# Step 3. add a second layer for men, displayed as points
-p1$layer2(x = "countrycode", y = "value", color = 'gender',
+p1$layer(x = "countrycode", y = "value", color = 'gender',
data = men, type = 'point', size = list(const = 3))
# Step 4. format the x and y axis labels
diff --git a/rChartOECD/server.R b/rChartOECD/server.R
index a53c82e..7f670a1 100644
--- a/rChartOECD/server.R
+++ b/rChartOECD/server.R
@@ -5,11 +5,11 @@ shinyServer(function(input, output) {
men <- subset(dat2m, gender == "Men" & year == YEAR)
women <- subset(dat2m, gender == "Women" & year == YEAR)
p1 <- rPlot(x = list(var = "countrycode", sort = "value"), y = "value",
- color = 'gender', data = women, type = 'bar')
- p1$layer2(x = "countrycode", y = "value", color = 'gender',
- data = men, type = 'point', size = list(const = 3))
+ color = 'gender', data = women, type = 'bar')
+ p1$layer(x = "countrycode", y = "value", color = 'gender',
+ data = men, type = 'point', size = list(const = 3))
p1$addParams(height = 300, dom = 'chart1',
- title = "Percentage of Employed who are Senior Managers")
+ title = "Percentage of Employed who are Senior Managers")
p1$guides(x = list(title = "", ticks = unique(men$countrycode)))
p1$guides(y = list(title = "", max = 18))
return(p1)