> ## Documentation Index
> Fetch the complete documentation index at: https://doc.lucidworks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# click_pos

[localhost link]: http://localhost:3000/docs/4/fusion-server/reference/fusion-sql/click_pos

[mintlify link]: https://doc.lucidworks.com/docs/4/fusion-server/reference/fusion-sql/click_pos

[old doc.lw link]: https://doc.lucidworks.com/fusion-server/4.2/3251

The `click_pos` UDF computes either a reciprocal rank or a raw click position (using a 0-based index) of a document in a page of results. This UDF is used to compute the mean reciprocal rank (MRR) for experiments. For example, given the following list of documents and a doc ID, the `click_pos` UDF will return 2:
import { LwTemplate } from '/snippets/LwTemplate.jsx';

<LwTemplate />

```yml wrap  theme={"dark"}
docs: a,b,c,d
doc ID: c
```
