如何查看类方法的所有可用参数(或更一般地查看文档)?
例如,如果我们看
print()
?print
x
an object used to select a method.
...
further arguments passed to or from other methods.
quote
logical, indicating whether or not strings should be printed with surrounding quotes.
-- leaving others out for brevity --
useSource
logical indicating if internally stored source should be used for printing when present, e.g., if options(keep.source = TRUE) has been in use.
请注意,我们没有看到该参数的任何文档
max_n
.
现在假设我们打电话来
打印()
在某种程度上
xml_nodes
,例如:
library(rvest)
library(dplyr)
a <- rep("<p></p>", 30) %>%
paste0(collapse="") %>%
read_html %>%
html_nodes("p")
class(a)
a
xml_nodeset
print(a)
,它打印出来了
只有20个结果
,这是因为(我认为)xml\u nodeset类被配置为
print
can be changed via the
max_n
parameter
).
我们如何找到有关
打印
在类的对象上调用时的行为
? (最好通过RStudio/手册)
注意上面的例子只是一个随机的例子,我想找到一个寻找所有类方法文档的一般方法