Annotation of OpenXM/src/R/r-packages/hgm_fb/man/hgm.mleFBByOptim.Rd, Revision 1.1
1.1 ! takayama 1: % $OpenXM$
! 2: \name{hgm.z.mleFBByOptim}
! 3: \alias{hgm.z.mleFBByOptim}
! 4: %%Todo, write documents for hgm.z.mleDemo, hgm.ssFB
! 5: %\alias{hgm.ncso3}
! 6: %- Also NEED an '\alias' for EACH other topic documented here.
! 7: \title{
! 8: MLE of Fisher-Bingham distribution by optim and HGM.
! 9: }
! 10: \description{
! 11: It makes the maximal likelihood estimate (MLE) for the Fisher-Bingham
! 12: distribution on S^d.
! 13: }
! 14: \usage{
! 15: hgm.z.mleFBByOptim(d=0,ss=NULL,data=NULL,start=NULL,lb=NULL,ub=NULL,bigValue=10000)
! 16: }
! 17: %- maybe also 'usage' for other objects documented here.
! 18: \arguments{
! 19: \item{d}{The dimension of the sphere}
! 20: \item{ss}{Sufficient statistics}
! 21: \item{data}{
! 22: The argument data is a set of data on the d-dimensional sphere.
! 23: Its format is an n by (d+1) matrix where n is the number of data.
! 24: When data is given, ss must be NULL
! 25: and ss is calculated from data by hgm.ssFB(data).
! 26: }
! 27: \item{start}{
! 28: Starting point for the function optim. The default value is a random
! 29: vector.
! 30: }
! 31: \item{lb}{
! 32: An array of length sslen = (d+1)*(d+2)/2 + (d+1), each of which
! 33: is the lower bound of the parameter. The default value is -100.
! 34: }
! 35: \item{ub}{
! 36: An array of length sslen = (d+1)*(d+2)/2 + (d+1), each of which
! 37: is the upper bound of the parameter. The default value is 100.
! 38: }
! 39: \item{bigValue}{
! 40: It is used as a value wall to avoid that the evaluation point is out of
! 41: the search domain defined by lb and ub.
! 42: }
! 43: }
! 44: \details{
! 45: It solves the MLE for the Fisher-Bingham distribution.
! 46: The normalizing constant is evaluated by hgm_ko_ncfb (external program,
! 47: which should in the path).
! 48: The function
! 49: % \code{\link[RCurl]{postForm}}
! 50: \code{\link{optim}}
! 51: is used for the optimization.
! 52: The output is used as a starting point for the holonomic gradient method.
! 53: See nk_fb_gen_c.rr of \url{http://www.math.kobe-u.ac.jp/Asir}.
! 54: This function generates temporary work files whose names start with tmp.
! 55: \code{data <- read.table(fileName,sep=",")} can be used to read CSV data
! 56: from a file.
! 57: }
! 58: \value{
! 59: The output format is that of the function optim().
! 60: }
! 61: \references{
! 62: T. Koyama, H. Nakayama, K. Nishiyama, N. Takayama,
! 63: Holonomic Gradient Descent for the Fisher-Bingham Distribution on the d-dimensional Sphere,
! 64: Computational Statistics (2013)
! 65: \url{http://dx.doi.org/10.1007/s00180-013-0456-z}
! 66: }
! 67: \author{
! 68: T.Koyama, H.Nakayama, K.Nishiyama, N.Takayama.
! 69: }
! 70: \note{
! 71: %% ~~further notes~~
! 72: }
! 73:
! 74: %% ~Make other sections like Warning with \section{Warning }{....} ~
! 75:
! 76: \seealso{
! 77: \code{\link{optim}}
! 78: }
! 79: \examples{
! 80: ## =====================================================
! 81: ## Example 1. Asteroid data in [N3OST2]
! 82: ## =====================================================
! 83: \dontrun{
! 84: d <- 2
! 85: ss <- c(0.3119,0.0292,0.0707,
! 86: 0.3605,0.0462,
! 87: 0.3276,
! 88: 0.0063,0.0054,0.0762)
! 89: start <- c(0.1,0.1,1,1,1,-1,-1,-1,-1)
! 90: hgm.z.mleFBByOptim(d=d,ss=ss,start=start)
! 91: }
! 92: }
! 93: % Add one or more standard keywords, see file 'KEYWORDS' in the
! 94: % R documentation directory.
! 95: \keyword{ Holonomic gradient method }
! 96: \keyword{ HGM }
! 97: \keyword{ Fisher-Bingham distribution on S^d}
! 98: \keyword{ MLE }
! 99:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>