The gene expression data obtained from microarrays have shown to be useful in cancer classification. DNA microarray data have extremely high dimensionality compared to the small number of available samples. An important step in microarray studies is to remove genes irrelevant to the learning problem and to select a small number of genes expressed in biological samples under specific conditions. In this paper, we propose a novel feature subset selection algorithm, partitional branch and bound (PBB) algorithm. This new algorithm is very efficient for selecting sets of genes in very high dimensional feature space. Two databases are considered: the colon cancer database and the leukemia database. Our experimental results show that the proposed algorithm yields a better subset of features than both forward selection algorithms and individual ranking methods in terms of a criterion function measuring class separability.