Please can someone help with a solution for running Discrete wavelet transform in R.
I have tried with the following data format; Year
, Rain
.
Year is in form of 1970,1972,1973.... and Rain in form of 200, 85, 34, 56 23, 0.5... etc. I don't know if my data frame is correct. or if i need to do something to the data before I run it.
Haven't saved the data.frame as wave, I ran as:
rain.dwt.01 <- wavDWT(wave)
Here is my code:
getwd()
setwd("C:\\Users\\dell\\Desktop\\ANN")
wave<-read.csv(file.choose(),header = T)
library(wmtsa)
library(wavelets)
library(waveslim)
library(MASS)
library(wavethresh) ### loaded auxillary functions from Internet
con <- url("faculty.washington.edu/dbp/R-CODE/workshop.Rdata")
print(load(con))
close(con)
lplot(wave)
abline(h=mean(wave),lty="dotted",col="red")
rain.dwt.01 <- wavDWT(wave)
I got this error:
Error in itCall("RS_wavelets_transform_discrete_wavelet_convolution", :
(list) object cannot be coerced to type 'double
Please help with example so I can understand why this error appears