Codon usage varies both between organisms and between different genes in the same organism. This observation has been used as a basis for earlier work in identifying highly expressed and horizontally transferred genes in Escherichia coli. In this work, we applied Kohonen's self-organizing map to analysis of the codon usage pattern of the Escherichia coli, Aquifex aeolicus, Archaeoglobus fulgidus, Haemophilus influenzae RD:, Methanococcus jannaschii, Methanobacterium thermoautotrophicum, and Pyrococcus horikoshii genomes for evidence of highly expressed genes and horizontally transferred genes. All of the analyzed genomes had a clear category of horizontally transferred genes, and their apparent percentages ranged from 7.7% to 21.4%. The apparent percentage of highly expressed genes ranges from 0% to 11.8%. A clustering of average codon usage of main gene categories of the seven genomes showed an interesting mixing of gene classes in four thermophilic/hyperthermophilic organisms, A. aeolicus, A. fulgidus, M. thermoautotrophicum, and P. horikoshii, which suggests possible origins of their horizontally transferred genes as well as the need for adaptation to a specific environment. Further classification of the three gene categories in E. coli and H. influenzae according to gene function revealed that genes involved in communication (such as regulation and cell process) and structure (cell structure and structural proteins) are more likely to be horizontally transferred than are genes involved in information (transcription, translation, and related processes) and in some groups of energy (such as energy metabolism and carbon compound catabolism).