  The metal-insulator transition and the problem of d-electron delocalization
are investigated in the pyrite system NiS_{2-x}Se_x under pressure using
density functional theory (DFT). We test several approximations, including the
generalized gradient approximation (GGA), the GGA+U approach, and hybrid
functionals. In addition we apply the GW approximation and perform Hartree-Fock
calculations. The important role of the chalcogen dimers in the electronic
structure is discussed within GGA, which sufficiently describes the role of the
lattice in the metal-insulator transition. In addition, the magnetic phase
diagram is determined. However, the electronic properties are inadequately
described -- the insulating ground state of NiS_2 cannot be obtained -- and the
magnetic order is slightly overestimated. If correlations are taken into
account within GGA+U, the insulator is found, but the non-magnetic ground state
of the doped samples is not accessible. Mixing Fock exchange with local
approximations as GGA correctly reproduce the insulating ground state in NiS_2,
and metallic ground states with doping and pressure. The insulator is -- in
contrast to earlier suggestions -- of Mott type, i. e. the gap opens between Ni
3d {eg} states. Due to the Fock term, the magnetic order is strongly
overestimated. The applied GW calculations are not able to correct the metallic
character of NiS_2 and underestimate the gap by one order of magnitude.
