Skip to content

fitsemivariance.py: nugget if statement #3

@SimonMolinsky

Description

@SimonMolinsky

When we calculate theoretical semivariance then we must set a nugget for each model. As I understand from the book (and the code itself) a nugget value should be set to zero (?) even if our first lag distance from empirical semivariance is not 0.0. But I do not understand the else statement in a condition when we set a nugget. Why do we choose the second value of lag if the first is equal to 0? Then we will start with nugget different than 0. Is this a correct way of setting our nugget value?

Code related to the question:

if s[0][0] is not 0.0:      # c0, nugget
  c0 = 0.0
else:
  c0 = s[0][1]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions