Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
brentp committed Nov 13, 2015
1 parent a5d1d09 commit ecfd971
Show file tree
Hide file tree
Showing 30 changed files with 11,617 additions and 57 deletions.
Binary file modified docs/_build/doctrees/environment.pickle
Binary file not shown.
Binary file modified docs/_build/doctrees/index.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/relatedness.doctree
Binary file not shown.
2 changes: 1 addition & 1 deletion docs/_build/html/.buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: afd4f162f81866546b34bf43a60ac9dd
config: 895eb4b97f76d81dda11c2de7331f3e9
tags: 645f666f9bcd5a90fca523b33c5a78b7
7 changes: 5 additions & 2 deletions docs/_build/html/_sources/index.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ corresponding `.vcf` file such as can occur from sample-swaps
or pedigree misspecifications.

The code to do this is quite simple. Below, we check for pedigree
violations by looking at 5,000 sites (see docs for more details on selection)
violations by looking at 5,000 sites (see :doc:`docs <relatedness>` for more details on selection)
and for sex discrepancies by looking at the non-PA regions of the X
chromosome where males should have very few HET calls.

Expand Down Expand Up @@ -70,7 +70,7 @@ And we can see that there are no inferred errors along with other information us

The `ped-check` file will contain `n_samples` \* `n_samples` number of rows like below::

ibs0 ibs2 ibs2* n rel sample_a sample_b pedigree_distance pedigree_parents predicted_parents parent_error
ibs0 ibs2 ibs2* n rel sample_a sample_b pedigree_relatedness pedigree_parents predicted_parents parent_error
0.0801 0.0042 0.0165 4722 0.0245 NA12877 NA12878 0.0000 False False False
0.0000 0.0125 0.0360 4723 0.5401 NA12877 NA12879 0.5000 True True False
0.0000 0.0108 0.0390 4723 0.5482 NA12877 NA12880 0.5000 True True False
Expand All @@ -83,6 +83,9 @@ The `ped-check` file will contain `n_samples` \* `n_samples` number of rows like

Using `IBS0`, we can infer the parent-child relationship of a pair of samples. If the inferred value
doesn't match the relationship in the ped file, then the `parent_error` column will be `True`.
We can see that the first line above has a high `ibs0` value (and low `rel` value) indicating it's
not expected to be a parent-child relation while the rest have low `ibs0` (and high `rel` values).


..
.. toctree::
Expand Down
34 changes: 34 additions & 0 deletions docs/_build/html/_sources/relatedness.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
relatedness calculations
========================

Using cyvcf2, we can quickly calculate relatedness using the method
described in http://www.nature.com/ng/journal/v42/n7/full/ng.608.html in
equation 6.

