The electronic structure of the ternary RAgSn (R=Ce,Pr,Nd,Dy) compounds which crystallize in the hexagonal LiGaGe-type structure was studied by X-ray photoemission spectroscopy. Core-levels and valence bands were investigated. The X-ray photoemission spectroscopy valence bands are compared with the ones calculated using the spin-polarized tight-binding linear muffin-tin orbital method. The obtained results indicate that the valence bands are mainly determined by the Ag 4d band. The spin-orbit splitting values Δso determined from the XPS spectra of 3d512 and 3d3/2 are equal to 18.8 eV for R = Ce, 20.2 eV for R = Pr and 22.6 eV for R = Nd. The analysis of these spectra on the basis of the Gunnarsson-Schönhammer model gives a hybridization of f orbitals with the conduction band. The calculation of the total energy for two models of the crystal structure: an ordered of the LiGaGe-type and a disordered one of the CaIn2-type indicate that in these compounds 'the LiGaGe-type structure is stable. Additionally, the temperature dependences of the electrical resistivity of CeAgSn and DyAgSn are investigated. At high temperatures the resistivity is not a linear function of temperature which indicates an electron-phonon interaction in the presence of a small s-d scattering, whereas at low temperatures anomalies connected with the magnetic phase transitions are observed.