<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE article SYSTEM "http://www.atmos-chem-phys.net/inc/acp/copernicus.dtd">
<article language="en">
	<journal>
		<journal_title>Atmospheric Chemistry and Physics</journal_title>
		<journal_url>www.atmos-chem-phys.net</journal_url>
		<issn>1680-7316</issn>
		<eissn>1680-7324</eissn>
		<volume_number>8</volume_number>
		<issue_number>17</issue_number>
		<publication_year>2008</publication_year>
	</journal>
	<doi>10.5194/acp-8-5477-2008</doi>
	<article_url>http://www.atmos-chem-phys.net/8/5477/2008/</article_url>
	<abstract_html>http://www.atmos-chem-phys.net/8/5477/2008/acp-8-5477-2008.html</abstract_html>
	<fulltext_pdf>http://www.atmos-chem-phys.net/8/5477/2008/acp-8-5477-2008.pdf</fulltext_pdf>
	<start_page>5477</start_page>
	<end_page>5487</end_page>
	<publication_date>2008-09-12</publication_date>
	<article_title content_type="html">Technical Note: Review of methods for linear least-squares fitting of data and application to atmospheric chemistry problems</article_title>
	<authors>
		<author numeration="1" affiliations="1">
			<name>C. A. Cantrell</name>
			<email>cantrell@ucar.edu</email>
		</author>
	</authors>
	<affiliations>
		<affiliation numeration="1" content_type="html">National Center for Atmospheric Research Atmospheric Chemistry Division 1850 Table Mesa Drive Boulder, CO 80305, USA</affiliation>
	</affiliations>
	<abstract content_type="html">The representation of data, whether geophysical observations, numerical
