Ratios of top-quark pair to -boson cross sections measured from proton--proton collisions at the LHC centre-of-mass energies of TeV, 8TeV, and 7TeV are presented by the ATLAS Collaboration. Single ratios, at a given for the two processes and at different for each process, as well as double ratios of the two processes at different , are evaluated. The ratios are constructed using previously published ATLAS measurements of the and -boson production cross sections, corrected to a common phase space where required, and a new analysis of where at TeV performed with data collected in 2015 with an integrated luminosity of fb. Correlations of systematic uncertainties are taken into account when evaluating the uncertainties in the ratios. The correlation model is also used to evaluate the combined cross section of the and the channels for each value. The results are compared to calculations performed at next-to-next-to-leading-order accuracy using recent sets of parton distribution functions. The data demonstrate significant power to constrain the gluon distribution function for the Bjorken- values near 0.1 and the light-quark sea for .