Description Usage Arguments Value Examples

A quick C implementation for “which.first” (`head(which(x), 1)`

) and
“which.last” (`tail(which(x), 1)`

).

1 2 3 |

`x` |
[ |

`use.names` |
[ |

[`integer(1)`

| `integer(0)`

].
Returns the index of the first/last `TRUE`

value in `x`

or
an empty integer vector if none is found. NAs are ignored.

1 2 3 |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.