Karyotyping involves the staining and imaging of chromosomes from cells in metaphase. This helps in analyzing the number and structure of chromosomes, which is critical for identifying chromosomal abnormalities that are often seen in leukemia.