map_wb() takes a list and returns a list of wbWorkbook objects.
properties is recycled to match the length of the input x.
Arguments
- x
A data frame, a list of data frames, a file path for an Excel file, or a
wbWorkbookobject. AwbWorkbookis returned "as is" ignoring all other parameters. A file path is loaded to a data frame usingopenxlsx2::wb_to_df().- ...
Arguments passed on to
as_wbsheet_namesOptional character vector of worksheet names.
title,subject,category,keywordsAdditional arguments passed to
openxlsx2::wb_workbook().creatorCreator of the workbook (your name). Defaults to login username or
options("openxlsx2.creator")if set.datetime_createdThe time of the workbook is created
themeOptional theme identified by string or number. See Details for options.
callThe execution environment of a currently running function, e.g.
caller_env(). The function will be mentioned in error messages as the source of the error. See thecallargument ofabort()for more information.
- properties
A named list (typically from
openxlsx2::wb_get_properties()) used to set new workbook properties for any values set toNULL.datetime_createddefaults toSys.time()so must be set toNULLto inherit value fromproperties.- .progress
Whether to show a progress bar. Use
TRUEto turn on a basic progress bar, use a string to give it a name, or see progress_bars for more details.
Examples
map_wb(list(mtcars[1:3, ], mtcars[4:6, ]))
#> [[1]]
#> A Workbook object.
#>
#> Worksheets:
#> Sheets: Sheet 1
#> Write order: 1
#> [[2]]
#> A Workbook object.
#>
#> Worksheets:
#> Sheets: Sheet 1
#> Write order: 1