The i2dashboard S4 class provides main functionality of the package. Besides global properties such as the dashboard title, author and theme, an instance of the i2dashboard class also stores individual dashboard pages and the navigation menu, as well as all components that make up the content of individual pages. A new instance can be created using the i2dashboard function.
# S4 method for i2dashboard initialize(.Object, ...) # S4 method for i2dashboard show(object) i2dashboard(...)
| .Object | An object of class i2dashboard. |
|---|---|
| ... | Named slots of the i2dashboard object. |
| object | An i2dashboard class object. |
'i2dashboard()' returns an i2dashboard object with a default title, theme, and an empty 'default' page.
'show()' returns text, describing the structure of the i2dashboard object.
titleThe dashboards title (default 'i2dashboard').
authorThe author of the dashboard.
interactiveIf a 'shiny'-based report should be created (default 'FALSE').
themeThe theme of the dashboard (see the documentation of 'flexdashboard' for available themes) (default 'yeti').
datadirPath to the directory, where report data is stored (default 'tempdir()').
pagesA list of dashboard pages.
sidebarContent of the global sidebar
colormapsA named list with color mappings.
sourceEither a logical value describing whether the source code should be embeded through an item in the navigation bar or a link to a URL where the source code can be found online.
shareA vector with any number of the following services: 'facebook', 'twitter', 'google-plus', 'linkedin', and 'pinterest'. You can also specify “menu” to provide a generic sharing drop-down menu that includes all of the services.
navbarA list of links in the navigation bar (see the documentation of 'flexdashboard').
# \donttest{ dashboard <- i2dashboard() dashboard <- i2dashboard( title = "Dashboard title", author = "John Doe", interactive = TRUE, theme = "cosmo", datadir = "path/to/workdir", source = "embed" ) # inspect dashboard: show(dashboard) dashboard # }