ABSTRACT

This chapter demonstrates the fitting of curves to data, in particular, exponential, polynomial, log, logistic, and power curves by using examples. It uses the real-world data, such as US solar capacity, Arctic sea ice extent, and Germany solar capacity, for the examples of exponential, polynomial, and logistic curve fittings, respectively. The chapter provides an understanding that functions such as summary or names return similar results while demonstrating the exponential fit. For polynomial fit, the Arctic sea ice extent data is modeled by a sixth degree polynomial using lm function, and the sixth degree polynomial is defined by the poly function.