Note that there are some explanatory texts on larger screens.

plurals
  1. POPerl: How to pass information to a function in module?
    primarykey
    data
    text
    <p>Completely new to Perl here. Anyway, I was given a certain task and I found a perl module online that does <em>exactly</em> what I want. </p> <p><a href="http://jaspar.genereg.net/html/DOWNLOAD/jaspar_CORE/non_redundant/by_tax_group/vertebrates/matrix_only/matrix_only.txt" rel="nofollow">Matrix</a></p> <p><a href="http://tfbs.genereg.net/DOC/" rel="nofollow">Documentation</a></p> <p>This is the documentation for the perl module -- under Ext there is one called pwmsearch, which does exactly what I need.</p> <p>So I tried to write a script that starts out something like this:</p> <pre><code>#!/usr/bin/env perl -w use strict; use TFBS::Ext::pwmsearch; #this was how the documentation said in synopsis part for pwmsearch so I figured this was how to do it </code></pre> <p>The problem is that I cannot figure out how I am supposed to pass objects to pwmsearch. The source code of pwmsearch as shown in the documentation above says it takes in $matrixobj and $seqobj, which I have stored as files matrix and sequence. </p> <p>So after googling around on what I could try, I tried doing things like:</p> <pre><code>pwmsearch('matrix','sequence'); </code></pre> <p>or</p> <pre><code>open FILE, 'matrix.txt' or die "Couldn't open file"; $matrix.=&lt;FILE&gt; close FILE; open FILE, 'sequence' or die "Couldn't open file"; $seq.=&lt;FILE&gt; close FILE; pwmsearch($matrix,$seq) </code></pre> <p>But all of them makes perl bark at me with various errors. What am I doing wrong and what could I do to fix them?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload