{"action":"created","comment":{"url":"https://api.github.com/repos/hail-is/hail/pulls/comments/93821087","pull_request_review_id":14356337,"id":93821087,"diff_hunk":"@@ -830,13 +1081,43 @@ def hardcalls(self):\n     def ibd(self, output, maf=None, unbounded=False, min=None, max=None):\n         \"\"\"Compute matrix of identity-by-descent estimations.\n \n+        **Examples**\n+\n+        Suppose we have a variant annotation ``va.panel_maf`` of allele\n+        frequencies computed from a reference panel. Then\n+\n+        >>> (hc.read('example.vds')\n+        >>>  .ibd('ibd.tsv', maf='va.panel_maf', min=0.2, max=0.9)\n+\n+        outputs to ``ibd.tsv`` only those sample pairs with ``pi_hat`` between 0.2 and 0.9 inclusive, using the the provided expression for the minor allele frequency.\n+\n+        To writes the full IBD matrix to `ibd.tsv` with the minor allele frequency computed from the dataset:\n+\n+        >>> (hc.read('example.vds')\n+        >>>  .ibd('ibd.tsv'\n+\n+        **Notes**\n+\n+        The implementation is based on the IBD algorithm described in the `PLINK paper <http://www.ncbi.nlm.nih.gov/pmc/articles/PMC1950838>`_.\n+\n+        ``ibd`` requires the dataset to be bi-allelic (otherwise run ``split_multi``). ``ibd`` does not perform LD\n+        pruning though linkage disequilibrium may adversely impact the result.\n+\n+        Conceptually, the output is a symmetric, sample-by-sample matrix. The output .tsv has the following form::\n+\n+          SAMPLE_ID_1\tSAMPLE_ID_2\tZ0\tZ1\tZ2\tPI_HAT\n+          sample1\tsample2\t1.0000\t0.0000\t0.0000\t0.0000\n+          sample1\tsample3\t1.0000\t0.0000\t0.0000\t0.0000\n+          sample1\tsample4\t0.6807\t0.0000\t0.3193\t0.3193\n+          sample1\tsample5\t0.1966\t0.0000\t0.8034\t0.8034\n+\n         :param str output: Output .tsv file for IBD matrix.\n \n         :param maf: Expression for the minor allele frequency.\n         :type maf: str or None\n \n         :param bool unbounded: Allows the estimations for Z0, Z1, Z2,\n-            and PI_HAT to take on biologically-nonsense values\n+            and PI_HAT to take on biologically nonsensical values\n             (e.g. outside of [0,1]).\n ","path":"python/pyhail/dataset.py","position":345,"original_position":345,"commit_id":"83d7f7064ea785a1060b80d1fc4fbd594959e626","original_commit_id":"83d7f7064ea785a1060b80d1fc4fbd594959e626","user":{"login":"jigold","id":1693348,"avatar_url":"https://avatars.githubusercontent.com/u/1693348?v=3","gravatar_id":"","url":"https://api.github.com/users/jigold","html_url":"https://github.com/jigold","followers_url":"https://api.github.com/users/jigold/followers","following_url":"https://api.github.com/users/jigold/following{/other_user}","gists_url":"https://api.github.com/users/jigold/gists{/gist_id}","starred_url":"https://api.github.com/users/jigold/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jigold/subscriptions","organizations_url":"https://api.github.com/users/jigold/orgs","repos_url":"https://api.github.com/users/jigold/repos","events_url":"https://api.github.com/users/jigold/events{/privacy}","received_events_url":"https://api.github.com/users/jigold/received_events","type":"User","site_admin":false},"body":":rtype: and :return:","created_at":"2016-12-24T20:22:10Z","updated_at":"2016-12-24T20:48:27Z","html_url":"https://github.com/hail-is/hail/pull/1216#discussion_r93821087","pull_request_url":"https://api.github.com/repos/hail-is/hail/pulls/1216","_links":{"self":{"href":"https://api.github.com/repos/hail-is/hail/pulls/comments/93821087"},"html":{"href":"https://github.com/hail-is/hail/pull/1216#discussion_r93821087"},"pull_request":{"href":"https://api.github.com/repos/hail-is/hail/pulls/1216"}}},"pull_request":{"url":"https://api.github.com/repos/hail-is/hail/pulls/1216","id":99251267,"html_url":"https://github.com/hail-is/hail/pull/1216","diff_url":"https://github.com/hail-is/hail/pull/1216.diff","patch_url":"https://github.com/hail-is/hail/pull/1216.patch","issue_url":"https://api.github.com/repos/hail-is/hail/issues/1216","number":1216,"state":"open","locked":false,"title":"Move docs for 11 commands to Python API","user":{"login":"jbloom22","id":3201642,"avatar_url":"https://avatars.githubusercontent.com/u/3201642?v=3","gravatar_id":"","url":"https://api.github.com/users/jbloom22","html_url":"https://github.com/jbloom22","followers_url":"https://api.github.com/users/jbloom22/followers","following_url":"https://api.github.com/users/jbloom22/following{/other_user}","gists_url":"https://api.github.com/users/jbloom22/gists{/gist_id}","starred_url":"https://api.github.com/users/jbloom22/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbloom22/subscriptions","organizations_url":"https://api.github.com/users/jbloom22/orgs","repos_url":"https://api.github.com/users/jbloom22/repos","events_url":"https://api.github.com/users/jbloom22/events{/privacy}","received_events_url":"https://api.github.com/users/jbloom22/received_events","type":"User","site_admin":false},"body":"```\r\npca.md\r\nannotatevariants_bed.md\r\ngrep.md\r\nannotatesamples_list.md\r\nimportgen.md\r\nannotatesamples_table.md\r\nrenamesamples.md\r\nvariantqc.md\r\nibd.md\r\nexportgenotypes.md\r\nannotateglobal_list.md\r\n```","created_at":"2016-12-23T14:58:37Z","updated_at":"2016-12-24T20:48:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e81b1ce169cf67983ad6737c694587c09b9f8c5d","assignee":{"login":"cseed","id":1244990,"avatar_url":"https://avatars.githubusercontent.com/u/1244990?v=3","gravatar_id":"","url":"https://api.github.com/users/cseed","html_url":"https://github.com/cseed","followers_url":"https://api.github.com/users/cseed/followers","following_url":"https://api.github.com/users/cseed/following{/other_user}","gists_url":"https://api.github.com/users/cseed/gists{/gist_id}","starred_url":"https://api.github.com/users/cseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cseed/subscriptions","organizations_url":"https://api.github.com/users/cseed/orgs","repos_url":"https://api.github.com/users/cseed/repos","events_url":"https://api.github.com/users/cseed/events{/privacy}","received_events_url":"https://api.github.com/users/cseed/received_events","type":"User","site_admin":false},"assignees":[{"login":"cseed","id":1244990,"avatar_url":"https://avatars.githubusercontent.com/u/1244990?v=3","gravatar_id":"","url":"https://api.github.com/users/cseed","html_url":"https://github.com/cseed","followers_url":"https://api.github.com/users/cseed/followers","following_url":"https://api.github.com/users/cseed/following{/other_user}","gists_url":"https://api.github.com/users/cseed/gists{/gist_id}","starred_url":"https://api.github.com/users/cseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cseed/subscriptions","organizations_url":"https://api.github.com/users/cseed/orgs","repos_url":"https://api.github.com/users/cseed/repos","events_url":"https://api.github.com/users/cseed/events{/privacy}","received_events_url":"https://api.github.com/users/cseed/received_events","type":"User","site_admin":false},{"login":"jigold","id":1693348,"avatar_url":"https://avatars.githubusercontent.com/u/1693348?v=3","gravatar_id":"","url":"https://api.github.com/users/jigold","html_url":"https://github.com/jigold","followers_url":"https://api.github.com/users/jigold/followers","following_url":"https://api.github.com/users/jigold/following{/other_user}","gists_url":"https://api.github.com/users/jigold/gists{/gist_id}","starred_url":"https://api.github.com/users/jigold/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jigold/subscriptions","organizations_url":"https://api.github.com/users/jigold/orgs","repos_url":"https://api.github.com/users/jigold/repos","events_url":"https://api.github.com/users/jigold/events{/privacy}","received_events_url":"https://api.github.com/users/jigold/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/hail-is/hail/pulls/1216/commits","review_comments_url":"https://api.github.com/repos/hail-is/hail/pulls/1216/comments","review_comment_url":"https://api.github.com/repos/hail-is/hail/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hail-is/hail/issues/1216/comments","statuses_url":"https://api.github.com/repos/hail-is/hail/statuses/83d7f7064ea785a1060b80d1fc4fbd594959e626","head":{"label":"jbloom22:jb_move_docs","ref":"jb_move_docs","sha":"83d7f7064ea785a1060b80d1fc4fbd594959e626","user":{"login":"jbloom22","id":3201642,"avatar_url":"https://avatars.githubusercontent.com/u/3201642?v=3","gravatar_id":"","url":"https://api.github.com/users/jbloom22","html_url":"https://github.com/jbloom22","followers_url":"https://api.github.com/users/jbloom22/followers","following_url":"https://api.github.com/users/jbloom22/following{/other_user}","gists_url":"https://api.github.com/users/jbloom22/gists{/gist_id}","starred_url":"https://api.github.com/users/jbloom22/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbloom22/subscriptions","organizations_url":"https://api.github.com/users/jbloom22/orgs","repos_url":"https://api.github.com/users/jbloom22/repos","events_url":"https://api.github.com/users/jbloom22/events{/privacy}","received_events_url":"https://api.github.com/users/jbloom22/received_events","type":"User","site_admin":false},"repo":{"id":64696976,"name":"hail","full_name":"jbloom22/hail","owner":{"login":"jbloom22","id":3201642,"avatar_url":"https://avatars.githubusercontent.com/u/3201642?v=3","gravatar_id":"","url":"https://api.github.com/users/jbloom22","html_url":"https://github.com/jbloom22","followers_url":"https://api.github.com/users/jbloom22/followers","following_url":"https://api.github.com/users/jbloom22/following{/other_user}","gists_url":"https://api.github.com/users/jbloom22/gists{/gist_id}","starred_url":"https://api.github.com/users/jbloom22/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbloom22/subscriptions","organizations_url":"https://api.github.com/users/jbloom22/orgs","repos_url":"https://api.github.com/users/jbloom22/repos","events_url":"https://api.github.com/users/jbloom22/events{/privacy}","received_events_url":"https://api.github.com/users/jbloom22/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jbloom22/hail","description":"Hail, a framework for scalable genetic data analysis","fork":true,"url":"https://api.github.com/repos/jbloom22/hail","forks_url":"https://api.github.com/repos/jbloom22/hail/forks","keys_url":"https://api.github.com/repos/jbloom22/hail/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jbloom22/hail/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jbloom22/hail/teams","hooks_url":"https://api.github.com/repos/jbloom22/hail/hooks","issue_events_url":"https://api.github.com/repos/jbloom22/hail/issues/events{/number}","events_url":"https://api.github.com/repos/jbloom22/hail/events","assignees_url":"https://api.github.com/repos/jbloom22/hail/assignees{/user}","branches_url":"https://api.github.com/repos/jbloom22/hail/branches{/branch}","tags_url":"https://api.github.com/repos/jbloom22/hail/tags","blobs_url":"https://api.github.com/repos/jbloom22/hail/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jbloom22/hail/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jbloom22/hail/git/refs{/sha}","trees_url":"https://api.github.com/repos/jbloom22/hail/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jbloom22/hail/statuses/{sha}","languages_url":"https://api.github.com/repos/jbloom22/hail/languages","stargazers_url":"https://api.github.com/repos/jbloom22/hail/stargazers","contributors_url":"https://api.github.com/repos/jbloom22/hail/contributors","subscribers_url":"https://api.github.com/repos/jbloom22/hail/subscribers","subscription_url":"https://api.github.com/repos/jbloom22/hail/subscription","commits_url":"https://api.github.com/repos/jbloom22/hail/commits{/sha}","git_commits_url":"https://api.github.com/repos/jbloom22/hail/git/commits{/sha}","comments_url":"https://api.github.com/repos/jbloom22/hail/comments{/number}","issue_comment_url":"https://api.github.com/repos/jbloom22/hail/issues/comments{/number}","contents_url":"https://api.github.com/repos/jbloom22/hail/contents/{+path}","compare_url":"https://api.github.com/repos/jbloom22/hail/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jbloom22/hail/merges","archive_url":"https://api.github.com/repos/jbloom22/hail/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jbloom22/hail/downloads","issues_url":"https://api.github.com/repos/jbloom22/hail/issues{/number}","pulls_url":"https://api.github.com/repos/jbloom22/hail/pulls{/number}","milestones_url":"https://api.github.com/repos/jbloom22/hail/milestones{/number}","notifications_url":"https://api.github.com/repos/jbloom22/hail/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jbloom22/hail/labels{/name}","releases_url":"https://api.github.com/repos/jbloom22/hail/releases{/id}","deployments_url":"https://api.github.com/repos/jbloom22/hail/deployments","created_at":"2016-08-01T19:51:47Z","updated_at":"2016-08-01T19:51:49Z","pushed_at":"2016-12-23T17:33:25Z","git_url":"git://github.com/jbloom22/hail.git","ssh_url":"git@github.com:jbloom22/hail.git","clone_url":"https://github.com/jbloom22/hail.git","svn_url":"https://github.com/jbloom22/hail","homepage":"","size":8823,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"hail-is:master","ref":"master","sha":"f5b14a372db3a839b2f83a5dfa602e33ca61fe0b","user":{"login":"hail-is","id":20861792,"avatar_url":"https://avatars.githubusercontent.com/u/20861792?v=3","gravatar_id":"","url":"https://api.github.com/users/hail-is","html_url":"https://github.com/hail-is","followers_url":"https://api.github.com/users/hail-is/followers","following_url":"https://api.github.com/users/hail-is/following{/other_user}","gists_url":"https://api.github.com/users/hail-is/gists{/gist_id}","starred_url":"https://api.github.com/users/hail-is/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hail-is/subscriptions","organizations_url":"https://api.github.com/users/hail-is/orgs","repos_url":"https://api.github.com/users/hail-is/repos","events_url":"https://api.github.com/users/hail-is/events{/privacy}","received_events_url":"https://api.github.com/users/hail-is/received_events","type":"Organization","site_admin":false},"repo":{"id":45069467,"name":"hail","full_name":"hail-is/hail","owner":{"login":"hail-is","id":20861792,"avatar_url":"https://avatars.githubusercontent.com/u/20861792?v=3","gravatar_id":"","url":"https://api.github.com/users/hail-is","html_url":"https://github.com/hail-is","followers_url":"https://api.github.com/users/hail-is/followers","following_url":"https://api.github.com/users/hail-is/following{/other_user}","gists_url":"https://api.github.com/users/hail-is/gists{/gist_id}","starred_url":"https://api.github.com/users/hail-is/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hail-is/subscriptions","organizations_url":"https://api.github.com/users/hail-is/orgs","repos_url":"https://api.github.com/users/hail-is/repos","events_url":"https://api.github.com/users/hail-is/events{/privacy}","received_events_url":"https://api.github.com/users/hail-is/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hail-is/hail","description":"Scalable genetic data analysis","fork":false,"url":"https://api.github.com/repos/hail-is/hail","forks_url":"https://api.github.com/repos/hail-is/hail/forks","keys_url":"https://api.github.com/repos/hail-is/hail/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hail-is/hail/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hail-is/hail/teams","hooks_url":"https://api.github.com/repos/hail-is/hail/hooks","issue_events_url":"https://api.github.com/repos/hail-is/hail/issues/events{/number}","events_url":"https://api.github.com/repos/hail-is/hail/events","assignees_url":"https://api.github.com/repos/hail-is/hail/assignees{/user}","branches_url":"https://api.github.com/repos/hail-is/hail/branches{/branch}","tags_url":"https://api.github.com/repos/hail-is/hail/tags","blobs_url":"https://api.github.com/repos/hail-is/hail/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hail-is/hail/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hail-is/hail/git/refs{/sha}","trees_url":"https://api.github.com/repos/hail-is/hail/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hail-is/hail/statuses/{sha}","languages_url":"https://api.github.com/repos/hail-is/hail/languages","stargazers_url":"https://api.github.com/repos/hail-is/hail/stargazers","contributors_url":"https://api.github.com/repos/hail-is/hail/contributors","subscribers_url":"https://api.github.com/repos/hail-is/hail/subscribers","subscription_url":"https://api.github.com/repos/hail-is/hail/subscription","commits_url":"https://api.github.com/repos/hail-is/hail/commits{/sha}","git_commits_url":"https://api.github.com/repos/hail-is/hail/git/commits{/sha}","comments_url":"https://api.github.com/repos/hail-is/hail/comments{/number}","issue_comment_url":"https://api.github.com/repos/hail-is/hail/issues/comments{/number}","contents_url":"https://api.github.com/repos/hail-is/hail/contents/{+path}","compare_url":"https://api.github.com/repos/hail-is/hail/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hail-is/hail/merges","archive_url":"https://api.github.com/repos/hail-is/hail/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hail-is/hail/downloads","issues_url":"https://api.github.com/repos/hail-is/hail/issues{/number}","pulls_url":"https://api.github.com/repos/hail-is/hail/pulls{/number}","milestones_url":"https://api.github.com/repos/hail-is/hail/milestones{/number}","notifications_url":"https://api.github.com/repos/hail-is/hail/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hail-is/hail/labels{/name}","releases_url":"https://api.github.com/repos/hail-is/hail/releases{/id}","deployments_url":"https://api.github.com/repos/hail-is/hail/deployments","created_at":"2015-10-27T20:55:42Z","updated_at":"2016-12-20T20:21:36Z","pushed_at":"2016-12-23T17:33:27Z","git_url":"git://github.com/hail-is/hail.git","ssh_url":"git@github.com:hail-is/hail.git","clone_url":"https://github.com/hail-is/hail.git","svn_url":"https://github.com/hail-is/hail","homepage":"https://hail.is","size":8210,"stargazers_count":88,"watchers_count":88,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":26,"mirror_url":null,"open_issues_count":295,"forks":26,"open_issues":295,"watchers":88,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hail-is/hail/pulls/1216"},"html":{"href":"https://github.com/hail-is/hail/pull/1216"},"issue":{"href":"https://api.github.com/repos/hail-is/hail/issues/1216"},"comments":{"href":"https://api.github.com/repos/hail-is/hail/issues/1216/comments"},"review_comments":{"href":"https://api.github.com/repos/hail-is/hail/pulls/1216/comments"},"review_comment":{"href":"https://api.github.com/repos/hail-is/hail/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hail-is/hail/pulls/1216/commits"},"statuses":{"href":"https://api.github.com/repos/hail-is/hail/statuses/83d7f7064ea785a1060b80d1fc4fbd594959e626"}}}}
{"actor":{"display_login":"jigold"}}