I want to add the caption above the table. There is no information on the package documentationhere. The documentation only explains adding caption to long table which is not the case of mine. Any help appreciated!
This is the code:
\usepackage{tabularray}
\usepackage[table]{xcolor}
\usepackage{graphicx}
\begin{document}
\scalebox{0.8}{
\begin{tblr}[caption={"sdsdssdfsdfds"}]{
colspec={cccccccc},
rowspec={Q[gray!20]Q[]Q[gray!10]Q[]Q[gray!10]Q[]Q[gray!10]Q[]},
rowhead = 1,
vline{2-8} = {0-1}{0.3pt,gray!50},
vline{2-8} = {2-7}{0.3pt,gray!30},
hline{1,2,8} = {0.1pt,azure5}}
header & header & header & header & header & header & header & header\\
1 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
2 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
3 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
4 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
5 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
6 & Beta & Gamma & Alpha & Beta & Gamma & Beta & Gamma\\
\end{tblr}
}
\end{document}
\scalebox
defined? Which document class do you employ?table
environment. Or use thecaption
orcapt-of
package that allows you to add captions with the\captionof
command.longtblr
for this. I know that it is meant for use with long tables which extend over one page, but it will work in a case like this, where you have a short table.