帮助大家,
想要使用print.xtable更改表的字体大小.
运用
print(xT, size="\\tiny")
有效,但我现在没有其他尺寸选择.像size ="7pt"这样的东西会很好.
最好的祝福.
在R Studio中安装软件包rmarkdown,您可以使用Rmd文件创建docx文档并按下Knit Word按钮.
然后调用的命令是:
"C:/Program Files/RStudio/bin/pandoc/pandoc" +RTS -K512m -RTS hallo.utf8.md --to docx --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash-implicit_figures
--output hallo.docx --highlight-style tango
Run Code Online (Sandbox Code Playgroud)
题
如何添加其他选项?我想补充一下:
--filter ./pandoc-word-pagebreak
Run Code Online (Sandbox Code Playgroud)
要得到:
"C:/Program Files/RStudio/bin/pandoc/pandoc" +RTS -K512m -RTS hallo.utf8.md --to docx --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash-implicit_figures --filter ./pandoc-word-pagebreak
--output hallo.docx --highlight-style tango
Run Code Online (Sandbox Code Playgroud) 想要截断表格(如果存在):
IF EXISTS(SELECT 1 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'mytable') TRUNCATE mytable
Run Code Online (Sandbox Code Playgroud)
错误:
您的SQL语法有错误; 检查与MySQL服务器版本对应的手册,以便在第1行的"IF EXISTS(SELECT 1 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME ='mytable')'附近使用正确的语法
我之后尝试添加那些)但问题似乎是在IF.
当我使用 时barplot,如果名称太大,我看不到条的名称。例如:
barplot(as.numeric(c(2, 4, 1, 6)), col = c("lightblue"), main="Barplot",
names.arg=c("This is bar 1...1", "This is bar 1...2",
"This is bar 1...3", "This is bar 1...4"),
xpd=TRUE, las=1, lwd=1, cex.names=0.5)
Run Code Online (Sandbox Code Playgroud)
当我使用时horiz=TRUE,我看不到左边的名字:
barplot(as.numeric(c(2, 4, 1, 6)), col = c("lightblue"), main="Barplot",
names.arg=c("This is \nbar 2...1", "This is bar 2...2",
"This is bar 2...3", "This is bar 2...4"),
xpd=TRUE, las=1, lwd=1, horiz=TRUE, space=1)
Run Code Online (Sandbox Code Playgroud)
在名称中使用换行符(例如“这是 \nbar 2...1”)或减小文本大小,例如cex.names=0.5“解决”问题,但我更愿意添加空格以使名称适合。
有没有能力改变包括情节在内的整个图形的宽度?