jalview Applet - parameter "PDBfile"

Hi,

I wanted to ask a question about the parameter "PDBfile" in jalview
Applet. From my point of view, it looks like there it is only possible
to set as value a pathname, that is a) in correlation to the source file
and b) has to be on the same level or in a subdirectory of the source.
Is there a way to set a pathname, which has not to be in correlation to
the source file? This would be very helpful for me, because I don't want
to put the pdb-files in the same directory or in a subdirectory as the
html file with the jalviewApplet inside.

Cause jMol can handle softlinks, I tried to use them as a workaround,
but it doesn't worked out. The same goes for file extension *.ent.gz.
But the applet could handle *.pdb.gz. Is there a reason?

I use the most recent version of jalview and jMol, working in Linux.

Thanks for helping :slight_smile: .

Cheers Rainer

Hi Rainer, sorry for the delay in replying, life is particularly busy at
the moment!

I wanted to ask a question about the parameter "PDBfile" in jalview
Applet. From my point of view, it looks like there it is only possible
to set as value a pathname, that is a) in correlation to the source file
and b) has to be on the same level or in a subdirectory of the source.
Is there a way to set a pathname, which has not to be in correlation to
the source file? This would be very helpful for me, because I don't want
to put the pdb-files in the same directory or in a subdirectory as the
html file with the jalviewApplet inside.

You are correct in assuming that the PDBfile parameters take paths as
arguments, but since the applet's environment is a web page, it actually
treats it as a URL - and applies the same transformations to it as for
all the other data source parameters. However, looking at the code, I
just realised it doesn't qute behave as it should - so I've opened a bug
about it (http://issues.jalview.org/browse/JAL-786). For the current
release, the workaround is to specify your PDB file paths as absolute URLs.

Cause jMol can handle softlinks, I tried to use them as a workaround,
but it doesn't worked out.

not quite sure what you mean here - do you mean 'ln -s' to make
softlinks between files on the directory path ? JalviewLite doesn't
know anything about the servers structure, only what can be resolved as
a URL (ie you should be able to point your browser at the URL and
retrieve the same data).

The same goes for file extension *.ent.gz.
But the applet could handle *.pdb.gz. Is there a reason?

JalviewLite doesn't actually care about the filename - to the best of my
knowledge, although it can cause problems if the PDB file doesn't
contain a properly formatted TITLE entry (ie one that contains a PDB
ID-like string). However, I'm also surprised that you managed to get any
gzipped file to be parsed by the applet, since it doesn't have any
special support for it, Do you have a public site where you can
demonstrate JalviewLite reading a pdb.gz file and failing to read a
.ent.gz file ?

Feel free to add a watch to the bug I mentioned above. I should fix it
today, and you'll be able to pick up the development build from the
usual address (see the Development page on www.jalview.org). Also, make
sure you have the 'debug' parameter set so you can see exactly what URLs
JalviewLite is trying to resolve.

Jim.

···

On 22/02/2011 09:45, Rainer Hausdorf wrote:

Hallo Jim,

thanks for reply and opening the Bugs (786 & 787).

Cause jMol can handle softlinks, I tried to use them as a workaround,
but it doesn't worked out.
    

not quite sure what you mean here - do you mean 'ln -s' to make
softlinks between files on the directory path ? JalviewLite doesn't
know anything about the servers structure, only what can be resolved as
a URL (ie you should be able to point your browser at the URL and
retrieve the same data).
  

My bad. I did not think of URLs. Now I understood how it is working.
But, if I place my PDBfile into the directory where the applet-jar is
placed, I do not have a connection in JalView/Jmol between the PDBfile
and the sequence it belongs to. But this would be essential.

<applet code="jalview.bin.JalviewLite" width="90" height="35"
archive="/<path>/Jalview/jalviewApplet.jar,
/<path>/Jalview/JmolApplet-12.1.13.jar">
        <param name="sequence1" value="seq_001 [---sequence---]">
        <param name="sequence2" value="1MP9B [---sequence of 1MP9B]">
        <param name="PDBfile"
value="file:///<path>/Jalview/pdb1mp9.ent.gz 1MP9B"> <!-- no
connection to sequence -->
        <param name="features" value=./pic/1MP9B_features.txt>
        <param name="annotations" value=./pic/1MP9B_secStruc.txt>
        <param name="showAnnotation" value="true">
        [...]
</applet>

The same goes for file extension *.ent.gz.
But the applet could handle *.pdb.gz. Is there a reason?
    

JalviewLite doesn't actually care about the filename - to the best of my
knowledge, although it can cause problems if the PDB file doesn't
contain a properly formatted TITLE entry (ie one that contains a PDB
ID-like string). However, I'm also surprised that you managed to get any
gzipped file to be parsed by the applet, since it doesn't have any
special support for it, Do you have a public site where you can
demonstrate JalviewLite reading a pdb.gz file and failing to read a
.ent.gz file ?
  
Sorry, I can not demonstrate this. As it turns out, for me the
jalView-Applet can also handle *.ent.gz if I place this file in the
directory, where the applet jar is located. (*.pdb.gz is also working).
Just to remember: When placing it in the directory containing the *.html
file, which launches jalview it only works for *.pdb.gz).

Cheers, Rainer