[Babase] Validating ALLMISCS.Txt

Karl O. Pinc kop at meme.com
Mon Jul 9 22:44:31 EDT 2007


On 07/09/2007 07:39:53 AM, Lacey Maryott wrote:
> I made notes below about each sample,
> 
> Karl O. Pinc wrote:
>> Hi,
>> 
>> Looks like there are some "OS" type ALLMISCS rows.  Are these valid?
>> 
>> 
>> (Lacey, note that the following SQL is, unlike what we did yesterday,
>> SQL standards compliant.)
>> 
>> babase=> select substring(allmiscs.txt from 1 for position(',' in  
>> allmiscs.txt) - 1) as col1, count(*), max(samples.date) from  
>> allmiscs, samples where samples.sid = allmiscs.sid group by col1;
>>  col1 | count |    max
>> ------+-------+------------
>>  OS   |     3 | 2006-01-23
>>  C    |   563 | 2006-12-15
>>  U    |   990 | 2005-11-10
>>  O    |   573 | 2006-06-13
>> (4 rows)
>> 
>> babase=> select * from samples, allmiscs where samples.sid =  
>> allmiscs.sid and substring(allmiscs.txt from 1 for position(',' in  
>> allmiscs.txt) - 1) = 'OS' order by samples.date;
>>   sid  |    date    | stime | observer | stype | grp  | sname | mins
>> | minsis | programid | setupid | palmtop | almid |  sid  |  atime    
>> |  txt
>> -------+------------+-------+----------+-------+------+-------+------+--------+-----------+---------+---------+-------+-------+----------+--------
>>  13254 | 2002-02-16 |       | JKW      | J     | 1.21 | OIL   |    5  
>> |      3 |         1 |       1 |       4 |  1084 | 13254 | 14:41:46  
>> | OS,,,,
>    OIL's sample for 02-02-16 P4 should be OS as in out of sight...  
> she had a few valid points within the sample too. it looks as though  
> the ADL was an error and should have been <PNT>
> <HDR>,0202161433OIL,PTSAMPLR_AUG01,SETUP_AUG01,4,16 Feb  
> 2002,OMO,JKW,OIL,JUV
> <PNT>,0202161433OIL,14:35:21,R2,OMO,OZO,XXX,
> <PNT>,0202161433OIL,14:36:22,R2,OZO,OMO,XXX,
> <PNT>,0202161433OIL,14:37:18,OS,,,,
> <PNT>,0202161433OIL,14:38:50,F3,OMO,DUI,XXX,UNK
> <PNT>,0202161433OIL,14:41:37,OS,,,,
> *<ADL>,0202161433OIL,14:41:46,OS,,,,*
>>  34732 | 2006-01-23 |       | RSM      | F     | 2.10 | LIW   |   10  
>> |      9 |         1 |       2 |       1 |  1981 | 34732 | 15:30:57  
>> | OS,
>> 34732 | 2006-01-23 |       | RSM      | F     | 2.10 | LIW   |   10  
>> |      9 |         1 |       2 |       1 |  1982 | 34732 | 15:31:20  
>> | OS,
>> (3 rows)
>> 
>> 
> the same seems to be the case with this LIW sample.
> 
> <HDR>,0601231530LIW,PTSAMPLR_JUL03,SETUP_JUL03,1,23 Jan  
> 2006,LIN,RSM,LIW,FEM
> <PNT>,0601231530LIW,15:30:49,OS,
> *<ADL>,0601231530LIW,15:30:57,OS,
> <ADL>,0601231530LIW,15:31:20,OS,*
> <PNT>,0601231530LIW,15:31:50,W1VS,WIP,WIP,XXX,
> <PNT>,0601231530LIW,15:32:42,W1VS,WIP,WIP,XXX,
> <PNT>,0601231530LIW,15:33:40,W1VS,WIP,WIP,XXX,
> <PNT>,0601231530LIW,15:34:41,W1VS,WIP,WIP,XXX,
> 
> what is the next step in fixing these?

You'd delete the ALLMISCS and put in a POINTS row with
the right Sid.  Or maybe just bump the SAMPLES.mins column.
That's probably it.  I can write more when I get back Fri.

Is 'OS' a legal in  ALLMISCS.Txt?

> 
> Lacey
>> Karl <kop at meme.com>
>> Free Software:  "You don't pay back, you pay forward."
>>                  -- Robert A. Heinlein
>> 
>> _______________________________________________
>> Babase mailing list
>> Babase at www.eco.princeton.edu
>> http://www.eco.princeton.edu/mailman/listinfo/babase
>> 
> 
>-- 
> Lacey Maryott
> Alberts Lab
> Department of Biology
> Duke University
> ph: 919-660-7306
> fax: 919-660-7293
> Lacey.Maryott at duke.edu
> _______________________________________________
> Babase mailing list
> Babase at www.eco.princeton.edu
> http://www.eco.princeton.edu/mailman/listinfo/babase
> 

Karl <kop at meme.com>
Free Software:  "You don't pay back, you pay forward."
                  -- Robert A. Heinlein



More information about the Babase mailing list