Epidemic routing has been proposed to reduce the data transmission delay in disruption tolerant wireless networks, in which data can be replicated along multiple opportunistic paths as different nodes move within each other's communication range. With the advent of network coding, it is intuitive that data can not only be replicated, but also coded, when the transmission opportunity arises. However, will opportunistic communication with network coding perform any better than simple replications? In this paper, we present a stochastic analytical framework to study the performance of epidemic routing using network coding in opportunistic networks, as compared to the use of replication. We analytically show that network coding is superior when bandwidth and node buffers are limited, reflecting more realistic scenarios. Our analytical study is able to provide further insights towards future designs of efficient data communication protocols using network coding. As an example, we propo...