Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with xp.boot.par.est for bootscm #27

Open
rikardn opened this issue Aug 13, 2024 · 0 comments
Open

Problem with xp.boot.par.est for bootscm #27

rikardn opened this issue Aug 13, 2024 · 0 comments

Comments

@rikardn
Copy link
Member

rikardn commented Aug 13, 2024

In the UPSS script for bootscm task 9 is using xp.boot.par.est, which displayed an empty plot. I think that the problem is related to the levels function call here:

lev.ord <- unlist(sapply(lev.ord,function(x) levels(pl.dat$cov)[grep(x,levels(pl.dat$cov))]),use.names = F)

It returns NULL since there is no levels attribute set on the object. Perhaps an earlier behaviour of R levels was to return the elements themselves in this case.

I managed to patch it, by replacing levels with unique

lev.ord <- unlist(sapply(lev.ord,function(x) unique(pl.dat$cov)[grep(x,unique(pl.dat$cov))]),use.names = F) 

This isn't a 100% solution since there will now be an extra .1 in the covariate effect labels as can be seen here:

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant