Electronegativity is a measure of an atom's ability to attract electrons in a chemical bond. It increases across a period as the proton number and effective nuclear charge increases, making the nucleus more able to attract electrons. However, electronegativity decreases down a group as the energy level and shielding effect increases, weakening the attraction between the nucleus and valence electrons. Electron affinity is the energy change when an electron is added to a neutral atom to form a negative ion. It is measured as the electron attachment energy or electronegativity.