A method of converting n-bit information words into m-bit code words, and the other way round, is described. The code words have a limited disparity. For every information word, two code words are assigned to a group of information words, which code words can be derived from one another by inversion. A choice between these two code words is made to limit the digital-sum-value so as to obtain a d.c. free code. In order to obtain a further limitation of the digital-sum-value within the code words, these code words are derived from each other by inversion and reversal.