Open janaobsteter opened 1 year ago
Fair point! They will be available in the queen's misc slot anyway.
@janaobsteter I am looking at this. So we have:
getCastePop(..., removeFathers = TRUE, ...)
at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L93
with docs at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L23 saying
#' @param removeFathers logical, removes \code{drones} that have already mated;
#' set to \code{FALSE} if you would like to get drones for mating with multiple
#' virgin queens, say via insemination
And then we do at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L133
if (caste == "drones" && removeFathers) {
test <- isDrone(pop)
if (any(!test)) {
pop <- pop[test]
}
}
Then we have:
getDrones(..., removeFathers = TRUE, ...)
at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L252C53-L252C73 createDCA(..., removeFathers = TRUE, ...)
at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L759with a note
#' @param removeFathers logical, removes \code{drones} that have already mated;
#' set to \code{FALSE} if you would like to get drones for mating with multiple
#' virgin queens, say via insemination
#'
#' @details In reality, drones leave the colony to mate. They die after that.
#' In this function we only get a copy of drones from \code{x}, for
#' computational efficiency and ease of use. However, any mating will change
#' the caste of drones to fathers, and they won't be available for future
#' matings (see \code{\link{cross}}). Not unless
#' \code{removeFathers = FALSE}.
pullCastePop <- function(..., removeFathers = TRUE, ...)
at https://github.com/HighlanderLab/SIMplyBee/blob/efca86c203d068741f5f680823f1b39e2795b91c/R/Functions_L1_Pop.R#L1015with a note
#' @param removeFathers logical, removes \code{drones} that have already mated;
#' set to \code{FALSE} if you would like to get drones for mating with multiple
#' virgin queens, say via insemination
pullDrones <- function(..., removeFathers = TRUE, ...)
at https://github.com/HighlanderLab/SIMplyBee/blob/758b632b988d1e81833063f494be5091396f9fd5/R/Functions_L1_Pop.R#L1117Now, why do we want to remove this argument? What if we actually want to replicate a drone, say for insemination purposes? Are you saying that if we want to do that (insemination), we would have got/pulled a drone out and used it multiple times and that is why you would like to remove the removeFathers
option - because we should be doing this by default all the time, which we do now, but you would like to hide this from the user?
removeFather = TRUE
by default - this means that the drones that were used in mating are removed when getting out the drones. I think this shouldn't even be an option - these individuals are dead and are only in thedrone
slot for computational reasons - but they shouldn't be accessible by users.