Consider the below example reported by Irene Breider, where calling selectInd(..., nInd = -4) removes 4 individuals, which makes sense looking at the selectInd() code (return(pop[take[0:nInd]])), but this can lead to unintended "bugs" in user scripts.
Options:
1) Add bound-checks (negative values) for arguments such as nInd
2) Document behaviour with negative values
Consider the below example reported by Irene Breider, where calling
selectInd(..., nInd = -4)
removes 4 individuals, which makes sense looking at theselectInd()
code (return(pop[take[0:nInd]])
), but this can lead to unintended "bugs" in user scripts.Options: 1) Add bound-checks (negative values) for arguments such as
nInd
2) Document behaviour with negative values@gaynorr what do you suggest?