func7: MLE Computes the liklihood of a given distribution for data x

Description Usage Arguments Value Examples

View source: R/func7.R

Description

MLE Computes the liklihood of a given distribution for data x

Usage

1
func7(x, fun, interval)

Arguments

x

vector

fun

a distribution function

interval

the interval where the optimization shoul search among

Value

return the log of the ppdf or pmf

Examples

1
2
3
4
x <- scan(url("http://www.stat.umn.edu/geyer/3701/data/q1p3.txt"))
f <- function(theta, x) dgamma(x, shape = theta, log = TRUE)
interval <- c(0,100)
func7(x,f,interval)

kuanghuangying/KuangHuangyingTools documentation built on May 25, 2019, 9:30 p.m.