Coder Social home page Coder Social logo

parentage's Introduction

Overview

  Usage:  parentage.pl -parents FILE [-options]

  Given a file of individuals and parents, recursively determine the pedigree
  (the parentage going back as many generations as possible) for an individual.
  Can be calculated for a single indicated individual or for all in the parents file.

  The parents file should be structured like this.
  The individual (progeny) is on the left, and the parent(s) are on the right
    indID  parent1  parent2
    A      B        C
    D      B        C
    E      B        F
    G      H        -    # an individual with only one parent
    I      -        H    # another individual with only one parent

  Required:
    -parents  File listing the individuals and parents

  Options:
    -query    ID of an individual for which to calculate parentage.
              If not provided, report parentage for all individuals.
    -format   Output format. Options: string, table. Either or both (string,table) can be specified. [table]
    -noself   Remove the query ID from the parentage string.
    -verbose  Report some intermediate information.
    -help     This message.

Example: Calculate pedigree strings for all genotypes in the input parent file

Report the output as a table of genotype-parent-parent triples and a tree-like pedigree string

  ./parentage.pl -parents parents_clean1.tsv -format table,string | head -7
    
    Hale_Ogden_#12	Ogden	-
    Ogden	Tokyo	PI_54610
    Tokyo	PI_8424	-
    Hale_Ogden_#12: ( Hale_Ogden_#12 ( Ogden ( Tokyo ( PI_8424 , - ) , PI_54610 ) , - ) )
    
    70653G003	Pioneer_P9594	Syngenta_S59-60
    70653G003: ( 70653G003 ( Pioneer_P9594 , Syngenta_S59-60 ) )
    ...

Example: Report input data and pedigree string for an indicated genotype

Report the output as a table of genotype-parent-parent triples, with header line. This can be written to a file and used as input to the Helium pedigree viewer

  ./parentage.pl -parents parents_clean1.tsv -q YB57H

    Genotype	Female Parent	Male Parent
    YB57H	8377-16	W8238-02
    8377-16	Pioneer_P9582	W2707-23
    W2707-23	Y2011Z2	Epps
    Y2011Z2	1190-02	J74-45
    1190-02	Mack	Forrest
    W8238-02	Pioneer_P9591	Y277402
    Y277402	1100-07	1190-19
    1100-07	Forrest	Tracy
    1190-19	Mack	Forrest

Here is the pedigree image generated by the Helium pedigree viewer from the input above (for -q YB57H):

soy_ped_YB57H

Here is the corresponding pedigree string, generated with ./parentage.pl -parents parents_clean1.tsv -q YB57H -format string:

YB57H: ( YB57H ( 8377-16 ( Pioneer_P9582 , W2707-23 ( Y2011Z2 ( 1190-02 ( Mack , Forrest ) , J74-45 ) , Epps ) ) , W8238-02 ( Pioneer_P9591 , Y277402 ( 1100-07 ( Forrest , Tracy ) , 1190-19 ( Mack , Forrest ) ) ) ) )

parentage's People

Contributors

stevencannon-usda avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.