URL links in gbrowse 2

View: New views
4 Messages — Rating Filter:   Alert me  

URL links in gbrowse 2

by Maureen J. Donlin :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I have a Gbrowse2 installation; Bioperl 1.6

Located at: http://hagrid.slu.edu/cgi-bin/gbrowse/drad2/

Edited the Genbank file so the "db_xref=GeneID:" are now "geneid="

Generated GFF3 and imported into mysql.  Now geneid is one of the
key:value pairs in the fattributes table.

Trying to create a link to the Gene database from the main Gbrowse page.

Why does this link for GENE feature not work when a similar link for
[ORIGIN] does?

[GENE]
feature      = gene
glyph        = arrow
fgcolor      = red
linewidth    = 2
height       = 6
description  = sub {
        my $feature = shift;
        return $feature->attributes('geneid');
        }
link =  http://www.ncbi.nlm.nih.gov/sites/entrez?db=gene&cmd=search&term=$feature
key          = Annotated Genes

All I see in the link is $feature rather than the ID number of the
Gene db record.

Here is the code for the [ORIGIN] track:
[ORIGIN]
feature      = region
glyph        = anchored_arrow
fgcolor      = orange
font2color   = red
linewidth    = 2
height       = 10
description  = 1
link          =
http://www.ncbi.nlm.nih.gov/htbin-post/Entrez/query?db=n&form=1&field=Sequence+ID&term=$name
key          = Definition line

Thanks in advance for any suggestions.

Regards,
Maureen



--
Maureen J. Donlin, Ph.D.

Research Associate Professor
Dept. of Biochemistry & Molecular Biology
Dept. of Molecular Microbiology & Immunology
Saint Louis University School of Medicine
507 Doisy Research Center
314-977-8858

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gmod-gbrowse mailing list
Gmod-gbrowse@...
https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse

Re: URL links in gbrowse 2

by Lincoln Stein-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Maureen,

I think it will work if you use "$name" instead of "$feature".

Lincoln

On Fri, Sep 4, 2009 at 2:50 PM, Maureen Donlin <donlinmj@...> wrote:
I have a Gbrowse2 installation; Bioperl 1.6

Located at: http://hagrid.slu.edu/cgi-bin/gbrowse/drad2/

Edited the Genbank file so the "db_xref=GeneID:" are now "geneid="

Generated GFF3 and imported into mysql.  Now geneid is one of the
key:value pairs in the fattributes table.

Trying to create a link to the Gene database from the main Gbrowse page.

Why does this link for GENE feature not work when a similar link for
[ORIGIN] does?

[GENE]
feature      = gene
glyph        = arrow
fgcolor      = red
linewidth    = 2
height       = 6
description  = sub {
       my $feature = shift;
       return $feature->attributes('geneid');
       }
link            =  http://www.ncbi.nlm.nih.gov/sites/entrez?db=gene&cmd=search&term=$feature
key          = Annotated Genes

All I see in the link is $feature rather than the ID number of the
Gene db record.

Here is the code for the [ORIGIN] track:
[ORIGIN]
feature      = region
glyph        = anchored_arrow
fgcolor      = orange
font2color   = red
linewidth    = 2
height       = 10
description  = 1
link          =
http://www.ncbi.nlm.nih.gov/htbin-post/Entrez/query?db=n&amp;form=1&amp;field=Sequence+ID&amp;term=$name
key          = Definition line

Thanks in advance for any suggestions.

Regards,
Maureen



--
Maureen J. Donlin, Ph.D.

Research Associate Professor
Dept. of Biochemistry & Molecular Biology
Dept. of Molecular Microbiology & Immunology
Saint Louis University School of Medicine
507 Doisy Research Center
314-977-8858

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gmod-gbrowse mailing list
Gmod-gbrowse@...
https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse



--
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@...>

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gmod-gbrowse mailing list
Gmod-gbrowse@...
https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse

Re: URL links in gbrowse 2

by Maureen J. Donlin :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Lincoln,

