I need to display the symbol '^'
d <- dist(fascores, method = "euclidean")^2
How do I do that?
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It only takes a minute to sign up.
Sign up to join this communityI need to display the symbol '^'
d <- dist(fascores, method = "euclidean")^2
How do I do that?
\textrm
or similar in math-mode)
\textasciicircum
or\^{}
,\hat{}
(only this produces a circumflex),\widehat{}
, or\wedge
(∧).in a verb-like manner
\string^
,\char`\^
,\verb!^!
:
\verb!d <- dist(fascores, method = "euclidean")^2!
\documentclass{standalone}
\usepackage{upquote}% getting the right grave ` (and not ‘)!
\begin{document}
\begin{tabular}{lcc}
Input & Text & Math \\ \hline
\verb|\string^| & \string^ & $\string^$ \\
\verb|\char`\^| & \char`\^ & $\char`\^$ \\
\verb|\verb!^!| & \verb!^! & $\verb!^!$ \\ \hline
\verb|\textasciicircum| & \textasciicircum & --- \\
\verb|\^{}| & \^{} (e.g. \^a) & --- \\ \hline
\verb|\hat{}| & --- & $\hat{}$ (e.g. $\hat a$) \\
\verb|\wedge| & --- & $\wedge$ (e.g. $a\wedge b$) \\
\verb|\widehat{}| & --- & $\widehat{\ }$ (e.g. $\widehat{abc}$) \\
\end{tabular}
\end{document}
^\wedge
. Other variants is mostly to small.
– serkas
Nov 3 '14 at 12:06
You could also try
\textsuperscript{$\wedge$}
which yields:
To put this into context, (\textsuperscript{$\wedge$}N225),
will yield: