  In-depth studies of exoplanetary atmospheres are starting to become reality.
In order to unveil their properties in detail, we need spectra with a higher
S/N and also more sophisticated analysis methods. With high-resolution
spectrographs, we can not only detect the sodium feature in the atmosphere of
exoplanets, but also characterize it by studying its line profile. After
finding a clearly w-shaped sodium line profile in the transmission spectrum of
HD189733b, we investigated possible sources of contamination given by the star
and tried to correct for these spurious deformations. By analyzing the single
transmission spectra of HD189733b in the wavelength space, we show that the
main sodium signal that causes the absorption in the transmission spectrum is
centered on the stellar rest frame. We concentrate on two main stellar effects
that contaminate the transmission spectrum: center-to-limb variations and
stellar rotation. We show the effects on the line profile: while we correct for
the CLV using simulated theoretical stellar spectra, we provide a new method,
based directly on observational data, to correct for the RM contribution to the
line profile of the retrieved transmission spectrum. We apply the corrections
to the spectra of HD189733b. Our analysis shows line profiles of the Na D lines
in the transmission spectrum that are narrower than reported previously. The
correction of the D2 line, which is deeper than the D1, is probably still
incomplete since the planetary radius is larger at this wavelength. A careful
detrending from spurious stellar effects followed by an inspection in the
velocity space is mandatory when studying the line profile of atmospheric
features in the high-resolution transmission spectrum of exoplanets. Data with
higher S/N coupled with improved atmospheric models will allow us to adapt the
magnitude of the corrections of stellar effects in an iterative way.
