# Like cut, turn a vector of numbers into a factor

### Description

Like `cut`

, turn a vector of numbers into a factor

### Usage

1 2 |

### Arguments

`x` |
a numeric vector |

`intervals` |
a character vector of intervals |

`buckets` |
a character vector of levels for the new factor
these have a 1-1 correspondence with |

`na.bucket` |
what level should NA values be given? |

`unmatched.bucket` |
what level should numbers not covered by an interval be given? |

`out.as.factor` |
default is TRUE Should the resulting vector be a factor? If FALSE will return a character vector. |

### Examples

1 2 3 4 5 |