我shelve使用以前的 Pandas 版本(不确定是哪个,但可能是 0.25.3)将两个数据帧保存到数据库中,并且shelve使用 Pandas 0.25.3从文件中读取它们没有问题。但是,我无法使用最新的 Pandas(1.0.0,由 pandas. version打印)阅读它们。我收到以下错误:
AttributeError: Can't get attribute 'FrozenNDArray' on <module 'pandas.core.indexes.frozen' from 'local/virtualenv.../'
Run Code Online (Sandbox Code Playgroud)
似乎FrozenNDArray该类已在 1.0.0 中删除,那么如何恢复数据帧?一些搜索指向pandas.read_pickle,但没有等同于shelve。
给定以下rmarkdown文件:
```{r}
library(knitr)
```
```{r, out.width="100%"}
path <- "plotx.png"
knitr::include_graphics(path)
```
```{r, out.width="100%", out.height="150%"}
knitr::include_graphics(path)
```
Run Code Online (Sandbox Code Playgroud)
图形之间的大小没有差异,就好像图形大小选项没有任何影响一样。使用其他类似的选项,例如fig.width、fig.height,没有任何区别。
```{r}
library(knitr)
```
```{r, out.width="100%"}
path <- "plotx.png"
knitr::include_graphics(path)
```
```{r, out.width="100%", out.height="150%"}
knitr::include_graphics(path)
```
Run Code Online (Sandbox Code Playgroud)