R: Repeatedly attempt a compute plan until successful

mxComputeTryHard {OpenMx} | R Documentation

## Repeatedly attempt a compute plan until successful

### Description

The provided compute plan is run until the status code indicates success (0 or 1). It gives up after a small number of retries.

### Usage

    mxComputeTryHard(
      plan,
      ...,
      freeSet = NA_character_,
      verbose = 0L,
      location = 1,
      scale = 0.25,
      maxRetries = 3L
    )

### Arguments

`plan` | compute plan to optimize the model
`...` | Not used. Forces remaining arguments to be specified by name.
`freeSet` | names of matrices containing free variables
`verbose` | integer. Level of run-time diagnostic output. Set to zero to disable
`location` | location of the perturbation distribution
`scale` | scale of the perturbation distribution
`maxRetries` | maximum number of plan evaluations per invocation (including the first evaluation)

### Details

Upon failure, start values are randomly perturbed. Currently only the uniform distribution is implemented. The distribution is parameterized by arguments `location` and `scale`. The location parameter is the distribution's median. For the uniform distribution, `scale` is the absolute difference between its median and extrema (i.e., half the width of the rectangle). Each start value is multiplied by a random draw and then added to a random draw from a distribution with the same `scale` but with a median of zero.

### References

Shanno, D. F. (1985). On Broyden-Fletcher-Goldfarb-Shanno method. Journal of Optimization Theory and Applications, 46(1), 87-94.

### See Also

`mxTryHard`

[Package OpenMx version 2.20.6 Index]