We present measurements of the electrical conductivity of barely metallic n-type indium phosphide (InP) that are driven to the metal-insulator transition (MIT) by a magnetic field. The experiments are carried out at low temperature in the range 4.2-0.066 K and in magnetic fields up to 11 T. The analysis of the lowtemperature correction to the Boltzmann conductivity due to electron-electron interaction as a function of the magnetic field allowed us to study the influence of exchange and Hartree interactions on the change of the sign of the electron-electron interaction correction. When the magnetic field is increased, several phenomena contribute to this corrective term "mT 1/2 " among which are the spin-splitting effect, the electronelectron interaction effect, and weak localisation effect. Not too close to the MIT, both the inelastic diffusion length L I and the interaction length L T contribute to a T 1/2 corrective term of the metallic electrical conductivity σ . It is convenient to develop a criterion to distinguish their contribution. This is based on the relation between the magnitude m and the zero temperature ( 0) T σ = .