This article is part of The Definitive Guide to Importing and Preparing Data.
It is common to have a numeric variable in a dataset from which you need to create categories or groups for analysis. The best practice approach in this situation is not to convert the numeric variable to a categorical variable but to instead derive a new categorical variable where you've specified the 'bands' or 'buckets' (i.e., the categories).
A primary example is when there is an age variable with the exact age of each respondent in years. For analysis purposes, you want to use the following groups in tables and graphs, 'Under 18', '18-40', '40-65', and '65+'. In this case, you could derive a new categorical variable with those categories, without altering your original source variable.