For tracking spacecraft and performing radio science, the transformation between the proper time (τ) given by a clock carried onboard a spacecraft and the barycentric coordinate time (TCB) is investigated under IAU resolutions. In order to more clearly demonstrate manifestations of a physical model and improve computa- tional efficiency, an analytic approach is adopted. After numerical verification, it is confirmed that this method is adequate to describe a Mars orbiter during one year, and is particularly good at describing the influence from perturbing bodies. Further analyses demonstrate that there are two main effects in the transformation: the gravi- tational field of the Sun and the velocity of the spacecraft in the barycentric coordinate reference system. The combined contribution of these effects is at the level of a few sub-seconds.