Kable 在 R 中强制我的 table 高于我的文本,我该如何解决这个问题?

Kable forces my table above my text in R, how do I fix this?

我正在使用一些乳胶编写以下代码(在 R 笔记本中制作可重现的报告文档,但出于某种原因,我的 table 放在我的文本和等式上方。我该如何解决这个问题?enter image description here

title: "Empirical Research in Finance"
subtitle: "**Hypothesis tests and simulation**" 
author: Faes E.
fontsize: 12pt
date: '*January 25, 2021*'
output: 
    pdf_document: default
    html_document:
    df_print: paged
header-includes:
  - \usepackage{amsmath} \usepackage{color}
  - \usepackage{titling}
  - \pretitle{\begin{center}
    \includegraphics[width=4in,height=4in]{AMSLOGO.jpg}\LARGE\}
  - \posttitle{\end{center}}
\thispagestyle{empty}
# copy the R logo to the current directory
file.copy(file.path(R.home("doc"), "html", "AMSLOGO.jpg"), '.')
\newpage

\newpage

在 table1 中对样本偏度的第一和第二时刻进行了检查。可以看出,对于较大的样本,均值趋于零。对于方差,正在达到渐近方差。我们知道它应该呈现以下值(等式 2),因为我们知道偏度是渐近分布的,均值为 0,方差为 6/n(在这种情况下,n 是样本大小)。

\begin{equation} 
\tag{2} 
skewness \stackrel{a}{\sim}N(0,\dfrac{6}{n})
\end{equation}

```{r echo=FALSE}
kable(des(mom=S), digits= 3, caption = "Statistics for skewness") %>%
    kable_classic(full_width = F) %>%
     footnote(number = c("n is the sample size","std is the standard deviation"))
```

喜欢 user2554330 回答正确并且对我有用:

你可以用kable(..., format = "latex", position = "h!")给出一个非常强烈的建议,让它留在原地。如果 LaTeX 认为这是个坏主意,它仍然不会这样做。