This is computationally intensive to calculate for the entire genome
and other methods, such as KING (http://www.ncbi.nlm.nih.gov/pubmed/20926424)
have fast methods to do this on the entire genome.

The limitations of these methods is that they assume the average pair of samples
is unrelated.

In `pedagree`, we use about 5,000 variants described in http://www.nature.com/nature/journal/v506/n7487/full/nature12975.html
that are known to be targeted by most exome platforms, in hardy weinberg equilibrium in 1000 genomes,
and mostly unlinked.

When a user requests to calculate relatedness, we use those 5K sites and
the genotypes from the 2504 1KG samples to provide a background of samples so
that most samples are indeed unrelated. Since we are sampling on 5K sites,
the calculations are quite fast (~5 minutes) and match very well what
we get from a whole-genome scan because of the properties of those sites.
Though we use the additional 2504 1KG samples internally, only the information
from the ped/vcf file is returned.

`pedagree` stores the relationships from the pedigree in a graph and can calculate
the expected coefficient of relation from what is specified in the ped file.
We can use this information to compare to what is calculated from the genotypes.

sex QC
------


74 changes: 68 additions & 6 deletions docs/_build/html/_static/basic.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*
* Sphinx stylesheet -- basic theme.
*
* :copyright: Copyright 2007-2014 by the Sphinx team, see AUTHORS.
* :copyright: Copyright 2007-2015 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
Expand Down Expand Up @@ -197,7 +197,10 @@ h3:hover > a.headerlink,
h4:hover > a.headerlink,
h5:hover > a.headerlink,
h6:hover > a.headerlink,
dt:hover > a.headerlink {
dt:hover > a.headerlink,
caption:hover > a.headerlink,
p.caption:hover > a.headerlink,
div.code-block-caption:hover > a.headerlink {
visibility: visible;
}

Expand Down Expand Up @@ -314,6 +317,13 @@ table.docutils {
border-collapse: collapse;
}

table caption span.caption-number {
font-style: italic;
}

table caption span.caption-text {
}

table.docutils td, table.docutils th {
padding: 1px 8px 1px 5px;
border-top: 0;
Expand Down Expand Up @@ -344,6 +354,25 @@ table.citation td {
border-bottom: none;
}

/* -- figures --------------------------------------------------------------- */

div.figure {
margin: 0.5em;
padding: 0.5em;
}

div.figure p.caption {
padding: 0.3em;
}

div.figure p.caption span.caption-number {
font-style: italic;
}

div.figure p.caption span.caption-text {
}


/* -- other body styles ----------------------------------------------------- */

ol.arabic {
Expand Down Expand Up @@ -406,6 +435,10 @@ dl.glossary dt {
font-size: 1.3em;
}

.sig-paren {
font-size: larger;
}

.versionmodified {
font-style: italic;
}
Expand Down Expand Up @@ -471,22 +504,51 @@ table.highlighttable td {
padding: 0 0.5em 0 0.5em;
}

tt.descname {
div.code-block-caption {
padding: 2px 5px;
font-size: small;
}

div.code-block-caption code {
background-color: transparent;
}

div.code-block-caption + div > div.highlight > pre {
margin-top: 0;
}

div.code-block-caption span.caption-number {
padding: 0.1em 0.3em;
font-style: italic;
}

div.code-block-caption span.caption-text {
}

div.literal-block-wrapper {
padding: 1em 1em 0;
}

div.literal-block-wrapper div.highlight {
margin: 0;
}

code.descname {
background-color: transparent;
font-weight: bold;
font-size: 1.2em;
}

tt.descclassname {
code.descclassname {
background-color: transparent;
}

tt.xref, a tt {
code.xref, a code {
background-color: transparent;
font-weight: bold;
}

h1 tt, h2 tt, h3 tt, h4 tt, h5 tt, h6 tt {
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
background-color: transparent;
}

Expand Down
Binary file modified docs/_build/html/_static/bg-page.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
29 changes: 27 additions & 2 deletions docs/_build/html/_static/doctools.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*
* Sphinx JavaScript utilities for all documentation.
*
* :copyright: Copyright 2007-2014 by the Sphinx team, see AUTHORS.
* :copyright: Copyright 2007-2015 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
Expand Down Expand Up @@ -91,6 +91,30 @@ jQuery.fn.highlightText = function(text, className) {
});
};

/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();

var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];

return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}

/**
* Small JavaScript module for the documentation.
*/
Expand Down Expand Up @@ -152,9 +176,10 @@ var Documentation = {

/**
* workaround a firefox stupidity
* see: https://bugzilla.mozilla.org/show_bug.cgi?id=645075
*/
fixFirefoxAnchorBug : function() {
if (document.location.hash && $.browser.mozilla)
if (document.location.hash)
window.setTimeout(function() {
document.location.href += '';
}, 10);
Expand Down
Binary file modified docs/_build/html/_static/down-pressed.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_build/html/_static/down.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_build/html/_static/file.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/_build/html/_static/haiku.css
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* Braden Ewing <brewin@gmail.com>
* Humdinger <humdingerb@gmail.com>
*
* :copyright: Copyright 2007-2014 by the Sphinx team, see AUTHORS.
* :copyright: Copyright 2007-2015 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
Expand Down Expand Up @@ -307,7 +307,7 @@ td {
vertical-align: top;
}

tt {
code {
background-color: #e2e2e2;
font-size: 1.0em;
font-family: monospace;
Expand Down

0 comments on commit ecfd971

Please sign in to comment.