Write a function recode_likert() that takes a numeric vector with the values 1 to 5 as input and that returns an ordered factor with the levels:

 

very bad < bad < OK < good < very good

 

Be sure to include the necessary checks and messages for the user. For instance, keep in mind the input vector can also have missing values.

If you have no clue how to start, take another look at how to construct an ordered factor (help(factor)).