Skip to content

Confusing variable wh in compare() #9

Description

@dillard064

The compare() function reuses the variable wh for two unrelated purposes and doesn't seem to fit the use for contrasts construction variable cc at the end for some cases:

wh is first defined as:

wh <- is.na(pv$predicted.value)

And then, inside the PVAL branch it is redefined, and only when if length(nterm) > 1:

wh <- coefs[, 1] == 0

however the term is then used again outside if length(nterm) > 1:

cc <- list(coef = (1:lenf)[!wh], type = "con", comp = mat)

which would still point to the first definition is.na(pv$predicted.value) in some branch of the evaluation?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions