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

🔖 release v0.9.7 #28

Open
wants to merge 31 commits into
base: master
Choose a base branch
from
Open

🔖 release v0.9.7 #28

wants to merge 31 commits into from

Conversation

filippob
Copy link
Collaborator

@filippob filippob commented Jan 5, 2022

Improving the output of the function tableRuns

Description

On the devel branch, the code of the function tableRuns has been modified to add a column named avg_pct to the output dataframe

Related Issue

close #43
close #39
close #31
close #36
close #17

Motivation and Context

It adds a piece of relevant information to the output of the function tableRuns (ROH/HRR islands)

How Has This Been Tested?

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

filippob and others added 28 commits January 5, 2022 18:36
a new output variable has been added to keep track of the average percentage of samples in which SNPs are "in runs"
the new output variable is named avg_pct and is a column added at the end of the output data.frame
snpInsideRuns(Cpp) is now internal
check runs where SNP are major or equal the threshold specified
rewrite code to calculate percentages correctly
correctly skip empty subset
no more copy values from dataframe
…Runs

Set guides(fill="none") since ggplot2 deprecated guides(fill=FALSE)
👽 set guides(fill="none") in plot_InbreedingChr and plot_DistributionRuns
@codecov
Copy link

codecov bot commented May 9, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (e383906) 51.11% compared to head (efc5c72) 59.01%.

❗ Current head efc5c72 differs from pull request most recent head 567859e. Consider uploading reports for the commit 567859e to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #28      +/-   ##
==========================================
+ Coverage   51.11%   59.01%   +7.89%     
==========================================
  Files           6        6              
  Lines        1254     1359     +105     
==========================================
+ Hits          641      802     +161     
+ Misses        613      557      -56     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

filippob added 2 commits May 9, 2023 15:33
⚡ refactor tableRuns to better manage memory
- added a comment on the need for chromosomes to be numerically coded
- in the vignette, the description of the `summary_ROH_mean_chr` dataset from `summaryRuns()` has been corrected
- the documentation of the function `summaryRuns` has been expanded
@bunop bunop changed the title Devel 🔖 release v0.9.7 May 9, 2023
@filippob
Copy link
Collaborator Author

filippob commented May 9, 2023

Ready to merge for me

Copy link
Contributor

@bunop bunop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that issue #41 should be addressed before merging

@@ -243,7 +243,16 @@ Froh_inbreedingClass <- function(runs, mapFile, Class=2){
#'
#' @return A list of dataframes containing the most relevant descriptives
#' statistics on detected runs. The list conveniently contains 9 dataframes that can
#' be used for further processing and visualization, or can be written out to text files
#' be used for further processing and visualization, or can be written out to text files:
#' 1) summary_ROH_count_chr: n. of runs per chromosome and breed/group;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This list will be rendered as a plain text. Consider using list with roxygen, for example:

#' \enumerate{
#'  \item{summary_ROH_count_chr: }{n. of runs per chromosome and breed/group}
#'  \item{summary_ROH_percentage_chr: }{percent distribution of runs per chromosome in each breed/group (sum to 1)}
#'  \item{summary_ROH_count: }{n. of runs per size-class (Mb) in each breed/group}
#' <add all the other items>
#' }

#' 6) summary_ROH_mean_class: average size of runs (Mb) per size-class (Mb) in each breed/group
#' 7) result_Froh_genome_wide: genome-wide inbreeding ($F_{ROH}$) for each individual in the dataset
#' 8) result_Froh_chromosome_wide inbreeding ($F_{ROH}$) for each individual (and chromosome) in the dataset
#' 9) result_Froh_class: genome-wide inbreeding ($F_{ROH}$) for each individual in the dataset per size-class (Mb) of runs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There could be a 10th item when providing snpInRuns=TRUE as parameter

#'
#' @param genotypeFile genotype (.ped) file path
#' @param mapFile map file (.map) file path
#' @param mapFile map file (.map) file path (chromosomes should be numeric)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will be better to check chromosomes in readMapFile directly and throw an error here?

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