In a reactive circuit, the ratio of the reactance in ohms divided by the resistance in ohms. is defined as quality factor.
A system's quality factor, Q, describes the sharpness of the system's response. Q is equal to the ratio of the center frequency to the bandwidth. ie. Q=fo/bw
Q is also used to describe the amplitude of the resonant response, which is roughly equal to resonant frequency divided by the driving frequency.
The above posts give good information on how to determine the value from circuit component values or circuit performance measurements.
The basic definition is the ratio of the stored energy to the lost energy from dissipation per radian of cyclic oscillation. This basic definition will apply to all systems, such as mechanical and acoustic in addition to electrical.