Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
quarto-dev
GitHub Repository: quarto-dev/quarto-cli
Path: blob/main/src/resources/schema/cell-figure.yml
12921 views
1
- name: fig-width
2
tags:
3
engine: knitr
4
schema: number
5
description: "Default width for figures"
6
7
- name: fig-height
8
tags:
9
engine: knitr
10
schema: number
11
description: "Default height for figures"
12
13
- name: fig-cap
14
schema:
15
maybeArrayOf: string
16
description: Figure caption
17
18
- name: fig-subcap
19
schema:
20
anyOf:
21
- enum: [true]
22
- maybeArrayOf: string
23
description: Figure subcaptions
24
25
- name: fig-link
26
schema:
27
maybeArrayOf: string
28
description: Hyperlink target for the figure
29
30
- name: fig-align
31
tags:
32
contexts: [document-figures]
33
formats: [docx, rtf, $odt-all, $pdf-all, $html-all]
34
schema:
35
maybeArrayOf:
36
enum: [default, left, right, center]
37
default: default
38
description: Figure horizontal alignment (`default`, `left`, `right`, or `center`)
39
40
- name: fig-alt
41
tags:
42
formats: [$html-all]
43
schema:
44
maybeArrayOf: string
45
description: |
46
Alternative text to be used in the `alt` attribute of HTML images.
47
48
- name: fig-env
49
tags:
50
formats: [$pdf-all]
51
contexts: [document-figures]
52
schema:
53
maybeArrayOf: string
54
description: LaTeX environment for figure output
55
56
- name: fig-pos
57
tags:
58
formats: [$pdf-all]
59
contexts: [document-figures]
60
schema:
61
anyOf:
62
- maybeArrayOf: string
63
- enum: [false]
64
description:
65
short: LaTeX figure position arrangement to be used in `\begin{figure}[]`.
66
long: |
67
LaTeX figure position arrangement to be used in `\begin{figure}[]`.
68
69
Computational figure output that is accompanied by the code
70
that produced it is given a default value of `fig-pos="H"` (so
71
that the code and figure are not inordinately separated).
72
73
If `fig-pos` is `false`, then we don't use any figure position
74
specifier, which is sometimes necessary with custom figure
75
environments (such as `sidewaysfigure`).
76
77
- name: fig-scap
78
tags:
79
formats: [$pdf-all]
80
schema:
81
maybeArrayOf: string
82
description:
83
short: A short caption (only used in LaTeX output)
84
long: |
85
A short caption (only used in LaTeX output). A short caption is inserted in `\caption[]`,
86
and usually displayed in the “List of Figures” of a PDF document.
87
88
- name: fig-format
89
tags:
90
engine: knitr
91
schema:
92
enum: [retina, png, jpeg, svg, pdf]
93
description: "Default output format for figures (`retina`, `png`, `jpeg`, `svg`, or `pdf`)"
94
95
- name: fig-dpi
96
tags:
97
engine: knitr
98
schema: number
99
description: "Default DPI for figures"
100
101
- name: fig-asp
102
tags:
103
engine: knitr
104
schema: number
105
description: |
106
The aspect ratio of the plot, i.e., the ratio of height/width. When `fig-asp` is specified, the height of a plot
107
(the option `fig-height`) is calculated from `fig-width * fig-asp`.
108
109
- name: out-width
110
tags:
111
engine: knitr
112
schema:
113
anyOf:
114
- string
115
- schema:
116
"null":
117
completions: []
118
description:
119
short: "Width of plot in the output document"
120
long: |
121
Width of the plot in the output document, which can be different from its physical `fig-width`,
122
i.e., plots can be scaled in the output document.
123
When used without a unit, the unit is assumed to be pixels. However, any of the following unit
124
identifiers can be used: px, cm, mm, in, inch and %, for example, `3in`, `8cm`, `300px` or `50%`.
125
126
- name: out-height
127
tags:
128
engine: knitr
129
schema: string
130
description:
131
short: "Height of plot in the output document"
132
long: |
133
Height of the plot in the output document, which can be different from its physical `fig-height`,
134
i.e., plots can be scaled in the output document.
135
Depending on the output format, this option can take special values.
136
For example, for LaTeX output, it can be `3in`, or `8cm`;
137
for HTML, it can be `300px`.
138
139
- name: fig-keep
140
tags:
141
engine: knitr
142
schema:
143
anyOf:
144
- enum: [high, none, all, first, last]
145
- maybeArrayOf: number
146
default: high
147
description:
148
short: "How plots in chunks should be kept."
149
long: |
150
How plots in chunks should be kept. Possible values are as follows:
151
152
- `high`: Only keep high-level plots (merge low-level changes into
153
high-level plots).
154
- `none`: Discard all plots.
155
- `all`: Keep all plots (low-level plot changes may produce new plots).
156
- `first`: Only keep the first plot.
157
- `last`: Only keep the last plot.
158
- A numeric vector: In this case, the values are indices of (low-level) plots
159
to keep.
160
161
- name: fig-show
162
tags:
163
engine: knitr
164
schema:
165
enum: [asis, hold, animate, hide]
166
default: asis
167
description:
168
short: "How to show/arrange the plots"
169
long: |
170
How to show/arrange the plots. Possible values are as follows:
171
172
- `asis`: Show plots exactly in places where they were generated (as if
173
the code were run in an R terminal).
174
- `hold`: Hold all plots and output them at the end of a code chunk.
175
- `animate`: Concatenate all plots into an animation if there are multiple
176
plots in a chunk.
177
- `hide`: Generate plot files but hide them in the output document.
178
179
- name: out-extra
180
tags:
181
engine: knitr
182
schema: string
183
description: "Additional raw LaTeX or HTML options to be applied to figures"
184
185
- name: external
186
tags:
187
engine: knitr
188
formats: [$pdf-all]
189
schema: boolean
190
default: true
191
description: "Externalize tikz graphics (pre-compile to PDF)"
192
193
- name: sanitize
194
tags:
195
engine: knitr
196
formats: [$pdf-all]
197
schema: boolean
198
default: false
199
description: "sanitize tikz graphics (escape special LaTeX characters)."
200
201
- name: interval
202
tags:
203
engine: knitr
204
schema: number
205
default: 1
206
description: "Time interval (number of seconds) between animation frames."
207
208
- name: aniopts
209
tags:
210
engine: knitr
211
schema: string
212
default: "controls, loop"
213
description:
214
short: "Extra options for animations"
215
long: |
216
Extra options for animations; see the documentation of the LaTeX [**animate**
217
package.](http://ctan.org/pkg/animate)
218
219
- name: animation-hook
220
tags:
221
engine: knitr
222
schema:
223
string:
224
completions: [ffmpeg, gifski]
225
default: ffmpeg
226
description:
227
short: "Hook function to create animations in HTML output"
228
long: |
229
Hook function to create animations in HTML output.
230
231
The default hook (`ffmpeg`) uses FFmpeg to convert images to a WebM video.
232
233
Another hook function is `gifski` based on the
234
[**gifski**](https://cran.r-project.org/package=gifski) package to
235
create GIF animations.
236
237