Description Usage Arguments Details Value Author(s) See Also Examples

Splitting a string into a number of sections of defined length is needed, when we want to split a table given as a number of lines without separator into columns. The cutting points can either be defined by the lengths of the sections or directly by position.

1 | ```
StrChop(x, len, pos)
``` |

`x` |
the string to be cut in pieces. |

`len` |
a vector with the lengths of the pieces. |

`pos` |
a vector of cutting positions. Will be ignored when |

If length is going over the end of the string the last part will be returned, so if the rest of the string is needed, it's possible to simply enter a big number as last partlength.

`len`

and `pos`

can't be defined simultaneously, only alternatively.

Typical usages are

1 2 |

a vector with the parts of the string.

Andri Signorell <andri@signorell.net>

1 2 3 4 5 6 7 8 |

```
[1] "abc" "defgh" "ij"
[1] "abc" "defgh" "ij" "klmnopqrstuvwxyz"
[1] "abcde" "fghij" "klmnopqrstuvwxyz"
```

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.