2011-04-05 7 views

답변

8

일반적으로 내장 도움말이 상당히 유용합니다. 당신은 맞습니다. boxplot에 대한 도움말 페이지는 옵션이 무엇인지 명시하지 않고 na.action을 언급합니다. 이 경우

, ?na.action와 - 거기에서 다음 - (.이 매우 일반적이며, 또한 boxplot보다 다른 것들에 적용) ?na.omit 가능성을 설명

Handle Missing Values in Objects 

Description: 

    These generic functions are useful for dealing with ‘NA’s in e.g., 
    data frames. ‘na.fail’ returns the object if it does not contain 
    any missing values, and signals an error otherwise. ‘na.omit’ 
    returns the object with incomplete cases removed. ‘na.pass’ 
    returns the object unchanged. 

Usage: 

    na.fail(object, ...) 
    na.omit(object, ...) 
    na.exclude(object, ...) 
    na.pass(object, ...) 

Arguments: 

    object: an R object, typically a data frame 

    ...: further arguments special methods could require. 

Details: 

    At present these will handle vectors, matrices and data frames 
    comprising vectors and matrices (only). 

    If ‘na.omit’ removes cases, the row numbers of the cases form the 
    ‘"na.action"’ attribute of the result, of class ‘"omit"’. 

    ‘na.exclude’ differs from ‘na.omit’ only in the class of the 
    ‘"na.action"’ attribute of the result, which is ‘"exclude"’. This 
    gives different behaviour in functions making use of ‘naresid’ and 
    ‘napredict’: when ‘na.exclude’ is used the residuals and 
    predictions are padded to the correct length by inserting ‘NA’s 
    for cases omitted by ‘na.exclude’. 
+1

도움말 파일의 전체 내용을 게시하다 대답이 아닙니다. '? na.action'의 한 가지 문제점은 이해하기 어렵다는 점입니다. – buhtz

관련 문제