r - zoo error - $ operator is invalid for atomic vectors -


i've created zoo object in order apply hargreavessamani et (evapotranspiration) function this package.

the input data file here , code i've used below notes.

require(evapotranspiration) require(zoo)  data("constants") oakpark<- read.csv("oakparkr.csv", header=true)  #fill blanks in csv nas na.fill(oakpark,na)  #convert zoo oakpark <- as.zoo(oakpark)  #create zoo series required variables pe.data <- oakpark[ ,c(3,5)]  #defining function , associating data function class funname <- "hargreavessamani" class(pe.data) <- funname 

then when applying function:

results <- et(pe.data,constants) 

i following error:

error in data$tmax : $ operator invalid atomic vectors 

i've tried converting large zoo data frame , trying again et function works on zoo series, didn't work either.

other pages '$ operator invalid atomic vectors' seem suggest changing format of data, need find way around without doing that.


Comments

Popular posts from this blog

mysql - FireDac error 314 - but DLLs are in program directory -

git - How to list all releases of public repository with GitHub API V3 -

c++ - Getting C2512 "no default constructor" for `ClassA` error on the first parentheses of constructor for `ClassB`? -