No, that didn't help.  Whether I use $name or $ f it still opens the
gbrowse_details page and there is not link to the Gene db on that
either.

If I remove the link  = AUTO line, then it no longer calls the
gbrowse_details script, but still no link to Genbank.

I'll have to revisit it next week.

Regards,
Maureen

On Fri, Sep 4, 2009 at 3:06 PM, Lincoln Stein<lincoln.stein@...> wrote:

> Hi Maureen,
>
> I think it will work if you use "$name" instead of "$feature".
>
> Lincoln
>
> On Fri, Sep 4, 2009 at 2:50 PM, Maureen Donlin <donlinmj@...> wrote:
>>
>> I have a Gbrowse2 installation; Bioperl 1.6
>>
>> Located at: http://hagrid.slu.edu/cgi-bin/gbrowse/drad2/
>>
>> Edited the Genbank file so the "db_xref=GeneID:" are now "geneid="
>>
>> Generated GFF3 and imported into mysql.  Now geneid is one of the
>> key:value pairs in the fattributes table.
>>
>> Trying to create a link to the Gene database from the main Gbrowse page.
>>
>> Why does this link for GENE feature not work when a similar link for
>> [ORIGIN] does?
>>
>> [GENE]
>> feature      = gene
>> glyph        = arrow
>> fgcolor      = red
>> linewidth    = 2
>> height       = 6
>> description  = sub {
>>        my $feature = shift;
>>        return $feature->attributes('geneid');
>>        }
>> link            =
>>  http://www.ncbi.nlm.nih.gov/sites/entrez?db=gene&cmd=search&term=$feature
>> key          = Annotated Genes
>>
>> All I see in the link is $feature rather than the ID number of the
>> Gene db record.
>>
>> Here is the code for the [ORIGIN] track:
>> [ORIGIN]
>> feature      = region
>> glyph        = anchored_arrow
>> fgcolor      = orange
>> font2color   = red
>> linewidth    = 2
>> height       = 10
>> description  = 1
>> link          =
>>
>> http://www.ncbi.nlm.nih.gov/htbin-post/Entrez/query?db=n&form=1&field=Sequence+ID&term=$name
>> key          = Definition line
>>
>> Thanks in advance for any suggestions.
>>
>> Regards,
>> Maureen
>>
>>
>>
>> --
>> Maureen J. Donlin, Ph.D.
>>
>> Research Associate Professor
>> Dept. of Biochemistry & Molecular Biology
>> Dept. of Molecular Microbiology & Immunology
>> Saint Louis University School of Medicine
>> 507 Doisy Research Center
>> 314-977-8858
>>
>>
>> ------------------------------------------------------------------------------
>> Let Crystal Reports handle the reporting - Free Crystal Reports 2008
>> 30-Day
>> trial. Simplify your report design, integration and deployment - and focus
>> on
>> what you do best, core application coding. Discover what's new with
>> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
>> _______________________________________________
>> Gmod-gbrowse mailing list
>> Gmod-gbrowse@...
>> https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse
>
>
>
> --
> 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@...>
>



--
Maureen J. Donlin, Ph.D.

Research Associate Professor
Dept. of Biochemistry & Molecular Biology
Dept. of Molecular Microbiology & Immunology
Saint Louis University School of Medicine
507 Doisy Research Center
314-977-8858

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gmod-gbrowse mailing list
Gmod-gbrowse@...
https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse

Re: URL links in gbrowse 2

by Scott Cain-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Maureen,

I haven't seen the GFF, nor do I actually know what you want to appear  
in the url, but I suspect that you want the value of what geneid is  
set to.  To do that, you need a callback, like this:

link   = sub {
        my $feature = shift;
        my ($geneid) = $feature->attributes('geneid');
        return "http://www.ncbi.nlm.nih.gov/sites/entrez?db=gene&cmd=search&term=$geneid 
";
   }

Scott

On Sep 4, 2009, at 4:25 PM, Maureen Donlin wrote:

