Many papers in connection with power associativity in genetic algebras show a class of commutative power-associative algebras which are one-dimensional modulo their maximal nil ideals. In this paper we study power-associative algebras with principal and absolutely primitive idempotent and the Peirce decomposition A= A 1⊕ A 1 2⊕ A 0 of which either A 1 is isomorphic to the ground field of A 0= 0. In the first case, this class of algebras, which we call power-associative B-algebras, coincide with the class of Berstein algebras of order n (n⩾ 0) which are power-associative. Every power-associative B-algebra is a train algebra, and when it is a Jordan B-algebra, it is special train algebra. In the other case, we refer to power-associative algebras of type II. These algebras are also train algebras.