Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Issue with link function in Mundlak Machine bonus content #450

Open
@GuiMarthe

Description

Hello folks

There seems to be a bug somewhere in the link function or model definition in the Mundlack Machine script.

In line 151 from https://github.com/rmcelreath/stat_rethinking_2024/blob/main/scripts/12_bonus_mundlak.r#L151 you are creating predictions from the posterior samples on top of the data.

But I keep getting the following error

> pf0 <- link(mf,data=list(g=1:N_groups,X=rep(0,N_groups)))
Error in Z[TRUE, g[i]] : incorrect number of dimensions

And it seems due to the usage of g as an index variable, but I couldn't figure it out.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /