knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

Workflow

Load colrectr

library(colrectr)

Read Excel file specifying path and sheet.

colrect(path = "../inst/extdata/demo.xlsx",
        sheet = "降水量")
colrect(path = "../inst/extdata/demo.xlsx",
        sheet = "降水量",
        col = 1,
        regex = "^年.月$",
        offset = c(0, 0),
        ends = list(row = "^2019$", col = "^12月$"))

Read multiple sheets using regular expression

colrect(
    path = "../inst/extdata/demo.xlsx",
    sheet_regex = ".+",
    col = 1,
    regex = "^年.月",
  offset = c(0, 0),
  ends = list(row = "^2[0-9]{3}", col = "^12月$")
)


Rindrics/colrectr documentation built on Nov. 12, 2021, 1:01 p.m.