The R Project SVN R

Rev

Rev 77548 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 77548 Rev 77685
Line 31... Line 31...
31
 
31
 
32
#ifdef IEEE_754
32
#ifdef IEEE_754
33
    if (ISNAN(x) || ISNAN(meanlog) || ISNAN(sdlog))
33
    if (ISNAN(x) || ISNAN(meanlog) || ISNAN(sdlog))
34
	return x + meanlog + sdlog;
34
	return x + meanlog + sdlog;
35
#endif
35
#endif
36
    if(sdlog < 0) ML_ERR_return_NAN;
36
    if(sdlog < 0) ML_WARN_return_NAN;
37
    if(!R_FINITE(x) && log(x) == meanlog) return ML_NAN;/* log(x) - meanlog is NaN */
37
    if(!R_FINITE(x) && log(x) == meanlog) return ML_NAN;/* log(x) - meanlog is NaN */
38
    if(sdlog == 0)
38
    if(sdlog == 0)
39
	return (log(x) == meanlog) ? ML_POSINF : R_D__0;
39
	return (log(x) == meanlog) ? ML_POSINF : R_D__0;
40
    if(x <= 0) return R_D__0;
40
    if(x <= 0) return R_D__0;
41
 
41