Dopants and defects can be introduced as well as the intercalation of metals into single wall carbon nanotubes (SWCNTs) to modify their electronic and magnetic properties, thus significantly widening their application areas. Through spinpolarized density functional theory (DFT) calculations, we have systemically studied the following: (i) (10,0) and (5,5) SWCNT doped with nitrogen (), (ii) (10,0) and (5,5) SWCNT with pyridine-like defects (3NV-), and (iii) chemical functionalization of (10,0) and (5,5) 3NV- with 12 different transition metals (TMs) (Sc, Ti, V, Cr, Mn, Fe, Co, Ni, Cu, Zn, Pd, and Pt). Attention was done in searching for the most stable configurations, deformation, calculating the formation energies, and exploring the effects of the doping concentration of nitrogen and pyridine-like nitrogenated defects on the electronic properties of the nanotubes. Also, calculating the corresponding binding energies and effects of chemical functionalization of TMs on the electronic and magnetic properties of the nanotubes has been made. We found out that the electronic properties of SWCNT can be effectively modified in various ways, which are strongly dependent not only on the concentration of the adsorbed nitrogen but also to the configuration of the adsorbed nitrogen impurities, the pyridine-like nitrogenated defects, and the TMs absorbed; due to the strong interaction between the d orbitals of TMs and the p orbitals of N atoms, the binding strengths of TMs with the two 3NV- are significantly enhanced when compared to the pure SWCNTs.