diff --git a/R/group_rows.R b/R/group_rows.R
index 7300eb3..6cc8ec5 100644
--- a/R/group_rows.R
+++ b/R/group_rows.R
@@ -19,6 +19,12 @@
 #' documents.
 #' @param escape A T/F value showing whether special characters should be
 #' escaped.
+#' @param latex_align Adjust justification of group_label in latex only. Value should be "c" for
+#' centered on row, "r" for right justification, or "l" for left justification. Default
+#' Value is "l"  If using html, the alignment can be set by using the label_row_css
+#' parameter.
+#' @param colnum A numeric that determines how many columns the text should span.
+#' The default setting will have the text span the entire length.
 #'
 #' @examples x <- knitr::kable(head(mtcars), "html")
 #' # Put Row 2 to Row 5 into a Group and label it as "Group A"
@@ -30,7 +36,7 @@
                        index = NULL,
                        label_row_css = "border-bottom: 1px solid;",
                        latex_gap_space = "0.3em",
-                       escape = TRUE) {
+                       escape = TRUE, latex_align = "l", colnum = NULL) {
 
   kable_format <- attr(kable_input, "format")
   if (!kable_format %in% c("html", "latex")) {
@@ -41,28 +47,32 @@
   }
   if (is.null(index)) {
     if (kable_format == "html") {
+      if(!missing(latex_align)) warning("latex_align parameter is not used in HTML Mode,
+                                    use label_row_css instead.")
       return(group_rows_html(kable_input, group_label, start_row, end_row,
-                             label_row_css, escape))
+                             label_row_css, escape, colnum))
     }
     if (kable_format == "latex") {
       return(group_rows_latex(kable_input, group_label, start_row, end_row,
-                              latex_gap_space, escape))
+                              latex_gap_space, escape, latex_align, colnum))
     }
   } else {
     index <- group_row_index_translator(index)
     out <- kable_input
     if (kable_format == "html") {
       for (i in 1:nrow(index)) {
+        if(!missing(latex_align)) warning("latex_align parameter is not used in HTML Mode,
+                                    use label_row_css instead.")
         out <- group_rows_html(out, index$header[i],
                                index$start[i], index$end[i],
-                               label_row_css, escape)
+                               label_row_css, escape, colnum)
       }
     }
     if (kable_format == "latex") {
       for (i in 1:nrow(index)) {
         out <- group_rows_latex(out, index$header[i],
                                index$start[i], index$end[i],
-                               latex_gap_space, escape)
+                               latex_gap_space, escape, latex_align, colnum)
       }
     }
     return(out)
