Skip to content

Commit

Permalink
more flexible handling of comments in weather data files
Browse files Browse the repository at this point in the history
Former-commit-id: 4ff4240
  • Loading branch information
dschlaep committed Apr 14, 2015
1 parent 0336455 commit 81d0b6e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ if(createWeatherDatabaseFromLookupWeatherFolderOrMaurer2002) {
weatherData <- list()
for(j in 1:length(weath)) {
year <- as.numeric(sub(pattern="weath.",replacement="",weath[j]))
temp <-as.matrix(read.csv(file.path(WeatherFolder,weath[j]),header=FALSE,skip=2,sep="\t"))
temp <-as.matrix(read.table(file.path(WeatherFolder,weath[j]),header=FALSE, comment.char = "#", blank.lines.skip=TRUE, sep="\t"))
weatherData[[j]] <- new("swWeatherData",year=year,data=temp)
}
names(weatherData) <- years
Expand Down

0 comments on commit 81d0b6e

Please sign in to comment.