model output or laboratory results, by a best fit straight line is a routine
practice in the geosciences and other fields. While the literature is full
of detailed analyses of procedures for fitting straight lines to values with
uncertainties, a surprising number of scientists blindly use the standard
least-squares method, such as found on calculators and in spreadsheet
programs, that assumes no uncertainties in the &lt;i&gt;x&lt;/i&gt; values. Here, the available
procedures for estimating the best fit straight line to data, including
those applicable to situations for uncertainties present in both the &lt;i&gt;x&lt;/i&gt; and
&lt;i&gt;y&lt;/i&gt; variables, are reviewed. Representative methods that are presented in the
literature for bivariate weighted fits are compared using several sample
data sets, and guidance is presented as to when the somewhat more involved
iterative methods are required, or when the standard least-squares procedure
would be expected to be satisfactory. A spreadsheet-based template is made
available that employs one method for bivariate fitting.</abstract>
	<references>
		<reference numeration="1" content_type="text">Barker, D. R. and Diana, L. M.: Simple method for fitting data when both variables have uncertainties, Am. J. Phys., 42, 224–227, 1974. </reference>
		<reference numeration="2" content_type="text">Bevington, P. R.: Data reduction error analysis for the physical sciences, McGraw-Hill Book Company, New York, 1969. </reference>
		<reference numeration="3" content_type="text">Borcherds, P. H. and Sheth, C. V.: Least squares fitting of a straight line to a set of data points, Eur. J. Phys. 16, 1, 204–210, 1995. </reference>
		<reference numeration="4" content_type="text">Brauers, T. and Finlayson-Pitts, B. J.: Analysis of relative rate measurements, Int. J. Chem. Kin., 29, 665–672, 1997. </reference>
		<reference numeration="5" content_type="text">Bruzzone H. and Moreno, C.: When errors in both coordinates make a difference in the fitting of straight lines by least squares, Meas. Sci. Technol., 9, 2007–2011, 1998. </reference>
		<reference numeration="6" content_type="text">Cantrell, C. A., Edwards, G. D., Stephens, S., Mauldin, R. L., Zondlo, M. A., Kosciuch, E., Eisele, F. L., Shetter, R. E., Lefer, B. L., Hall, S., Flocke, F., Weinheimer, A. Fried, E. Apel, Y. Kondo, D. R. Blake, N. J. Blake, I. J. Simpson, A., Bandy, A. R., Thornton, D. C., Heikes, B. G., Singh, H. B., Brune, W. H., Harder, H., Martinez, M., Jacob, D. J., Avery, M. A., Barrick, J. D., Sachse, G. W., Olson, J. R., Crawford, J. H., and Clark, A. D.: Peroxy radical behavior during the Transport and Chemical Evolution over the Pacific (TRACE-P) campaign as measured aboard the NASA P-3B aircraft, J. Geophys. Res., 108(D20), 8797, doi:10.1029/2003JD003674, 2003. </reference>
		<reference numeration="7" content_type="text">Cecchi, G. C.: Error analysis of the parameters of a least-squares determined curve when both variables have uncertainties, Meas. Sci. Technol., 2, 1127–1128, 1991. </reference>
		<reference numeration="8" content_type="text">Chong, D. P.: Comment on &quot;Linear least-squares fits with errors in both coordinates&quot; by B. C. Reed, Am. J. Phys. 57, 642–646, 1989, Am. J. Phys., 59, 472–474, 1991. </reference>
		<reference numeration="9" content_type="text">Chong, D. P.: On the use of least squares to fit data in linear form, J. Chem. Ed., 71, 489–490, 1994. </reference>
		<reference numeration="10" content_type="text">Christian, S. D. and Tucker, E. E.: Analysis with the microcomputer. 5. General least-squares with variable weighting, Am. Lab., 16(2), 18–18, 1984. </reference>
		<reference numeration="11" content_type="text">Christian, S. D., Tucker, E. E., and Enwall, E.: Least-squares analysis: A primer, Am. Lab., 18, 41–49, 1986. </reference>
		<reference numeration="12" content_type="text">Crawford, J., Davis, D., Olson, J., Chen, G., Liu, S., Gregory, G., Barrick, J., Sachse, G., Sandholm, S., Heikes, B., Singh, H., and Blake, D.: Assessment of upper tropospheric HO&lt;sub&gt;x&lt;/sub&gt; sources over the tropical Pacific based on NASA GTE/PEM data: Net effect on HO&lt;sub&gt;x&lt;/sub&gt; and other photochemical parameters, J. Geophys. Res., 104(D13), 16 255–16 273, 1999. </reference>
		<reference numeration="13" content_type="text">Dean, R. B. and Dixon, W. J.: Simplified statistics for small numbers of observations, Anal. Chem., 23, 636–638, doi:10.1021/ac60052a025, 1951. </reference>
		<reference numeration="14" content_type="text">Faloona, I., Tan, D., Brune, W. H., Jaeglé, L., Jacob, D. J., Kondo, Y., Koike, M., Chatfield, R., Pueschel, R., Ferry, G., Sachse, G., Vay, S., Anderson, B., Hannon, J., and Fuelberg, H.: Observations of HO&lt;sub&gt;x&lt;/sub&gt; and its relationship with NO&lt;sub&gt;x&lt;/sub&gt; in the upper troposphere during SONEX, J. Geophys. Res., 105(D3), 3771–3783, 2000. </reference>
		<reference numeration="15" content_type="text">Fried, A., Crawford, J., Olson, J., Walega, J., Potter, W., Wert, B., Jordan, C., Anderson, B., Shetter, R., Lefer, B., Blake, D., Blake, N., Meinardi, S., Heikes, B., O&apos;Sullivan, D., Snow, J., Fuelberg, H., Kiley, C. M., Sandholm, S., Tan, D., Sachse, G., Singh, H., Faloona, I., Harward, C. N., and Carmichael, G. R.: Airborne tunable diode laser measurements of formaldehyde during TRACE-P: Distributions and box model comparisons, J. Geophys. Res., 108(D20), 8798, doi:10/1029/2003JD003451, 2003. </reference>
		<reference numeration="16" content_type="text">Gonzalez, A. G., Marquez, A., and Fernandez Sanz, J.: An iterative algorithm for consistent and unbiased estimation of linear regression parameters when there are errors in both the $x$ and $y$ variables, Computers Chem., 16(1), 25–27, 1992. </reference>
		<reference numeration="17" content_type="text">Irwin, J. A. and Quickenden, T. I.: Linear least squares treatement when there are errors in both $x$ and $y$, J. Chem. Ed., 60(5), 711–712, 1983. </reference>
		<reference numeration="18" content_type="text">Jones, T. A.: Fitting straight lines when both variables are subject to error. I. Maximum likelihood and least-squares estimation, Math. Geo., 11(1), 1–25, 1979. </reference>
		<reference numeration="19" content_type="text">Kalantar, A. H.: Weighted least squares evaluation of slope from data having errors in both axes, Trends in Anal. Chem., 9(1), 149–151, 1990. </reference>
		<reference numeration="20" content_type="text">Kalantar, A. H.: Kerrich&apos;s method for \textity=$\alpha x$ data when both $y$ and $x$ are uncertain, J. Chem Ed., 68(1), 368–370, 1991. </reference>
		<reference numeration="21" content_type="text">Kalantar, A. H.: Straight-line parameters&apos; errors propagated from the errors in both coordinates, Meas. Sci. Technol., 3, 1113–1113, 1992. </reference>
		<reference numeration="22" content_type="text">Kalantar, A. H., Gelb, R. I., and Alper, J. S.: Biases in summary statistics of slopes and intercepts in linear regression with errors in both variables, Talanta, 42(4), 597–603, 1995. </reference>
		<reference numeration="23" content_type="text">Krane, K. S. and Schecter, L.: Regression line analysis, Am. J. Phys., 50(1), 82–84, 1982. </reference>
		<reference numeration="24" content_type="text">Leduc, D. J.: A comparative analysis of the reduced major axis technique of fitting lines to bivariate data, Can. J. For. Res., 17, 654–659, 1987. </reference>
		<reference numeration="25" content_type="text">Lybanon, M.: A better least-squares method when both variables have uncertainties, Am. J. Phys., 52(1), 22–26, 1984a. </reference>
		<reference numeration="26" content_type="text">Lybanon, M.: Comment on &quot;Least squares when both variables have uncertainties&quot;, Am. J. Phys., 52(3), 276–278, 1984b. </reference>
		<reference numeration="27" content_type="text">Lybanon, M.: A simple generalized least-squares algorithm, Comp. Geosci., 11, 501–508, 1985. </reference>
		<reference numeration="28" content_type="text">Macdonald, J. R. and Thompson, W. J.: Least-squares fitting when both variables contain errors: Pitfalls and possibilities, Am. J. Phys., 60(1), 66–73, 1992. </reference>
		<reference numeration="29" content_type="text">MacTaggart, D. L. and Farwell, S. O.: Analytical use of linear regression, Part II: Statistical error in both variables, J. AOAC Intl., 75(4), 608–614, 1992. </reference>
		<reference numeration="30" content_type="text">Markovsky, I. and Van Huffel, S.: Overview of total least-squares methods, Sig. Proc., 87, 2283–2302, 2007. </reference>
		<reference numeration="31" content_type="text">Moreno, C., and Bruzzone, H.: Parameters&apos; variances of a least-squares determined straight line with errors in both coordinates, Meas. Sci. Technol., 4, 635–636, 1993. </reference>
		<reference numeration="32" content_type="text">Moreno, C.: A least-squares-based method for determining the ratio between two measured quantities, Meas. Sci. Technol., 7, 137–141,1996. </reference>
		<reference numeration="33" content_type="text">Neri, F., G. Saitta, and S. Chiofalo: An accurate and straightforward approach to line regression analysis of error-affected experimental data, J. Phys. E: Sci. Inst., 22, 215–217, 1989. </reference>
		<reference numeration="34" content_type="text">Neri, F., Patanè, S., and Saitta, G.: Error-affected experimental data analysis: application to fitting procedure, Meas. Sci. Technol., 1, 1007–1010, 1990. </reference>
		<reference numeration="35" content_type="text">Olson, J. R., Crawford, J. H., Chen, G., Fried, A., Evans, M. J., Jordan, C. E., Sandholm, S. T., Davis, D. D., Anderson, B. E., Avery, M. A., Barrick, J. D., Black, D. R., Brune, W. H., Eisele, F. L., Flocke, F., Harder, H., Jacob, D. J., Kondo, Y., Lefer, B. L., Martinez, M., Mauldin, R. L., Sachse, G. W., Shetter, R. E., Singh, H. B., Talbot, R. W., and Tan, D.: Testing fast photochemical theory during TRACE-P based on measurements of OH, HO&lt;sub&gt;2&lt;/sub&gt;, and CH&lt;sub&gt;2&lt;/sub&gt;O, J. Geophys. Res., 109, D15S10, doi:10.1029/2003JD004278, 2004. </reference>
		<reference numeration="36" content_type="text">Olson, J. R., Crawford, J. H., Chen, G., Brune, W. H., Faloona, I. C., Tan, D., Harder, H., and Martinez, M.: A reevaluation of airborne HO$_x$ observations from NASA field campaigns, J. Geophys. Res., 111, D10301, doi: 10.1029/2005/JD006617, 2006. </reference>
		<reference numeration="37" content_type="text">Orear, J.: Least squares when both variables have uncertainties, Am. J. Phys., 50, 912–916, 1982; Erratum, Am. J. Phys., 52, 278–278, 1984. </reference>
		<reference numeration="38" content_type="text">Pasachoff, J. M.: Applicability of least-squares formula, Am. J. Phys., 48(10), 800–800, 1980. </reference>
		<reference numeration="39" content_type="text">Pearson, K.: On lines and planes of closet fit to systems of points in space, Philos. Mag., 2(2), 559–572, 1901. </reference>
		<reference numeration="40" content_type="text">Press, W. H., Teukolsky, S. A., Vetterling, W. T., and Flannery, B. P.: Numerical Recipes in C, 2nd ed., Cambridge University Press, 1992a. </reference>
		<reference numeration="41" content_type="text">Press, W. H., Teukolsky, S. A., Vetterling, W. T., and Flannery, B. P.: Numerical Recipes in Fortran, 2nd ed., Cambridge University Press, 1992b. </reference>
		<reference numeration="42" content_type="text">Reed, B. C.: Linear least-squares fits with errors in both coordinates, Am. J. Phys., 57(3), 642–646, 1989; Erratum, Am J. Phys., 58(2), 189–189, 1990. </reference>
		<reference numeration="43" content_type="text">Reed, B. C.: Linear least-squares fits with errors in both coordinates. II: Comments on parameter variances, Am. J. Phys., 60(1), 59–62, 1992. </reference>
		<reference numeration="44" content_type="text">Riu, J. and Rius, F. X.: Univariate regression models with errors in both axes, J. Chemometrics, 9, 343–362, 1995. </reference>
		<reference numeration="45" content_type="text">Sheth, C. V. A.: Ngwengwe, and P. H. Borcherds, Least squares fitting of a straight line to a set of data points: II: Parameter variances, Eur. J. Phys., 17(2), 322–326, 1996. </reference>
		<reference numeration="46" content_type="text">Squire, P. T.: Comment on &quot;Linear least-squares fits with errors in both coordinates&quot; by B. C. Reed, Am. J. Phys. 57, 642–646, 1989, Am. J. Phys., 58(12), 1209–1209, 1990. </reference>
		<reference numeration="47" content_type="text">Titterington, D. M. and Halliday, A. N.: On the fitting of parallel isochrones and the method of maximum likelihood, Chem. Geol. 26, 183–195, 1979. </reference>
		<reference numeration="48" content_type="text">Williamson, J. H.: Least-squares fitting of a straight line, Can. J. Phys., 46, 1845–1847, 1968. </reference>
		<reference numeration="49" content_type="text">York, D.: Least-squares fitting of a straight line, Can. J. Phys., 44, 1079–1086, 1966. </reference>
		<reference numeration="50" content_type="text">York, D.: Least squares fitting of a straight line with correlated errors, Earth and Planet. Sci. Lett., 5, 320–324, 1969. </reference>
		<reference numeration="51" content_type="text">York, D., Evensen, N. M., López Martinez, M., and De Basabe Delgado, J.: Unified equations for the slope, intercept, and standard errors of the best straight line, Am J. Phys., 72(3), 367–375, 2004. </reference>
	</references>
</article>