@@ -79,7 +89,7 @@
 }
 
 group_rows_html <- function(kable_input, group_label, start_row, end_row,
-                            label_row_css, escape) {
+                            label_row_css, escape, colnum) {
   kable_attrs <- attributes(kable_input)
   kable_xml <- read_kable_as_xml(kable_input)
   kable_tbody <- xml_tpart(kable_xml, "tbody")
@@ -97,7 +107,9 @@
 
   # Insert a group header row
   starting_node <- xml_child(kable_tbody, group_seq[1])
-  kable_ncol <- length(xml_children(starting_node))
+  kable_ncol <- ifelse(is.null(colnum),
+                       length(xml_children(starting_node)),
+                       colnum)
   group_header_row_text <- paste0(
     '<tr groupLength="', length(group_seq), '"><td colspan="', kable_ncol,
     '" style="', label_row_css, '"><strong>', group_label,
@@ -115,7 +127,7 @@
 }
 
 group_rows_latex <- function(kable_input, group_label, start_row, end_row,
-                             gap_space, escape) {
+                             gap_space, escape, latex_align, colnum) {
   table_info <- magic_mirror(kable_input)
   out <- enc2utf8(as.character(kable_input))
 
@@ -135,14 +147,17 @@
   if (table_info$booktabs) {
     new_rowtext <- paste0(
       "\\\\addlinespace[", gap_space, "]\n",
-      "\\\\multicolumn{", table_info$ncol, "}{l}{\\\\textbf{", group_label,
+      "\\\\multicolumn{", ifelse(is.null(colnum),
+                                 table_info$ncol,
+                                 colnum),
+      "}{", latex_align, "}{\\\\textbf{", group_label,
       "}}\\\\\\\\\n",
       rowtext
     )
   } else {
     rowtext <- paste0("\\\\hline\n", rowtext)
     new_rowtext <- paste0(
-      "\\\\hline\n\\\\multicolumn{", table_info$ncol, "}{l}{\\\\textbf{",
+      "\\\\hline\n\\\\multicolumn{", table_info$ncol, "}{", latex_align,"}{\\\\textbf{",
       group_label, "}}\\\\\\\\\n", rowtext
     )
   }
diff --git a/R/kable_styling.R b/R/kable_styling.R
index 305d3d0..bad743d 100644
--- a/R/kable_styling.R
+++ b/R/kable_styling.R
@@ -35,6 +35,9 @@
 #' a `LaTeX` table, if `float_*` is selected, `LaTeX` package `wrapfig` will be
 #' imported.
 #' @param font_size A numeric input for table font size
+#' @param row_label_position A character string determining the justification of the row
+#' labels in a table.  Possible values inclued `l` for left, `c` for center, and `r` for
+#' right.  The default value is `l` for left justifcation.
 #' @param ... extra options for HTML or LaTeX. See `details`.
 #'
 #' @details For LaTeX, extra options includes:
@@ -59,6 +62,7 @@
                           full_width = NULL,
                           position = "center",
                           font_size = NULL,
+                          row_label_position = "l",
                           ...) {
 
   if (length(bootstrap_options) == 1 && bootstrap_options == "basic") {
@@ -88,6 +92,9 @@
     if (is.null(full_width)) {
       full_width <- getOption("kable_styling_full_width", T)
     }
+    if(!missing(row_label_position)) {
+      warning("'row_label_position' is not active for HTML tables yet and parameter will not be used.")
+    }
     return(htmlTable_styling(kable_input,
                              bootstrap_options = bootstrap_options,
                              full_width = full_width,
@@ -102,7 +109,9 @@
                             latex_options = latex_options,
                             full_width = full_width,
                             position = position,
-                            font_size = font_size, ...))
+                            font_size = font_size,
+                            row_label_position = row_label_position,
+                            ...))
   }
 }
 
@@ -186,7 +195,8 @@
                              repeat_header_method = c("append", "replace"),
                              repeat_header_continued = FALSE,
                              stripe_color = "gray!6",
-                             latex_table_env = NULL) {
+                             latex_table_env = NULL,
+                             row_label_position) {
 
   latex_options <- match.arg(
     latex_options,
@@ -249,6 +259,21 @@
 
   out <- structure(out, format = "latex", class = "knitr_kable")
   attr(out, "kable_meta") <- table_info
+
+  if (row_label_position != "l") {
+    if(table_info$tabular=="longtable") {
+      out <- sub("\\\\begin\\{longtable\\}\\{l",
+                 paste0("\\\\begin\\{longtable\\}\\{",
+                        row_label_position),
+                 out)
+    } else {
+      out <- sub("\\\\begin\\{tabular\\}\\{l",
+                 paste0("\\\\begin\\{tabular\\}\\{",
+                        row_label_position),
+                 out)
+    }
+  }
+
   return(out)
 }
 
diff --git a/tests/visual_tests/add_indent_and_group_rows_pdf.Rmd b/tests/visual_tests/add_indent_and_group_rows_pdf.Rmd
index 06439c8..b942a0a 100644
--- a/tests/visual_tests/add_indent_and_group_rows_pdf.Rmd
+++ b/tests/visual_tests/add_indent_and_group_rows_pdf.Rmd
@@ -30,7 +30,7 @@
   dplyr::mutate(wt = paste0("%", mpg)) %>%
 kable(format = "latex", booktabs = T) %>%
   kable_styling() %>%
-  group_rows("Group 1", 4, 7) %>%
+  group_rows("Group 1", 4, 7, latex_align='r',colnum=3) %>%
   group_rows("Group 2", 8, 10)
 ```
 
@@ -39,7 +39,7 @@
 kable(format = "latex", booktabs = T) %>%
   kable_styling() %>%
   group_rows("Group 1", 4, 7) %>%
-  group_rows("Group 2", 8, 10) %>%
+  group_rows("Group 2", 8, 10, latex_align='c') %>%
   group_rows("Group 2", 20, 22)
 
 aa <- mtcars