> Lincoln,
>
> No, that didn't help.  Whether I use $name or $ f it still opens the
> gbrowse_details page and there is not link to the Gene db on that
> either.
>
> If I remove the link  = AUTO line, then it no longer calls the
> gbrowse_details script, but still no link to Genbank.
>
> I'll have to revisit it next week.
>
> Regards,
> Maureen
>
> On Fri, Sep 4, 2009 at 3:06 PM, Lincoln  
> Stein<lincoln.stein@...> wrote:
>> Hi Maureen,
>>
>> I think it will work if you use "$name" instead of "$feature".
>>
>> Lincoln
>>
>> On Fri, Sep 4, 2009 at 2:50 PM, Maureen Donlin <donlinmj@...>  
>> wrote:
>>>
>>> I have a Gbrowse2 installation; Bioperl 1.6
>>>
>>> Located at: http://hagrid.slu.edu/cgi-bin/gbrowse/drad2/
>>>
>>> Edited the Genbank file so the "db_xref=GeneID:" are now "geneid="
>>>
>>> Generated GFF3 and imported into mysql.  Now geneid is one of the
>>> key:value pairs in the fattributes table.
>>>
>>> Trying to create a link to the Gene database from the main Gbrowse  
>>> page.
>>>
>>> Why does this link for GENE feature not work when a similar link for
>>> [ORIGIN] does?
>>>
>>> [GENE]
>>> feature      = gene
>>> glyph        = arrow
>>> fgcolor      = red
>>> linewidth    = 2
>>> height       = 6
>>> description  = sub {
>>>        my $feature = shift;
>>>        return $feature->attributes('geneid');
>>>        }
>>> link            =
>>>  http://www.ncbi.nlm.nih.gov/sites/entrez?db=gene&cmd=search&term=$feature
>>> key          = Annotated Genes
>>>
>>> All I see in the link is $feature rather than the ID number of the
>>> Gene db record.
>>>
>>> Here is the code for the [ORIGIN] track:
>>> [ORIGIN]
>>> feature      = region
>>> glyph        = anchored_arrow
>>> fgcolor      = orange
>>> font2color   = red
>>> linewidth    = 2
>>> height       = 10
>>> description  = 1
>>> link          =
>>>
>>> http://www.ncbi.nlm.nih.gov/htbin-post/Entrez/query?db=n&form=1&field=Sequence+ID&term=$name
>>> key          = Definition line
>>>
>>> Thanks in advance for any suggestions.
>>>
>>> Regards,
>>> Maureen
>>>
>>>
>>>
>>> --
>>> Maureen J. Donlin, Ph.D.
>>>
>>> Research Associate Professor
>>> Dept. of Biochemistry & Molecular Biology
>>> Dept. of Molecular Microbiology & Immunology
>>> Saint Louis University School of Medicine
>>> 507 Doisy Research Center
>>> 314-977-8858
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Let Crystal Reports handle the reporting - Free Crystal Reports 2008
>>> 30-Day
>>> trial. Simplify your report design, integration and deployment -  
>>> and focus
>>> on
>>> what you do best, core application coding. Discover what's new with
>>> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
>>> _______________________________________________
>>> Gmod-gbrowse mailing list
>>> Gmod-gbrowse@...
>>> https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse
>>
>>
>>
>> --
>> 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@...>
>>
>
>
>
> --
> Maureen J. Donlin, Ph.D.
>
> Research Associate Professor
> Dept. of Biochemistry & Molecular Biology
> Dept. of Molecular Microbiology & Immunology
> Saint Louis University School of Medicine
> 507 Doisy Research Center
> 314-977-8858
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008  
> 30-Day
> trial. Simplify your report design, integration and deployment - and  
> focus on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> _______________________________________________
> Gmod-gbrowse mailing list
> Gmod-gbrowse@...
> https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse

-----------------------------------------------------------------------
Scott Cain, Ph. D. scott at scottcain dot net
GMOD Coordinator (http://gmod.org/) 216-392-3087
Ontario Institute for Cancer Research





------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gmod-gbrowse mailing list
Gmod-gbrowse@...
https://lists.sourceforge.net/lists/listinfo/gmod-gbrowse