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

Error when creating a matrix in section 6.7 Real Case Study with HMSC: How Do Plant Traits Influence Their Distribution? #207

Open
mhb-bfg opened this issue Jan 16, 2025 · 0 comments

Comments

@mhb-bfg
Copy link

mhb-bfg commented Jan 16, 2025

When I use the Whittaker revisit data to run this code:
for (i in 1:n){
for (j in 1:ns){
row = data$site==sites[i] & data$species==
species[j]
Y[i,j] = data[row,]$value
env[i] = data[row,]$env
trait[j] = data[row,]$trait
}
}
I encounter the following error:
Error in [<-(*tmp*, i, j, value = data[row, ]$value) : subscript out of bounds
whittaker revisit data.csv

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