Problem in Differenced Variance Method in R

Dear R studio user, I am using fractal package for Hurst exponent. However i am facing problem in Difference Variance Method. I have used the below code:

hurstBlock(b, method="diffvar", scale.min=40, scale.max=NULL, scale.ratio=2, weight=function(x) rep(1,length(x)), fit=lm)

But the error message is coming like this:

Error in if (any(scale < 0)) stop("Negative scale(s) not allowed") : 
  missing value where TRUE/FALSE needed

Other methods such as aggabs and aggvar are not showing any error. But for the diffvar it is showing error. Can any one give suggestion.

1 Like

It would be helpful to have some insight into the object b as well as the session info.

Can you please provide a minimal reprex (reproducible example)? The goal of a reprex is to make it as easy as possible for me to recreate your problem so that I can fix it: please help me help you!

If you've never heard of a reprex before, start by reading "What is a reprex", and follow the advice further down that page.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.