@@ -65,7 +65,7 @@ doc = addParagraph( doc, "Document title", stylename = "TitleDoc" )
65
65
66
66
# add a paragraph
67
67
doc = addParagraph( doc , "This document is generated with ReporteRs."
68
- , stylename="Citationintense")
68
+ , stylename="Citationintense")
69
69
70
70
# add page break
71
71
doc = addPageBreak( doc )
@@ -92,8 +92,8 @@ doc = addPageBreak( doc )
92
92
# add a title
93
93
doc = addTitle( doc, "Texts demo", level = 1 )
94
94
texts = c( "Lorem ipsum dolor sit amet, consectetur adipiscing elit."
95
- , "In sit amet ipsum tellus. Vivamus dignissim arcu sit amet faucibus auctor."
96
- , "Quisque dictum tristique ligula."
95
+ , "In sit amet ipsum tellus. Vivamus dignissim arcu sit amet faucibus auctor."
96
+ , "Quisque dictum tristique ligula."
97
97
)
98
98
99
99
# add simple text
@@ -102,19 +102,19 @@ doc = addParagraph( doc, value = texts, stylename="BulletList" )
102
102
# Add "My tailor is rich" and "Cats and Dogs"
103
103
# format some of the pieces of text
104
104
pot1 = pot("My tailor"
105
- , textProperties(color="red", font.size = 12 ) ) + " is " + pot("rich"
106
- , textProperties(font.weight="bold") )
105
+ , textProperties(color="red", font.size = 12 ) ) + " is " + pot("rich"
106
+ , textProperties(font.weight="bold") )
107
107
pot2 = pot("Cats"
108
- , textProperties(color="red", font.size = 12)
109
- ) + " and " + pot("Dogs"
110
- , textProperties(color="blue", font.size = 12) )
108
+ , textProperties(color="red", font.size = 12)
109
+ ) + " and " + pot("Dogs"
110
+ , textProperties(color="blue", font.size = 12) )
111
111
doc = addParagraph(doc, set_of_paragraphs( pot1, pot2 ), stylename="Normal" )
112
112
113
113
################ PLOT DEMO ################
114
114
115
115
myplot = qplot(Sepal.Length, Petal.Length
116
- , data = iris, color = Species
117
- , size = Petal.Width, alpha = I(0.7)
116
+ , data = iris, color = Species
117
+ , size = Petal.Width, alpha = I(0.7)
118
118
)
119
119
# Add titles and then ' myplot '
120
120
doc = addTitle( doc, "Plot examples", level = 1 )
@@ -139,18 +139,18 @@ doc = addTitle( doc, "FlexTable example", level = 1 )
139
139
# Create a FlexTable with data.frame mtcars, display rownames
140
140
# use different formatting properties for header and body cells
141
141
MyFTable = FlexTable( data = mtcars, add.rownames = TRUE
142
- , body.cell.props = cellProperties( border.color = "#EDBD3E")
143
- , header.cell.props = cellProperties( background.color = "#5B7778" )
142
+ , body.cell.props = cellProperties( border.color = "#EDBD3E")
143
+ , header.cell.props = cellProperties( background.color = "#5B7778" )
144
144
)
145
145
# zebra stripes - alternate colored backgrounds on table rows
146
146
MyFTable = setZebraStyle( MyFTable, odd = "#D1E6E7", even = "#93A8A9" )
147
147
148
148
# applies a border grid on table
149
149
MyFTable = setFlexTableBorders(MyFTable
150
- , inner.vertical = borderProperties( color="#EDBD3E", style="dotted" )
151
- , inner.horizontal = borderProperties( color = "#EDBD3E", style = "none" )
152
- , outer.vertical = borderProperties( color = "#EDBD3E", style = "solid" )
153
- , outer.horizontal = borderProperties( color = "#EDBD3E", style = "solid" )
150
+ , inner.vertical = borderProperties( color="#EDBD3E", style="dotted" )
151
+ , inner.horizontal = borderProperties( color = "#EDBD3E", style = "none" )
152
+ , outer.vertical = borderProperties( color = "#EDBD3E", style = "solid" )
153
+ , outer.horizontal = borderProperties( color = "#EDBD3E", style = "solid" )
154
154
)
155
155
156
156
# add MyFTable into document
0 commit comments