# Why does the GATE pipeline fail with no obvious reason

In case your GATE pipeline fails with an error message similar to "missing value where TRUE/FALSE needed" the job has crashed while executing an R script. You can confirm this by checking the messages surrounding the error. They should contain hints to "package"s and may even be linked to a particular R package called Rcpp.

While this error cannot be sufficiently explained it can be avoided by reducing and/or changing your covariates, in particular the principal components (PCs) in your phenotype-covariate file. This trial-and-error approach is admittedly somewhat cumbersome but has proved successful as removing a small number of PCs prevents convergence from failing but should not dramatically affect the statistics.

When editing your phenotype-covariate file do not forget to modify your json file accordingly, changing the value informing on the used covariates.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.finngen.fi/faq/about-pipelines/why-does-the-gate-pipeline-fail-with-no-obvious-reason.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
