changeset 8:cf6a06a2346c draft

Uploaded
author greg
date Wed, 01 Aug 2018 09:17:15 -0400
parents 869e7d06bdf3
children fd41f452c9fe
files extract_ipm_date_interval.R
diffstat 1 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/extract_ipm_date_interval.R	Wed Aug 01 08:47:20 2018 -0400
+++ b/extract_ipm_date_interval.R	Wed Aug 01 09:17:15 2018 -0400
@@ -16,7 +16,6 @@
 
 get_new_temperature_data_frame = function(input_file) {
     temperature_data_frame = read.csv(file=input_file, header=T, strip.white=TRUE, stringsAsFactors=FALSE, sep=",");
-    colnames(temperature_data_frame) = c("LATITUDE", "LONGITUDE", "DATE", "DOY", "TMIN", "TMAX");
     return(temperature_data_frame);
 }
 
@@ -65,10 +64,10 @@
         date_labels = c(unlist(ticks_and_labels[2]));
     # All latitude values are the same, so get the value
     # for plots from the first row.
-        latitude = temperature_data_frame$LATITUDE[1];
+    latitude = temperature_data_frame$LATITUDE[1];
     # Save the date interval data into an output file
     # named the same as the input.
-    file_path = paste("output_data_dir", input_file, sep="/");
+    file_path = paste("output_data_dir", basename(input_file), sep="/");
     write.csv(temperature_data_frame, file=file_path, row.names=F);
-    # TODO: Save the datE interval plots...
+    # TODO: Save the date interval plots...
 }