ijtok {crochet} | R Documentation |

## Convert Two-Dimensional Indices i and j to One-Dimensional Index k

### Description

`ijtok`

is a helper function that converts two-dimensional indices
`i`

and `j`

to a one-dimensional index `k`

. This can be
useful if, for example, one-dimensional indexing is easier to implement
than two-dimensional indexing.

### Usage

```
ijtok(x, i, j)
```

### Arguments

`x` |
A matrix-like object. |

`i` |
The first component of a two-dimensional index. |

`j` |
The second component of a two-dimensional index. |

### Details

It is assumed that all indices are one-based.

### Value

A one-dimensional index.

[Package

*crochet*version 2.3.0 Index]