Skip to contents

Create subscripts

Create superscript

Usage

subscript(x, subscript = seq(length(x)))

superscript(x, superscript = seq(length(x)))

Arguments

x

text

subscript

subscript

superscript

superscript

Value

text

text

Examples

subscript("X", 1:3)
#> [1] "X<sub>1</sub>" "X<sub>2</sub>" "X<sub>3</sub>"
superscript(c("A", "B"), 2)
#> [1] "A<sup>2</sup>" "B<sup>2</sup>"