HighlanderLab / SIMplyBee

SIMplyBee R package extends AlphaSimR for simulating honeybee populations and breeding programmes
http://www.simplybee.info/
Other
0 stars 5 forks source link

Remove sex #294

Open janaobsteter opened 2 years ago

janaobsteter commented 2 years ago

Some functions use the sex information (createDrones) while others use caste information. We should probably decide:

gregorgorjanc commented 2 years ago

Best to use caste everywhere I think and then we don’t advocate using sex at all!

janaobsteter commented 2 years ago

Do we still keep the sex info, just don't advocate it? Or remove it all together?

gregorgorjanc commented 2 years ago

I think we should remove it altogether. Caste implies sex too, so best to stick to that. But we need to be careful about this change as it will likely break many things.

We really should start adding tests!!! Let’s teach @JerBub and @LStrachan on how to build tests well as we have lots of functionality already and for every such major change I wonder what will work and what won’t!

gregorgorjanc commented 2 years ago

One example where code could be much simpler - using caste instead of sex in reducing drone haplotypes and genotypes - see https://github.com/HighlanderLab/SIMplyBee/issues/326

janaobsteter commented 1 year ago

Just making sure we are still implementing this, so that I don't mention it in the paper?

gregorgorjanc commented 1 year ago

Yes! We have caste. No need to make life more complex to also have sex in my view.

janaobsteter commented 1 year ago

I'll do this while I'm changing some other functions

janaobsteter commented 1 year ago

A question - do we then also want to change the "sex" parameter in functions to "caste"? All genome related functions use the "sex" somwhere in the function.

gregorgorjanc commented 1 year ago

Hmm! This could be tricky! Do all genome functions have the sex arg or just the calc* ones? In calculations we often need to know if genotypes come from haploid individuals (drone and father castes!) or diploid individuals! Maybe we need a utility isHaploid() function so that we can do those calculations?

janaobsteter commented 1 year ago

I will create a list of functions that use sex and we'll see what would be best

janaobsteter commented 1 year ago

We decided to keep this for the submission, since it's more complex than we've anticipated, but we don't want to mention it in the vignettes or the paper

janaobsteter commented 1 year ago

Where do we use sex:

gregorgorjanc commented 1 year ago

Looks like you found a bug!!! Well done;)

gregorgorjanc commented 1 year ago

Hmm, the email notification had a different text! Are we missing droneHaplo arg in some genomics functions?

janaobsteter commented 1 year ago

Yeah,I realized I just overlooked it,all good!!!

janaobsteter commented 1 year ago

We decide to keep it for now due to computational use (saying "M" instead of "drones" and "fathers")