Electrical transport properties of double-walled carbon nanotubes (DWNTs) are modulated by encapsulating the azafullerene C 59 N which is synthesized via a plasma ion-irradiation method. The encapsulation of C 59 N molecules inside DWNTs has been confirmed by both transmission electron microscopy and Raman spectroscopy. The pristine DWNTs with outer diameter 4 -5 nm are found to exhibit an ambipolar semiconducting behavior due to their small band gap. It is found that C 60 fullerene encapsulated DWNTs exhibit a unipolar p-type semiconducting behavior. By comparison, C 59 N encapsulated DWNTs display an n-type semiconducting behavior. Our findings demonstrate that C 59 N operates as an electron donor compared with the acceptor behavior of C 60 , which is further clarified by photoelectron emission spectroscopy.