I was wondering how do I actually see what's inside a function, say,
density of t distribution, dt()?

I know for some, I can type the function name inside R and the code will be
displayed.  But for dt(), I get
> dt
function (x, df, ncp, log = FALSE)
{
    if (missing(ncp))
        .Internal(dt(x, df, log))
    else .Internal(dnt(x, df, ncp, log))
}
<environment: namespace:stats>

I am curious because I am doing rejection sampling and want to find a
"bigger" distribution.

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to