| footer_image | R Documentation |
The footer_image function inserts an image into the page footer. The function
can be used to add a logo or other graphical element to the report.
The image will then appear at the bottom of each page.
footer_image(x, image_path, height, width, align = "left")
x |
The report object to insert the image into. |
image_path |
The path of image file. Function accepts JPG images for RTF, DOCX, PDF, and HTML output types. Function also accepts PNG images for RTF, DOCX, and HTML output types. |
height |
Desired height of the image, in the report units of measure. |
width |
Desired width of the image, in the report units of measure. |
align |
Alignment of the image in the page footer. Valid values are "left", "right", "center", or "centre". The default value is "left". |
The function assumes
the existence of a page footer inserted by the page_footer function.
If there is no page footer, an error will be generated during the rendering
process in write_report. If there is text
in the same cell as the image, the text will be disregarded. You may add text
to other cells in the footer.
The "align" parameter determines which page footer cell the image will be inserted.
That is, if you align an image "left", it will be inserted into the left
column of the page footer. Options are "left", "right", and "center". To
insert images in multiple cells, you may use multiple calls to
image_footer.
The page footer cell width will take priority over the image width. That is, if you set the image width larger than the cell width, the image width will be reduced to fit the cell. To make a wider image, increase the cell width on the page footer.
Note that page footer cells can be removed entirely by setting the width to zero. This feature can give you more room for a wide image. For instance, to create a banner image under the entire report, align the image "center" and set the left and right page header column widths to zero.
See the page_footer function for more information on
setting footer column widths. For a demonstration of
a header image insertion, see vignette("reporter-hfimage").
The modified report specification.
Other report:
add_content(),
create_report(),
footnotes(),
header_image(),
options_fixed(),
page_by(),
page_footer(),
page_header(),
print.report_spec(),
set_margins(),
title_header(),
titles(),
write_report()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.