Vinecop.gradient
- Vinecop.gradient(self, u: numpy.ndarray, step_wise: bool = True, num_threads: int = 1, parameters: numpy.ndarray | None = None) numpy.ndarray
Evaluates the gradient of the average log-likelihood.
Returns the observation-average of
scores()as a vector of lengthnpars, mirroring howhessian()averageshessian_full().- Parameters:
- undarray, shape (n, m), dtype float
An \(n \times (d + k)\)or \(n \times 2d\)matrix of evaluation points, where \(k\)is the number of discrete variables (see
select()).- step_wisebool
if
False, full gradient of the log-likelihood; ifTrue, score function of the step-wise MLE (gradients computed per pair-copula, treating the pseudo-observations as fixed).- num_threadsint
The number of threads to use for computations; if greater than 1, the function will be applied concurrently to
num_threadsbatches ofu.