[Gmod-help] RE: [Gmod-gbrowse] Create SNP density track

Lincoln Stein lincoln.stein at gmail.com
Mon Apr 26 13:51:29 EDT 2010


That's right.

Lincoln

On Mon, Apr 26, 2010 at 1:49 PM, Jayaraman, Pushkala <pjayaraman at mcw.edu>wrote:

>  So all that I have to do is generate histograms in GFF and use
> Bio::DB::GFF in the conf file for this track instead?
>
>
>
> Pushkala
>
>
>
> *From:* gmodhelp at googlemail.com [mailto:gmodhelp at googlemail.com] *On
> Behalf Of *Dave Clements, GMOD Help Desk
> *Sent:* Monday, April 26, 2010 12:32 PM
> *To:* Jayaraman, Pushkala
> *Cc:* Wes Barris; gmod-gbrowse at lists.sourceforge.net
> *Subject:* Re: [Gmod-gbrowse] Create SNP density track
>
>
>
> Hi Pushkala,
>
>
>
> I don't believe there is any difference between how this is handled in the
> two different versions of GBrowse.
>
>
>
> Dave C
>
> On Mon, Apr 19, 2010 at 11:30 PM, Jayaraman, Pushkala <pjayaraman at mcw.edu>
> wrote:
>
> Hello,
> This may be a repeat question:
>
> Is the command on gbrowse2 different or creating snp density track?
> In gbrowse1.7:
> ========================================================================
> ========================================
>
> Generating Feature Frequency histograms
>
> Note: this applies to GFF2 databases only and needs to be rewritten
> slightly for GFF3
> With a little bit of additional effort, you can set one or more tracks
> up to display a density histogram of the features contained within the
> track. For example, the human data source in the GBrowse demo uses
> density histograms in the chromosomal overview. In addition, when the
> features in the SNP track become too dense to view, this track converts
> into a histogram. To see this in action, turn on the SNP track and then
> zoom out beyond 150K - Link plz?
> There are four steps for making histograms:
> generate the density data using the bp_generate_histogram.pl script.
> load the density data using bp_load_gff.pl or bp_fast_load_gff.pl.
> declare a density aggregator to the gbrowse configuration file
> add the density aggregator to the appropriate track in the configuration
> file.
> The first step is to generate the density data. Currently this is done
> by generating a GFF file containing a set of "bin" feature types. Use
> the bp_generate_histogram.pl script to do this. You will find it in
> BioPerl under the scripts/Bio-DB-GFF directory.
> Assuming that your database is named "dicty", you have a feature named
> SNP, and you wish to generate a density distribution across 10,000 bp
> bins, here is the command you would use:
>  bp_generate_histogram.pl -merge -d dicty -bin 10000 SNP
> >snp_density.gff
> This is saying to use the "dicty" database (-d) option, to use 10,000 bp
> bins (the -bin option) and to count the occurrences of the SNP feature
> throughout the database. In addition, the -merge option says to merge
> all types of SNPs into a single bin. Otherwise they will be stratified
> by their source. The resulting GFF file contains a series of entries
> like these ones:
>  Chr1  SNP bin 1     10000 49 + . bin Chr1:SNP
>  Chr1  SNP bin 10001 20000 29 + . bin Chr1:SNP
> What this is saying is that there are now a series of pseudo-features of
> type "bin:SNP" that occupy successive 10,000 bp regions of the genome.
> The score field contains the number of times a SNP was seen in that bin.
> You'll now load this file using bp_load_gff.pl or bp_fast_load_gff.pl:
>  bp_load_gff.pl -d dicty snp_density.gff
> The next step is to tell GBrowse how to use this information. You do
> this by creating a new aggregator for the SNP density information. Open
> the GBrowse configuration file and find the aggregators option. Add a
> new aggregator that looks like this:
>  aggregators = snp_density{bin:SNP}
> This is declaring a new feature named "snp_density" that is composed of
> subparts of type bin:SNP.
> The last step is to declare a track for the density information. You
> will use the "xyplot" glyph, which can draw a number of graphs,
> including histograms. To add the SNP density information as a static
> track in the overview, create a section like this one:
> [SNP:overview]
> feature       = snp_density
> glyph         = xyplot
> graph_type    = boxes
> scale         = right
> bgcolor       = red
> fgcolor       = red
> height        = 20
> key           = SNP Density
> This is declaring a new constant track in the overview named "SNP
> Density." The feature is "snp_density", corresponding to the aggregator
> declared earlier. The glyph is "xyplot" using the graph type of "boxes"
> to generate a column graph.
> To set up a track so that the histogram appears when the user zooms out
> beyond 100,000 bp but shows the detailed information at higher
> magnifications, generate two track sections like these:
>  [SNPs]
>  feature       = snp
>  glyph         = triangle
>  point         = 1
>  orient        = N
>  height        = 6
>  bgcolor       = blue
>  fgcolor       = blue
>  key           = SNPs
>  [SNPs:100000]
>  feature       = snp_density
>  glyph         = xyplot
>  graph_type    = boxes
>  scale         = right
> The first track section sets up the defaults for the SNP track. SNPs are
> represented as blue triangles pointing North. The second track
> declaration declares that when the user zooms out to over 100K base
> pairs, GBrowse should display the snp_density feature using the xyplot
> glyph.
>
> ========================================================================
> =============================
>
> How different is this for gbrowse2?
>
>
> Pushkala
>
>
> ------------------------------------------------------------------------------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> Gmod-gbrowse mailing list
> Gmod-gbrowse at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse
>
>
>
>
> --
> ===> PLEASE KEEP RESPONSES ON THE LIST <===
> http://gmod.org/wiki/GMOD_Logo_Program
> http://gmod.org/wiki/GMOD_News
> Was this helpful? http://gmod.org/wiki/Help_Desk_Feedback
>



-- 
Lincoln D. Stein
Director, Informatics and Biocomputing Platform
Ontario Institute for Cancer Research
101 College St., Suite 800
Toronto, ON, Canada M5G0A3
416 673-8514
Assistant: Renata Musa <Renata.Musa at oicr.on.ca>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://brie4.cshl.edu/pipermail/gmod-help/attachments/20100426/1e2d650b/attachment.html>


More information about the Gmod-help mailing list