ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/bioseg/trunk/README.bioseg
(Generate patch)
# Line 24 | Line 24
24   file:
25      gzip -d < bioseg-x.y.tar.gz | tar xf -
26  
27 + (Or check-out from subversion with:
28 +   svn checkout svn://bioinformatics.org/svnroot/bioseg/trunk bioseg
29 + in the contrib directory)
30 +
31   To install the type, change to the bioseg directory and run
32  
33      make
34      make install
35  
36   The user running "make install" may need root access; depending on the
37 < configuration of PostgreSQL.
37 > configuration of PostgreSQL.  If so this may work:
38 >
39 >    sudo make install
40  
41   This only installs the type implementation and documentation.  To make the
42   type available in any particular database, do
# Line 51 | Line 57
57   If you have a full installation of PostgreSQL, including the pg_config
58   program, bioseg can be unpacked anywhere and built like:
59  
60 <     make USE_PGXS=t
61 <     make install USE_PGXS=t
60 >    make USE_PGXS=t
61 >    make install USE_PGXS=t
62 >    (or: sudo make install USE_PGXS=t)
63  
64   and the type can then be installed in a particular database by any user with:
65  
# Line 62 | Line 69
69   SYNTAX
70   ======
71  
72 < The external representation of an interval is formed using one or two
72 > The user visible representation of an interval is formed using one or two
73   integers greater than 0 joined by the range operator ('..' or '...').
74   The first integer must be less than or equal to the second.
75  
76 < 11..22        An interval from 10 to 20 inclusive - length 11 (= 22-11+1)
76 >  11..22        An interval from 11 to 22 inclusive - length 12 (= 22-11+1)
77 >
78 >  1...2         The same as 1..2
79  
80 < 1...2         The same as 1..2
80 >  50            The same as 50..50
81  
82 < 50            The same as 50..50
82 > In a statement, bioseg values have the form:
83 >  '<start>..<end>'::bioseg
84 > or can be created with:
85 >  bioseg_create(start, end)
86 >
87 > For example:
88 >  CREATE TABLE test_bioseg (id integer, seg bioseg);
89 >  insert into test_bioseg values (1, '1000..2000'::bioseg);
90 > or, equivalently
91 >  insert into test_bioseg values (1, bioseg_create(1000, 2000));
92  
93  
94   USAGE
95   =====
96  
97 < Available operators include:
97 > See http://www.bioinformatics.org/bioseg/wiki/Main/BiosegUsage for usage
98 > examples.
99 >
100 > The following is a list of the available operators.  The [a, b] should be
101 > replaced in a statement with 'a..b'::bioseg or bioseg_create(a, b).
102  
103   [a, b] && [c, d]        Overlaps
104  
# Line 161 | Line 183
183      make install INTERBASE_COORDS=t
184  
185   This will compile and install the implementation for the "bioseg0" type.
186 < The "0" in the name being a mnemonic for "0-based".
186 > The "0" in the name is a mnemonic for "0-based".
187  
188 < Then restart PostgreSQL and run:
189 <    psql -d databasename < bioseg.sql
190 < as usual to install the type in the database.
188 > Then read "bioseg0.sql" into your database:
189 >    psql -d databasename < bioseg0.sql
190 > to install the type.
191 >
192 > The bioseg and bioseg0 types can be mixed in the same database.
193  
194   Note
195   ----
# Line 192 | Line 216
216  
217   Note from the author: Most of the code and all of the hard work needed to
218   implement BIOSEG was by Gene Selkov, Jr, author of the SEG type (contrib/seg
219 < in the PostgreSQL source).  All bugs are due to me.
219 > in the PostgreSQL source).  All bugs are due to me (kmr).
220 >
221 >
222 > THANKS
223 > ======
224 >
225 > Thanks to bioinformatics.org for hosting the project.
226  
227  
228   AUTHOR
229   ======
230  
231   Kim Rutherford <kmr@flymine.org>
232 +
233 + SEG code by Gene Selkov, Jr.
234 +

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines