I created a vector, marks
:
marks <- cut(scores[,1], breaks = break_vector, labels = mark_vector, right = FALSE)
Calling marks
gives: [1] 3 2 4 4 2 5 2 1
That’s fine. Now I want to create a matrix, having scores
in the first, and marks
in the second column.
Then I use marks_column <- cbind(marks)
before creating that matrix. There is the problem: In the output of R I now get a column, ignoring the labels = mark_vector
from the cut function above. So the R output gives a column, as if I had written labels = FALSE
insted of labels = mark_vector
.
How can I fix that?