RÓïÑÔÖÐÎÄÍø

 ÕÒ»ØÃÜÂë
 Á¢¼´×¢²á
²é¿´: 1274|»Ø¸´: 0

RÓïÑÔÁгöS3·ºÐͺ¯Êý»òÀàµÄ·½·¨methods()º¯Êý-ÖÐÓ¢ÎĶÔÕÕ°ïÖúÎĵµ

[¸´ÖÆÁ´½Ó]
·¢±íÓÚ 2020-8-21 08:07:19 | ÏÔʾȫ²¿Â¥²ã |ÔĶÁģʽ
        RÓïÑÔÁгöS3·ºÐͺ¯Êý»òÀàµÄ·½·¨methods()º¯Êý-ÖÐÓ¢ÎĶÔÕÕ°ïÖúÎĵµ

                                         By MicroRbt Martinez PhD

RÓïÑÔº¯ÊýÃû£ºmethods()
RÓïÑÔº¯Êý¹¦ÄÜ£ºÁгöS3·ºÐͺ¯Êý»òÀàµÄ·½·¨
À´×Ô×ÊÔ´¿â£º»ù´¡¿â£¨RÓïÑÔ×Ô´ø£©
methods()º¯ÊýËùÊôRÓïÑÔ°ü£ºËùÔÚR°ü¾ßÌåÃû³Æ¡¢°ü¹¦ÄܵÄÖÐÓ¢ÎÄË«ÓïÃèÊö¼ûÕýÎĺóÃæ'--ËùÔÚRÓïÑÔ°üÐÅÏ¢--'²¿·Ö¡£

ÃèÊö-----Description-----

List all available methods for a S3 and S4 generic function, or all methods for an S3 or S4 class.
ÁгöS3ºÍS4·ºÐͺ¯ÊýµÄËùÓпÉÓ÷½·¨£¬»òS3»òS4ÀàµÄËùÓз½·¨¡£


ʹÓ÷½·¨-----Usage-----

methods(generic.function, class)
.S3methods(generic.function, class, envir=parent.frame())
## S3 method for class 'MethodsFunction' S3 method for class 'MethodsFunction'
format(x, byclass = attr(x, "byclass"), ...)
## S3 method for class 'MethodsFunction' S3 method for class 'MethodsFunction'
print(x, byclass = attr(x, "byclass"), ...)

²ÎÊý-----Arguments-----

²ÎÊýgeneric.function½éÉÜ: a generic function, or a character string naming a generic function.
ͨÓú¯Êý£¬»òÃüÃûͨÓú¯ÊýµÄ×Ö·û´®¡£

²ÎÊýclass½éÉÜ: a symbol or character string naming a class: only used if generic.function is not supplied.
ÃüÃûÀàµÄ·ûºÅ»ò×Ö·û´®£º½öµ±Î´Ìṩgeneric.functionʱʹÓá£

²ÎÊýenvir½éÉÜ: the environment in which to look for the definition of the generic function, when the generic function is passed as a character string.
µ±Í¨Óú¯Êý×÷Ϊ×Ö·û´®´«µÝʱ£¬ÔÚÆäÖÐÑ°ÕÒͨÓú¯Êý¶¨ÒåµÄ»·¾³¡£

²ÎÊýx½éÉÜ: typically the result of methods(..), an R object of S3 class "MethodsFunction", see Value below.
ͨ³£ÊÇmethods(..)c£¨S3Àà"MethodsFunction"µÄR¶ÔÏ󣩵Ľá¹û£¬Çë²Î¼ûÏÂÃæµÄValue¡£

²ÎÊýbyclass½éÉÜ: an optional logical allowing to override the "byclass" attribute determining how the result is printed, see Details .
ÔÊÐí¸²¸Ç"byclass"ÊôÐÔ²¢È·¶¨ÈçºÎ´òÓ¡½á¹ûµÄ¿ÉÑ¡logical£¬Çë²Î¼ûDetails¡£

²ÎÊý...½éÉÜ: potentially further arguments passed to and from methods; unused currently.
·½·¨¿ÉÄÜ´«µÝµÄÆäËû²ÎÊý£»µ±Ç°Î´Ê¹Óá£


ÏêÇé-----Details-----

methods() finds S3 and S4 methods associated with either the generic.function or class argument. Methods are found in all packages on the current search() path. .S3methods() finds only S3 methods, .S4methods() finds only only S4 methods.
methods()²éÕÒÓëgeneric.function»òclass²ÎÊý¹ØÁªµÄS3ºÍS4·½·¨¡£·½·¨¿ÉÔÚµ±Ç°search()·¾¶ÉϵÄËùÓ
-----δÍ꣬´ýÐø-----£¬¡ý¡ý¡ýÕ¹¿ªÊ£Óà72%¡ý¡ý¡ý
¹ºÂòÖ÷Ìâ Ç°ÐÐÐèÒªÄúµÄÖ§³Ö£¬ÇëÔÞÖú×÷Õß ¡¾15 ½ðÇ®¡¿ ¾ÍÄÜä¯ÀÀÈ«²¿100%ÄÚÈÝÀ²£¡£¨±¾ÌùÒ»´ÎÔÞÖú¡¢ÓÀ¾Ã¿É¶Á£©
»Ø¸´

ʹÓõÀ¾ß ¾Ù±¨

ÄúÐèÒªµÇ¼ºó²Å¿ÉÒÔ»ØÌû µÇ¼ | Á¢¼´×¢²á

±¾°æ»ý·Ö¹æÔò

ÊÖ»ú°æ|СºÚÎÝ|Archiver|RÓïÑÔÖÐÎÄÍø    

GMT+8, 2024-5-20 21:05 , Processed in 0.030398 second(s), 23 queries .

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

¿ìËٻظ´ ·µ»Ø¶¥²¿ ·µ»ØÁбí