GradientDescent: Gradient descent estimation of model parameters

View source: R/eval.R

GradientDescentR Documentation

Gradient descent estimation of model parameters

Description

Estimates parameters h and J by iterative gradient updates to match first and second moments of the observed binary data under an maximum pairwise entropy model.

Usage

GradientDescent(data, maxit)

Arguments

data

Numeric matrix (typically 0/1). Rows are samples and columns are species or taxa.

maxit

Integer. Maximum number of gradient descent iterations.

Details

This function calls Energy() to compute energies for candidate states. Ensure that Energy is available in the package namespace.

Value

A list with elements:

h.est

Numeric vector of estimated implicit environmental parameters.

j.est

Numeric matrix of estimated interaction matrix.


ELAplus documentation built on May 28, 2026, 5:09 p.m.