#*****************************************************************************80 # ## snowfall_smoothed_plot plots smoothed yearly snowfall data. # # Licensing: # # This code is distributed under the MIT license. # # Modified: # # 21 August 2020 # # Author: # # John Burkardt # cat ( date ( ), "\n" ) cat ( "\n" ) cat ( "snowfall_smoothed_plot\n" ) cat ( " ", version$version.string, "\n" ) cat ( " Make a line plot of smoothed snowfall data.\n" ) filename = "snowfall_data.txt" data <- read.table ( filename, header = FALSE ) year = data[,1] inches = data[,10] inches_smooth = smooth ( inches ) filename = "snowfall_smoothed_plot.png" png ( filename ) plot ( year, inches_smooth, xlab = "Year", ylab = "Total Snow in Inches", main = "(smoothed) Yearly Snowfall at Michigan Tech", type = 'l', col = 'cyan', lwd = 3 ) grid ( ) cat ( ' Graphics saved as "', filename, '"\n' ) # # Terminate. # cat ( "\n" ) cat ( "snowfall_smoothed_plot\n" ) cat ( " Normal end of execution.\n" ) quit ( )