Technically, all image data compression schemes can be categorized into two groups as lossless (reversible) and lossy (irreversible). Although some information is lost in the lossy compression, especially for the radiologic image compression, new algorithms can be designed to minimize the effect of data loss on the diagnostic features of the images. Wavelet transform (WT) constitute a new compression technology that has been described in natural and medical images. In this study, the well known Shapiro's embedded zerotree wavelet algorithm (EZW) for image coding is modified. It is designed to optimize the combination of zerotree coding and Huffman coding. It is shown that the multi-iteration algorithms and particularly the two-iteration EZW for a given image quality produce lower bit rates than Shapiro's. It is applied for the medical images and here, the thorax radiology is chosen as a sample image and the good performance is codified.