<div class="section-label"><span class="num">02</span> Options</div>
<div class="section-title"><em>Settings</em> for each prediction call.</div>
These are **advanced knobs**. For general analysis, call <span class="mono">predict_psr</span>, <span class="mono">predict_maxfit</span>, or <span class="mono">predict_grid</span> without the options argument; each method uses suitable defaults.
To customize a run, pass the matching object: [[#PredictOptions|PredictOptions]] with <span class="mono">predict_psr</span>, [[#MaxFitOptions|MaxFitOptions]] with <span class="mono">predict_maxfit</span>, or [[Settings/Grid Options#GridOptions|GridOptions]] with <span class="mono">predict_grid</span>. MaxFitOptions and GridOptions extend PredictOptions: the same shared fields, plus the knobs for the respective path. Grid search, sampling, and retain are on [[Settings/Grid Options|Grid options]].
```mermaid
classDiagram
direction TB
class PredictOptions {
shared base fields
}
class MaxFitOptions {
+objective
+inner_parallel
}
class GridOptions {
+max_iter
+min_k
+max_k
+allowed_k
+seed
+attribute_combi
+required_attributes
+attribute_groups
+adjust_impact_for_missing
+retain_grid_objects
+inner_parallel
}
PredictOptions <|-- MaxFitOptions
PredictOptions <|-- GridOptions
```
## PredictOptions
Settings for <span class="mono">predict</span>. Also the shared base inherited by MaxFitOptions and GridOptions.
**Call:** `predict_psr`
**Type:** `PredictOptions`
**Defaults when omitted:** threshold `[0.5]`; `censor_type` `relevance`; `censor_unit` `percent`; `censor_operator` `gte`
```text
PredictOptions
├── threshold
├── censor_type, censor_unit, censor_operator
├── prediction_scale
├── adj_fit_multiplier, inv_method
└── missing_moments, include_linear_regression, verbose
```
Field details:
| Name | Type / values | Default | Description |
| --- | --- | --- | --- |
| <span class="mono">threshold</span> | vector, length ≥ 1 | <span class="mono">[0.5]</span> | Censor cut(s); becomes T on results |
| <span class="mono">censor_type</span> | <span class="mono">relevance</span> \| <span class="mono">similarity</span> | <span class="mono">relevance</span> | Score that is thresholded. <span class="mono">both</span> is invalid here |
| <span class="mono">censor_unit</span> | <span class="mono">score</span> \| <span class="mono">percent</span> | <span class="mono">percent</span> | Raw score vs percentile |
| <span class="mono">censor_operator</span> | <span class="mono">gt</span> \| <span class="mono">lt</span> \| <span class="mono">gte</span> \| <span class="mono">lte</span> | <span class="mono">gte</span> | How the cut compares to the score |
| <span class="mono">prediction_scale</span> | <span class="mono">response</span> \| <span class="mono">logistic</span> | <span class="mono">response</span> | Prediction on y scale or logistic scale |
| <span class="mono">adj_fit_multiplier</span> | <span class="mono">identity</span> \| <span class="mono">K</span> \| <span class="mono">log</span> | <span class="mono">K</span> | How adjusted fit is scaled |
| <span class="mono">inv_method</span> | <span class="mono">gaussian</span> \| <span class="mono">cholesky</span> \| <span class="mono">pseudoinverse</span> | <span class="mono">gaussian</span> | Covariance inversion method |
| <span class="mono">missing_moments</span> | <span class="mono">pairwise</span> \| <span class="mono">complete</span> | <span class="mono">pairwise</span> | How μ, Σ, and PSR N treat NaNs. Incomplete <span class="mono">X</span> rows still get weight 0; this does not drop them from ŷ. <span class="mono">complete</span> is listwise. Alias: <span class="mono">verify_missing_data</span> on → <span class="mono">complete</span> |
| <span class="mono">include_linear_regression</span> | on / off | off | Attach optional <span class="mono">yhat_linear</span> when available |
| <span class="mono">verbose</span> | on / off | off | Diagnostic status messages |
> [!note]- Percentile algorithm
> When <span class="mono">censor_unit</span> is <span class="mono">percent</span>, a process-wide percentile algorithm also applies (<span class="mono">full_sort</span> or <span class="mono">order_statistics</span>). It is not a field on the options object. See [[Settings/Allowed Values#Percentile algorithm|Allowed values]].
## MaxFitOptions
Settings for <span class="mono">predict_maxfit</span>. Includes all [[#PredictOptions|PredictOptions]] fields, with MaxFit-oriented defaults for threshold and censor type.
**Call:** `predict_maxfit`
**Type:** `MaxFitOptions`
**Inherits:** [[#PredictOptions|PredictOptions]]
```text
MaxFitOptions
├── …PredictOptions
├── threshold, censor_type (MaxFit defaults)
├── objective
└── inner_parallel
```
MaxFit-specific options and overridden defaults:
| Name | Type / values | Default | Description |
| --- | --- | --- | --- |
| <span class="mono">threshold</span> | vector, length ≥ 1 | <span class="mono">[0, 0.2, 0.5, 0.8]</span> | Candidate thresholds to search |
| <span class="mono">censor_type</span> | <span class="mono">relevance</span> \| <span class="mono">similarity</span> \| <span class="mono">both</span> | <span class="mono">both</span> | <span class="mono">both</span> allowed (unlike Predict) |
| <span class="mono">objective</span> | <span class="mono">fit</span> \| <span class="mono">adjusted_fit</span> \| <span class="mono">kfit</span> | <span class="mono">kfit</span> | Score used to pick the winning threshold |
| <span class="mono">inner_parallel</span> | <span class="mono">auto</span> \| <span class="mono">off</span> | <span class="mono">auto</span> | Within-call parallel when searching both censor types |
Other PredictOptions fields keep the PSR defaults unless you override them.
<div class="btn-row center">
<a class="btn-primary" href="/Settings/Grid%20Options">Grid options</a>
<a class="btn-ghost" href="/Settings/Allowed%20Values">Allowed values</a>
</div>
## Related
- [[Functions/PSR]] · [[MaxFit]] · [[Grid Prediction]]
- [[Settings/Grid Options|Grid options]] · [[Settings/Allowed Values|Allowed values]]
- [[Results/Overview|Results]]
> [!warning]- C ABI / native integrators
> Option names and defaults here follow the thin clients. The C ABI may expose different symbols, flag names, or ownership rules. Integration engineers should pin and follow the public header contract rather than this chapter alone: [[Install/Native Runtime|Native Runtime]] · [C ABI on GitHub](https://github.com/CambridgeSportsAnalytics/rbp-math-c-abi).