/ doc /
/doc/gombemi_system.xml
1 <?xml version='1.0' encoding="utf-8"?>
2 <!DOCTYPE book SYSTEM "/usr/share/xml/docbook/schema/dtd/5.0/docbook.dtd" [
3 <!-- Use symbols for repeating text. -->
4 <!ENTITY % entities SYSTEM "entities">
5 %entities;
6 <!ENTITY % constants SYSTEM "constants">
7 %constants;
8
9 <!-- The web site url stuff -->
10 <!ENTITY gombemi "gombemi.ccas.gwu.edu">
11 <!ENTITY gombemiwebsite
12 "&#x3C;link xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
13 version=&#x22;5.0&#x22;
14 xlink:href=&#x22;https://&gombemi;/&#x22;&#x3E;Gobemi-MI
15 Web site&#x3C;/link&#x3E;">
16 <!ENTITY securegombemiurl "https://&gombemi;">
17 <!ENTITY programsurl "&securegombemiurl;/programs">
18
19 <!-- References to 3rd party programs. -->
20 <!-- phpPgAdmin -->
21 <!ENTITY ppa
22 "&#x3C;link xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
23 version=&#x22;5.0&#x22;
24 xlink:href=&#x22;http://phppgadmin.sourceforge.net/&#x22;&#x3E;phpPgAdmin&#x3C;/link&#x3E;">
25 <!-- psql -->
26 <!ENTITY psql
27 "&#x3C;link xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
28 version=&#x22;5.0&#x22;
29 xlink:href=&#x22;http://www.postgresql.org/docs/&pgrelease;/static/app-psql.html&#x22;&#x3E;psql&#x3C;/link&#x3E;">
30
31 <!-- Other textual blurbs. -->
32 <!ENTITY time_zoned "This column is time zone aware; times are output in, and expected to be input in, your local time zone.">
33 <!ENTITY transaction "&#x3C;xref linkend=&#x22;transaction&#x22;
34 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
35 version=&#x22;5.0&#x22; /&#x3E;">
36 <!ENTITY autoid "This column is automatically maintained by the
37 database, cannot be changed, and must not be
38 &null;.">
39 <!ENTITY gcdbh "&#x3C;citetitle pubwork=&#x22;book&#x22;
40 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
41 version=&#x22;5.0&#x22;&#x3E;Gombe
42 Chimp Database Handbook&#x3C;/citetitle&#x3E;">
43 <!ENTITY ignored_column "The content of this column is ignored.">
44 <!ENTITY control_column "This column controls how other columns are
45 interpreted.">
46 <!ENTITY remove_spaces "Leading and trailing spaces in the data are
47 removed.">
48 <!ENTITY case_sensitive "The coded data is case sensitive.">
49 <!ENTITY remove_spaces_case "Leading and trailing spaces in the data are
50 removed and case is ignored.">
51 <!ENTITY comma_delim_elim_whitespace "These are delimited with
52 commas (&#x3C;literal
53 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
54 version=&#x22;5.0&#x22;&#x3E;&gmi_chimpid_delim;&#x3C;/literal&#x3E;)
55 and all whitespace is ignored.">
56 <!ENTITY semi_boolean "The legal values are: &#x3C;literal
57 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
58 version=&#x22;5.0&#x22;&#x3E;&gmi_sb_y;&#x3C;/literal&#x3E;, meaning true; &null; meaning false; and &#x3C;literal
59 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
60 version=&#x22;5.0&#x22;&#x3E;&gmi_sb_qmark;&#x3C;/literal&#x3E;, meaning true but uncertain.">
61
62 <!ENTITY bt_driven "The column name is looked up in the &#x3C;xref
63 linkend=&#x22;BEHAVIOR_TRANS&#x22;
64 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
65 version=&#x22;5.0&#x22;/&#x3E; table to determine
66 the behavior code and control other aspects of the
67 event recorded in Gombe-MI.">
68
69 <!ENTITY dt_driven "The column name is looked up in the &#x3C;xref
70 linkend=&#x22;DISTANCE_TRANS&#x22;
71 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
72 version=&#x22;5.0&#x22;/&#x3E; table to determine
73 the behavior code recorded in Gombe-MI.">
74
75 <!ENTITY special_chimpids "&#x3C;link
76 linkend=&#x22;Reserved_AnimIDs&#x22;
77 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
78 version=&#x22;5.0&#x22;&#x3E;See above&#x3C;/link&#x3E;
79 for special ChimpID values recognized by this column.">
80 <!ENTITY chimpid-like "(or &#x3C;link
81 linkend=&#x22;Reserved_AnimIDs&#x22;
82 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
83 version=&#x22;5.0&#x22;&#x3E;other
84 code&#x3C;/link&#x3E;)">
85 <!ENTITY play_role_determination "&#x3C;link
86 linkend=&#x22;Play_Role_Determination&#x22;
87 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
88 version=&#x22;5.0&#x22;&#x3E;See above&#x3C;/link&#x3E;
89 for information on how the
90 determination is made as to whether play is mutual
91 or directed.">
92 <!ENTITY csv_description "&#x3C;para
93 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
94 version=&#x22;5.0&#x22;&#x3E;There is no
95 standard for the CSV format, it is defined by
96 the operation of the programs which read and
97 write the format. At the time of this writing
98 the program attempts to read CSV formatted data
99 as produced by Excel, which is probably
100 described more or less as follows: the column
101 delimiter must be a comma, the character used to
102 quote textual data, if any quote character is
103 used, must be the double quote character, and
104 escaping must be done by doubling the double
105 quotes. At the time of this writing this format
106 can be obtained from Excel by exporting in CSV
107 format with a comma delimiter.&#x3C;/para&#x3E;
108
109 &#x3C;para
110 xmlns=&#x22;http://docbook.org/ns/docbook&#x22;
111 version=&#x22;5.0&#x22;&#x3E;Attempting to
112 upload data which contains the ASCII 0 character
113 or spreadsheets with individual cells that
114 contain multiple lines of text is likely to fail
115 in unpredictable ways or in ways which are
116 difficult to detect.&#x3C;/para&#x3E;">
117 ]>
118 <!-- Shouldn't have to use a SYSTEM doctype -->
119 <!--
120 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook V5.0//EN"
121 "http://www.oasis-open.org/docbook/xml/5.0/docbook.dtd" [
122 < ! - - Use symbols for repeating text. - - >
123 <!ENTITY % entities SYSTEM "entities">
124 %entities;
125 <!ENTITY % constants SYSTEM "constants">
126 %constants;
127 ]>
128 -->
129 <book xml:id="Gombe-MI-Technical-Specifications"
130 xmlns="http://docbook.org/ns/docbook"
131 version="5.0">
132
133 <info>
134 <mediaobject>
135 <imageobject role="html">
136 <imagedata scalefit="1" width="5in"
137 fileref="/doc/images/pointy.png" format="PNG" />
138 </imageobject>
139 <imageobject role="dblatex">
140 <imagedata
141 fileref="images/pointy.png" format="PNG" />
142 </imageobject>
143 </mediaobject>
144
145 <title>Gombe Mother-Infant Database Technical Specifications</title>
146
147 <mediaobject>
148 <imageobject role="html">
149 <imagedata scalefit="1" width="4in"
150 fileref="/doc/images/ff_hexed-72.png" format="PNG" />
151 </imageobject>
152 <imageobject role="dblatex">
153 <imagedata
154 fileref="images/ff_hexed.png" format="PNG" />
155 </imageobject>
156 </mediaobject>
157
158 <mediaobject>
159 <imageobject role="html">
160 <imagedata scalefit="1" width="3in" align="center"
161 fileref="/doc/images/lion.png" format="PNG" />
162 </imageobject>
163 <imageobject role="dblatex">
164 <imagedata
165 fileref="images/lion.png" format="PNG" />
166 </imageobject>
167 </mediaobject>
168
169 <authorgroup>
170 <author>
171 <personname>Karl O. Pinc</personname>
172 <email>kop@meme.com</email>
173 <affiliation>
174 <orgname>
175 <link xlink:href="http://www.meme.com/">
176 The Meme Factory, Inc.</link>
177 </orgname>
178 </affiliation>
179 </author>
180 </authorgroup>
181
182 <legalnotice xml:id="copyright">
183 <title>Copyright Notices</title>
184 <para>Copyright (C) 2012-2015 The Meme Factory, Inc.,
185 Elizabeth V. Lonsdorf, PhD., Carson M. Murray, PhD.</para>
186
187 <blockquote>
188 <para>Except as otherwise noted permission is granted to copy,
189 distribute and/or modify this document under the terms of the
190 GNU Free Documentation License, Version 1.3 or any later
191 version published by the Free Software Foundation; with no
192 Invariant Sections, no Front-Cover Texts, and no Back-Cover
193 Texts. A copy of the license is included in <xref
194 linkend="fdl"/>.</para>
195
196 <para>All of the code contained in this document, including
197 but not limited to the code presented in examples and figures,
198 is, at your option, dual licensed; you can redistribute it
199 and/or modify it under the terms of the GNU General Public
200 License as published by the Free Software Foundation; either
201 version 3 of the License, or (at your option) any later
202 version. A copy of this license is include in <xref
203 linkend="gpl"/>.</para>
204 </blockquote>
205
206 <para>Copyright (C) 1996-2011 The PostgreSQL Global Development
207 Group</para>
208
209 <blockquote>
210
211 <para>The appendix titled <link
212 linkend="transaction">&transaction_appendix;</link> is
213 Copyright (C) 1996-2011 by the PostgreSQL Global Development
214 Group, distributed under the terms of the license of the
215 University of California below.</para>
216
217 <para>Permission to use, copy, modify, and distribute this
218 software and its documentation for any purpose, without fee,
219 and without a written agreement is hereby granted, provided
220 that the above copyright notice and this paragraph and the
221 following two paragraphs appear in all copies.</para>
222
223 <para>IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE
224 TO ANY PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR
225 CONSEQUENTIAL DAMAGES, INCLUDING LOST PROFITS, ARISING OUT OF
226 THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE
227 UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY
228 OF SUCH DAMAGE.</para>
229
230 <para>THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY
231 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
232 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
233 PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN "AS-IS"
234 BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATIONS TO
235 PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
236 MODIFICATIONS.</para>
237 </blockquote>
238
239 <para>Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software
240 Foundation, Inc.</para>
241
242 <blockquote>
243
244 <para><xref linkend="fdl"/> is Copyright (C) 2000, 2001, 2002,
245 2007, 2008 Free Software Foundation, Inc.</para>
246
247 </blockquote>
248
249 <para>Copyright (C) 2007 Free Software Foundation, Inc.</para>
250
251 <blockquote>
252
253 <para><xref linkend="gpl"/> is Copyright (C) 2007 Free
254 Software Foundation, Inc.</para>
255
256 </blockquote>
257
258 <para>All declarations of copyright within the files of this
259 project may, in place of an explicit listing of all years for
260 which copyright is claimed, instead list a range of years in the
261 manner XXXX-YYYY to designate that copyright is claimed from
262 year XXXX through year YYYY, inclusive of both endpoints.</para>
263
264 </legalnotice>
265 </info>
266
267 <dedication>
268 <title>Acknowledgments</title>
269
270 <variablelist>
271 <title>The Gombe-MI Development Group</title>
272
273 <varlistentry>
274 <term>
275 <author>
276 <personname>Karl O. Pinc</personname>
277 <email>kop@meme.com</email>
278 <affiliation>
279 <orgname>
280 <link xlink:href="http://www.meme.com/">
281 The Meme Factory, Inc.</link>
282 </orgname>
283 </affiliation>
284 </author>
285 </term>
286
287 <listitem>
288 <simpara>Book Author, System Design Lead, Implementation</simpara>
289 </listitem>
290 </varlistentry>
291
292 <varlistentry>
293 <term>
294 <author>
295 <personname>Carson M. Murray, PhD.</personname>
296 <email>cmmurray@gwu.edu</email>
297 <affiliation>
298 <orgname>
299 <link xlink:href="http://www.gwu.edu/">George
300 Washington University</link></orgname>
301 </affiliation>
302 <uri type="webpage">
303 <link xlink:href="http://departments.columbian.gwu.edu/anthropology/people/317">http://departments.columbian.gwu.edu/anthropology/people/317</link>
304 </uri>
305 </author>
306 </term>
307
308 <listitem>
309 <simpara>Project Co-Leader, System Design Core Member</simpara>
310 </listitem>
311 </varlistentry>
312
313 <varlistentry>
314 <term>
315 <author>
316 <personname>Elizabeth V. Lonsdorf, PhD.</personname>
317 <email>elizabeth.lonsdorf@fandm.edu</email>
318 <affiliation>
319 <orgname>
320 <link xlink:href="http://www.fandm.edu/">Franklin &amp;
321 Marshall College</link></orgname>
322 </affiliation>
323 <uri type="webpage">
324 <link
325 xlink:href="http://www.fandm.edu/elizabeth-lonsdorf">http://www.fandm.edu/elizabeth-lonsdorf</link>
326 </uri>
327 </author>
328 </term>
329
330 <listitem>
331 <simpara>Project Co-Leader, System Design Core Member</simpara>
332 </listitem>
333 </varlistentry>
334
335 <varlistentry>
336 <term>
337 <author>
338 <personname>Karen Anderson</personname>
339 </author>
340 </term>
341
342 <listitem>
343 <simpara>System Design Core Member, Copy Review, System
344 Testing Lead</simpara>
345 </listitem>
346 </varlistentry>
347
348 <varlistentry>
349 <term>
350 <author>
351 <personname>A. Catherine Markham, PhD.</personname>
352 <affiliation>
353 <orgname>
354 <link xlink:href="http://www.stonybrook.edu/">Stony
355 Brook University</link>
356 </orgname>
357 </affiliation>
358 <uri type="webpage">
359 <link
360 xlink:href="http://www.stonybrook.edu/commcms/anthropology/faculty/cmarkham.html">http://www.stonybrook.edu/commcms/anthropology/faculty/cmarkham.html</link>
361 </uri>
362 </author>
363 </term>
364
365 <listitem>
366 <simpara>System Design Participant</simpara>
367 </listitem>
368 </varlistentry>
369
370 <varlistentry>
371 <term>
372 <author>
373 <personname>Margaret A. Stanton, PhD.</personname>
374 <affiliation>
375 <orgname>
376 <link xlink:href="http://www.gwu.edu/">George Washington University</link>
377 </orgname>
378 </affiliation>
379 <uri type="webpage">
380 <link xlink:href="http://cashp.columbian.gwu.edu/margaret-stanton">http://cashp.columbian.gwu.edu/margaret-stanton</link>
381 </uri>
382 </author>
383 </term>
384
385 <listitem>
386 <simpara>System Design Participant, System Testing Core
387 Member</simpara>
388 </listitem>
389 </varlistentry>
390
391 <varlistentry>
392 <term>
393 <author>
394 <personname>Edward Wilkerson, Jr.</personname>
395 <affiliation>
396 <orgname>
397 <link
398 xlink:href="http://www.lpzoo.org/">Lincoln Park Zoo</link>
399 </orgname>
400 </affiliation>
401 <uri type="webpage">
402 <link xlink:href="http://www.lpzoo.org/conservation-science/resources/staff-bios/edward-wilkerson">http://www.lpzoo.org/conservation-science/resources/staff-bios/edward-wilkerson</link>
403 </uri>
404 </author>
405 </term>
406
407 <listitem>
408 <simpara>System Design Participant</simpara>
409 </listitem>
410 </varlistentry>
411 </variablelist>
412
413 <formalpara>
414 <title>Funding and Support</title>
415
416 <para>We gratefully acknowledge the support of <link
417 xlink:href="http://www.nih.gov/">The National Institutes of
418 Health</link> grant R00HD057992 for the development of this
419 system. We are also very grateful for the support given by <link
420 xlink:href="http://www.lsgfchicago.org/">The Leo S. Guthman
421 Foundation</link>, the <link
422 xlink:href="http://www.lpzoo.org/">Lincoln Park Zoo</link>, <link
423 xlink:href="http://www.fandm.edu/">Franklin &amp; Marshall
424 College</link>, and <link xlink:href="http://www.gwu.edu/">The George
425 Washington University</link>.</para>
426 </formalpara>
427
428 <formalpara>
429 <title>Other Thanks</title>
430
431 <para>We would like to thank the myriad Free and Open Source
432 communities, including those of <link
433 xlink:href="http://www.postgresql.org">PostgreSQL</link>, the
434 <link xlink:href="http://www.gnu.org">GNU Project</link>, the
435 <link xlink:href="http://www.debian.org">Debian Project</link>,
436 <link xlink:href="http://www.ubuntu.com">Ubuntu</link>, <link
437 xlink:href="http://phppgadmin.sourceforge.net">PhpPgAdmin</link>,
438 the <link
439 xlink:href="http://www.pylonsproject.org/">Pyramid</link> web
440 framework, <link xlink:href="http://tug.org/">TeX</link> and <link
441 xlink:href="http://www.latex-project.org/">LaTeX</link>, <link
442 xlink:href="http://dblatex.sourceforge.net/">dblatex</link>, <link
443 xlink:href="http://docbook.org/">DocBook</link>, <link
444 xlink:href="http://papio.biology.duke.edu">Babase</link>, and many
445 others unmentioned, for giving, gratis, billions of dollars<footnote>
446
447 <para>See: <link
448 xlink:href="http://www.linuxfoundation.org/sites/main/files/publications/estimatinglinux.html">Estimating
449 the Total Development Cost of a Linux Distribution</link>.</para>
450
451 </footnote> of
452 work to the world, without which the Gombe-MI software and this
453 book would not exist.</para>
454 </formalpara>
455
456 <para>Any opinions, findings, conclusions or recommendations
457 expressed in this material are those of the author(s) and do not
458 necessarily reflect the views of the National Institutes of Health,
459 The Leo S. Guthman Foundation, the Lincoln Park Zoo, Franklin &amp;
460 Marshall College, The George Washington University, or any other
461 organization which has supplied support for this work.</para>
462
463 </dedication>
464
465 <chapter xml:id="Gombe-MI-System-Architecture">
466 <title>Gombe-MI System Architecture</title>
467 <section xml:id="databases">
468 <title>Databases</title>
469
470 <para>Databases are collections of information, all of which
471 can be queried and otherwise manipulated alone or in aggregation
472 with all other database content.<footnote>
473
474 <para>As security restrictions permit, of course. </para>
475
476 </footnote> Gombe-MI contains three databases. </para>
477
478 <section xml:id="gombemi-database">
479 <title>The <literal>gombemi</literal> Database</title>
480
481 <para>The <literal>gombemi</literal> database contains
482 the <quote>real</quote> information. All research takes place
483 in this database. </para>
484 </section>
485
486 <section xml:id="gombemi-test-database">
487 <title>The <literal>gombemi_test</literal> Database</title>
488
489 <para>The <literal>gombemi_test</literal> database contains a
490 copy of the gombemi database. It is a place to try out
491 dangerous things that might break the gombemi
492 database. </para>
493 </section>
494
495 <section xml:id="gombemi-copy-database">
496 <title>The <literal>gombemi_copy</literal> Database</title>
497
498 <para>The <literal>gombemi_copy</literal> database contains a
499 few bits of made up information. It is a place to try out
500 random things and a place where the gombemi developers can
501 work on alterations and enhancements. </para>
502 </section>
503 </section>
504
505 <section xml:id="roles">
506 <title>Roles and Database Permissions</title>
507
508 <para>Each user is given a role for their own personal use
509 (commonly called a login or username) and a password they must
510 use to gain access to the database. It is good form to change
511 your password occasionally.<footnote>
512
513 <para>That way if you unwittingly revealed your password
514 last weekend, after that fourth bottle of wine you
515 just <emphasis>knew</emphasis> was a mistake, by the time
516 everybody sobers up the password will have been changed and
517 the amount of damage done is
518 limited. </para></footnote></para>
519
520 <para>The database can grant specific users (via each user's
521 personal role, aka login) various levels of access to specific
522 tables, although such access is not common as it is difficult to
523 administer and maintain such a fine grained degree of control.
524 For further information see the &postgresql; documentation
525 on <link xlink:href="http://www.postgresql.org/docs/&pgrelease;/static/user-manag.html">
526 Database Roles</link>. </para>
527
528 <para>Rather than maintain database access privileges on a
529 per-user basis it is more convenient to grant users additional
530 roles, roles shared by many users, and then grant these roles
531 different levels of database access. </para>
532
533 <para>Gombe-MI contains the following (shared) roles: </para>
534
535 <section xml:id="gombemi_readers" xreflabel="gombemi_readers">
536 <title>The gombemi_readers role</title>
537
538 <para>The members of this shared role have read access to
539 Gombe-MI data but cannot add, delete, or otherwise alter any
540 of the data. </para>
541 </section>
542
543 <section xml:id="gombemi_editors" xreflabel="gombemi_editors">
544 <title>The gombemi_editors role</title>
545
546 <para>The members of this shared role have unlimited rights to
547 the Gombe-MI data. They may add data, delete data, or alter
548 existing data. They may not, however, alter the structure of
549 the gombemi database or change the rules to which the data are
550 required to conform. Thus, they may not add or delete tables,
551 alter triggers, or write or replace stored procedures. </para>
552 </section>
553 </section>
554
555 <section xml:id="Administrative-Users" xreflabel="Administrative Users">
556 <title>Administrative (Superuser) Users</title>
557
558 <para>An administrative user has no restrictions; these users
559 can do things like re-assign ownership of all database tables,
560 all schemas, and all databases; assign to or remove roles from
561 all usernames; create and destroy usernames, including other
562 administrative users; and create and destroy all tables, all
563 schemas, and all databases.</para>
564
565 <para>In short, administrative users are all-powerful.</para>
566
567 <para>Needless to say, administrative usernames should be
568 meted out sparingly. They should also be used
569 sparingly.</para>
570
571 <tip>
572 <para>Every person who has an administrative username should
573 also have an ordinary username. The ordinary username
574 carries much less risk of inadvertent, subtle or
575 not-so-subtle, destruction. Login as an administrative user
576 only when absolutely necessary.</para>
577 </tip>
578 </section>
579
580 <section xml:id="schemas">
581 <title>Schemas</title>
582
583 <para>Schemas partition databases. Tables, procedures,
584 triggers, and so forth are all kept in schemas. Schemas are like
585 sub-databases within a database. The salient difference between
586 schemas and databases is that a single SQL statement can refer
587 to objects in the different schemas of the parent database, but
588 cannot refer to objects in other databases -- tables within a
589 database can be related, but tables in different databases
590 cannot. Gombe-MI uses schemas to partition each database into
591 areas where users have a greater or lesser degree of freedom to
592 make changes. For further information on schemas see the <link
593 xlink:href="http://www.postgresql.org/docs/&pgrelease;/static/ddl-schemas.html">schema</link>
594 documentation for &postgresql;.</para>
595
596 <para>Each database is divided into the same schemas. That is,
597 each schema described below exists within each of the databases
598 described here. </para>
599
600 <para>The system looks at the different schemas for objects,
601 for example table names appearing in SQL queries, in the order
602 in which the schemas are listed below. If the table does not
603 appear in the first schema it looks in the second, and so
604 forth. As soon as a table is found with the name given, that table
605 is used and the search stops. </para>
606
607 <para>To explicitly reference an object in a specific schema,
608 place the name of the schema in front of the object, separating
609 the two with a period (e.g. schemaname.tablename). </para>
610
611 <section xml:id="gombemi-schema">
612 <title>The gombemi schema</title>
613
614 <para>The gombemi schema holds the <quote>official</quote>
615 Gombe-MI tables. Everything in the gombemi schema is documented
616 and supported. </para>
617
618 <para>In this schema the gombemi_readers and gombemi_editors
619 have the access described above. </para>
620 </section>
621
622 <section xml:id="gombemi-views-schemas">
623 <title>The gombemi_<wordasword>something</wordasword>_views
624 schemas</title>
625
626 <para>Gombe-MI contains a number of schemas that exist to
627 simplify things for those interested only in particular portions
628 of Gombe-MI. These schemas contain nothing
629 but <link linkend="The-Gombe-MI-Views">views</link> that
630 reference other parts of Gombe-MI (both tables and views), the
631 parts that are especially relevant and useful to those
632 interested only in one of the broad categories of Gombe-MI data.
633 These schemas and their corresponding categories are:</para>
634
635 <para>
636 <segmentedlist>
637 <title>The categories of Gombe-MI data and their schemas</title>
638 <?dblatex list-presentation="table"?>
639
640 <segtitle>Schema</segtitle>
641 <segtitle>Category</segtitle>
642 <seglistitem>
643 <seg><code>gombemi_support_views</code></seg>
644 <seg>Support Table Related</seg>
645 </seglistitem>
646
647 <seglistitem>
648 <seg><code>gombemi_demography_views</code></seg>
649 <seg>&demography_section;</seg>
650 </seglistitem>
651
652 <seglistitem>
653 <seg><code>gombemi_follow_views</code></seg>
654 <seg>&follow_section;</seg>
655 </seglistitem>
656
657 <seglistitem>
658 <seg><code>gombemi_event_views</code></seg>
659 <seg>&event_section;</seg>
660 </seglistitem>
661
662 <seglistitem>
663 <seg><code>gombemi_distance_views</code></seg>
664 <seg>&distance_section;</seg>
665 </seglistitem>
666
667 <seglistitem>
668 <seg><code>gombemi_group_views</code></seg>
669 <seg>&group_section;</seg>
670 </seglistitem>
671
672 </segmentedlist>
673 </para>
674
675 <para>These schemas provide an overview of the major areas of
676 Gombe-MI. They should be especially useful to those starting
677 out with Gombe-MI or those interested only in particular
678 portions of Gombe-MI data.</para>
679
680 <para>The views in these schemas may only be queried. Any
681 updating of Gombe-MI data must be done in the
682 <code>gombemi</code> schema.</para>
683
684 <note>
685 <para>Some of Gombe-MI's tables and views appear in more than
686 one of these schemas, some in none.</para>
687 </note>
688
689 <warning>
690 <para>Do not create any views that reference the views in
691 these schemas. Reference the <code>gombemi</code> schema
692 instead. Any views created that reference anything in these
693 <quote>category schemas</quote> will be destroyed on
694 occasion as Gombe-MI is modified.</para>
695 </warning>
696 </section>
697
698 <!--
699
700 <section xml:id="gombemi_pending-schema" xreflabel="gombemi_pending">
701 <title>The gombemi_pending schema</title>
702
703 <para>The gombemi_pending schema holds tables pending planned
704 integration into Gombe-MI. The tables in this schema are
705 intended to be used with the <quote>official</quote> Gombe-MI
706 tables but, unlike the <quote>official</quote> Gombe-MI tables,
707 there is no automated validation process and the table
708 structure has not been thoroughly reviewed. The tables in
709 gombemi_pending are to be used but their content and structure
710 may change when officially incorporated into Gombe-MI.</para>
711
712 <para>Documentation on the content of the gombemi_pending
713 schema may be found on the <link
714 xlink:href="&gombemiwikiurl;/Gombe-MIPending">gombemi_pending
715 page</link> of the &gombemiwiki;.</para>
716
717 <para>The difference between this schema and the <link
718 linkend="sandbox-schema">sandbox</link> schema is in the
719 permissions granted.</para>
720
721 <section>
722 <title>gombemi_readers permissions in the gombemi_pending
723 schema</title>
724
725 <para>Members of the gombemi_readers shared role have the same
726 permissions they do in the gombemi schema, they have read
727 access to the data but cannot add, delete or modify it.
728 However, unlike in the gombemi schema, individual users may be
729 granted the right to add, delete, or change data on a
730 table-by-table basis.</para>
731 </section>
732
733 <section>
734 <title>gombemi_editors permissions in the gombemi_pending
735 schema</title>
736
737 <para>Members of the gombemi_editors shared role have the
738 permissions they normally have in the gombemi schema, they may
739 add, delete or modify all data in the schema's tables.</para>
740 </section>
741
742 </section>
743 -->
744
745 <section xml:id="sandbox-schema">
746 <title>The sandbox schema</title>
747
748 <para>The sandbox schema holds tables that are used
749 together with the <quote>official</quote> Gombe-MI tables but have
750 not yet made it into the Gombe-MI project. They will not be
751 documented in the Gombe-MI documentation. </para>
752
753 <para>The shared roles have the following permissions: </para>
754
755 <section xml:id="gombemi-readers-in-sandbox">
756 <title>gombemi_readers permissions in the sandbox schema</title>
757
758 <para>The gombemi_readers have all the permissions in the
759 sandbox schema that the gombemi_editors have in the
760 gombemi schema. They may add, delete, or modify any
761 information in the schema but may not alter the structure of
762 the schema by adding or removing tables, procedures,
763 triggers, or anything else. </para>
764 </section>
765
766 <section xml:id="gombemi-editors-in-sandbox">
767 <title>gombemi_editors permissions in the sandbox schema</title>
768
769 <para>The gombemi_editors have all the permissions of the
770 gombemi_readers, plus they may add or delete tables, stored
771 procedures, or any other sort of object necessary to control
772 the structure of the data. </para>
773
774 <para>Because of the schema search order the schema name
775 must be used to qualify anything created in the sandbox
776 schema. E.g.
777 <example>
778 <title>Creating table <code>foo</code> in the sandbox
779 schema</title>
780 <literallayout>
781 <code>CREATE TABLE sandbox.foo (somecolumn INTEGER);</code>
782 </literallayout>
783 </example>
784 </para>
785
786 <para>&postgresql;, the
787 database underlying Gombe-MI, is secure by default. This
788 means that any tables or other database objects cannot be
789 accessed by anyone but their creator without permission of
790 the creator. gombemi_editors who create tables in the
791 sandbox schema should use the <link
792 xlink:href="http://www.postgresql.org/docs/&pgrelease;/static/sql-grant.html
793 ">GRANT</link> statement to grant access to Gombe-MI's other
794 users.</para>
795
796 <para>This is done as follows: <example>
797 <title>Granting permission to table
798 <code>foo</code> in the sandbox schema</title>
799 <literallayout>
800 <code>GRANT ALL ON sandbox.foo TO ROLE gombemi_editors;
801 GRANT SELECT ON sandbox.foo TO ROLE gombemi_readers;</code>
802 </literallayout>
803 </example>
804 </para>
805
806 <para>There is one other issue. Only the creator of a table
807 can change its structure -- to add another column, change
808 the table name, etc. And only the creator can destroy
809 (<link
810 xlink:href="http://www.postgresql.org/docs/&pgrelease;/static/sql-droptable.html">DROP</link>)
811 the table.</para>
812
813 </section>
814 </section>
815
816 <section xml:id="devel-schema">
817 <title>The devel schema</title>
818
819 <para>The devel schema holds tables undergoing integration
820 into Gombe-MI. Normally it is empty, but during the design and
821 development of new tables it may contain the tables being
822 developed.</para>
823
824 <para>The tables in this schema do not necessarily contain
825 valid or finalized data and so are not expected to be used for
826 other than developmental purposes.</para>
827
828 <para>Permissions are granted in the devel schema on the same
829 basis as the granting of permissions in the gombemi
830 schema.</para>
831
832 <para>The difference between this schema and the <link
833 linkend="sandbox-schema">sandbox</link> schema is that the
834 development tools support the creation and modification of the
835 tables in the devel schema, which facilitates the movement of
836 tables from the devel schema into the <link
837 linkend="gombemi-schema">gombemi</link> schema.</para>
838 </section>
839
840 <section xml:id="user-schema">
841 <title>The per-user schemas</title>
842
843 <para>Each user has her own schema, a schema named with the
844 user's login. Users have permissions to do anything they want
845 in their own schemas, and no permissions whatsoever to anybody
846 else's schema. A user's schema is private. </para>
847
848 <caution>
849 <para>Users are <emphasis>not</emphasis> encouraged to grant
850 others permissions to the tables in their schema, as shown
851 in the <xref linkend="sandbox-schema" xrefstyle="select:
852 labelname quotedtitle"/> above. A user's schema is
853 deleted when she leaves Gombe-MI. All shared tables belong in
854 the <link linkend="sandbox-schema">sandbox</link> schema
855 where they can be maintained without regard to personnel
856 changes.</para>
857 </caution>
858
859 <para>Because of the schema search order the schema name must
860 be used to qualify anything created in the user's schema. E.g.
861 <example>
862 <title>Creating table <code>foo</code> in user
863 <code>mylogin</code>'s schema</title>
864 <literallayout>
865 <code>CREATE TABLE mylogin.foo (somecolumn INTEGER);</code>
866 </literallayout>
867 </example>
868 </para>
869
870 </section>
871 </section>
872
873 <section xml:id="Tables-A-Definition">
874 <title>Tables, A Definition</title>
875
876 <para>The data in Gombe-MI are stored in tables. Tables can be
877 visualized as grids, with rows and columns. Each row represents
878 a single real-world thing or event, an
879 <wordasword>entity</wordasword>, e.g. a chimpanzee. Each cell in
880 the row contains a single unit of information, e.g. a birth
881 date, a name, and a sex. The row holds the entirety of the
882 information belonging to the entity as an isolated thing,
883 e.g. chimpanzee database entities consist of a birth date, a name,
884 and a sex. Each column contains one and only one kind of
885 information, e.g. birth date. </para>
886
887 <para><xref linkend="A-Simple-Database-Table"/> is an example of
888 a database table that might be used to represent chimpanzees, one
889 chimpanzee per row. Notice that each cell contains one and exactly
890 one unit of information.</para>
891
892 <table xml:id="A-Simple-Database-Table" tocentry="0">
893 <title>A Simple Database Table</title>
894 <tgroup cols='3'>
895 <colspec colname="Birthdate"/>
896 <colspec colname="Name"/>
897 <colspec colname="Sex"/>
898 <thead>
899 <row>
900 <entry>Birth</entry>
901 <entry>Name</entry>
902 <entry>Sex</entry>
903 </row>
904 </thead>
905 <tbody>
906 <row>
907 <entry>May 23, 1707</entry>
908 <entry>Alice</entry>
909 <entry>Female</entry>
910 </row>
911 <row>
912 <entry>February 12, 1809</entry>
913 <entry>Bob</entry>
914 <entry>Male</entry>
915 </row>
916 <row>
917 <entry>July 22, 1822</entry>
918 <entry>Carol</entry>
919 <entry>Female</entry>
920 </row>
921 </tbody>
922 </tgroup>
923 </table>
924
925 <para>Anyone working with Gombe-MI will require a familiarity with
926 the database's tables. An understanding of the entity each row
927 represents is critical when working with a table. The remainder
928 of this section provides short definitions of the entities each
929 table holds in its rows.</para>
930
931 <para>Some of the tables in Gombe-MI exist to define a vocabulary.
932 These are the <wordasword>support tables</wordasword>. For lack
933 of a better term, the remainder of the tables are labeled
934 <quote>main tables</quote> in the <xref
935 linkend="Main-Table-Overview"/>.</para>
936 </section>
937
938 <section xml:id="Queries">
939 <title>Queries</title>
940
941 <para>Querying is done using a language called SQL. A description
942 of SQL is beyond the scope of this document but one, somewhat more
943 advanced, SQL feature is worth mention. Because the Gombe-MI
944 system stores all data of a like kind together, in one table, it
945 is often desirable to reference the same table (or table-like
946 structure) more than once in a single query. The
947 SQL <literal>AS</literal> syntax can be used to give a table an
948 alternate name used elsewhere within the query, allowing a single
949 table to be referenced multiple times within a single query. For
950 example, self-grooming data can be queried from the
951 <xref linkend="ASOCIAL_EVENTS"/> view. To count the number of
952 times both the mother and the infant simultaneously self groom the
953 following query uses <literal>AS</literal> so that
954 <xref linkend="ASOCIAL_EVENTS"/> can be used twice:</para>
955
956 <example xml:id="sql-as-example-code">
957 <title>Using <literal>AS</literal> in an SQL query: Reference
958 ASOCIAL_EVENTS twice to count the number of times a mother and
959 infant simultaneously self-groom</title>
960 <titleabbrev>Using <literal>AS</literal> in an SQL query:
961 Counting simultaneous self-grooming</titleabbrev>
962 <literallayout>
963 <code>SELECT COUNT(*)
964 FROM asocial_events AS mom_events
965 , asocial_events AS infant_events
966 WHERE mom_events.intid = infant_events.intid -- Same interval
967 AND mom_events.function = '&gmi_mom;' -- Mom is mom
968 AND mom_events.behavior = 'G'
969 AND infant_events.function = '&gmi_infant;' -- Infant is infant
970 AND infant_events.behavior = 'G';</code></literallayout>
971 </example>
972
973 <para>The use of <literal>AS</literal> in queries, or other, more
974 cumbersome techniques such as the creation of temporary tables,
975 reduces the number of views which must be created and
976 maintained.</para>
977 </section>
978 </chapter>
979
980 <chapter xml:id="An-Overview-Of-The-Gombe-MI-Data">
981 <title>An Overview Of The Gombe-MI Data</title>
982
983 <para>The tables in Gombe-MI are divided into two sorts, those that
984 hold data of primary interest, the <wordasword>Main
985 Tables</wordasword>, and those who's primary purpose is to provide a
986 controlled vocabulary for use throughout the rest of the system,
987 the <wordasword>Support Tables</wordasword>. Support tables are
988 also often called lookup tables.</para>
989
990 <para>The relationships between the main tables are diagrammed in
991 entity relationship diagrams. These diagrams provide a concise
992 overview of the Gombe-MI system and are an essential aid to complete
993 understanding.</para>
994
995 <para>Because Gombe-MI is as data-driven as possible, wherever
996 possible the system relies on the use of user-supplied vocabulary
997 for it's semantics, an understanding of the codes defined by the
998 support tables is essential to the use of the system</para>
999
1000 <para xml:id="Views" xreflabel="views">In addition to the underlying
1001 data tables Gombe-MI also contains views, a database feature which
1002 allows a query to masquerade as a table. Views can present a simple
1003 interface to a complex data structure, one which is tailored to a
1004 particular purpose. This allows the underlying data structure to be
1005 as general-purpose as possible and so able to accommodate complex
1006 relationships and efficiently process arbitrary queries. At the same
1007 time the views allow straightforward access for the novice. Because
1008 view are often composed of a query into multiple underlying data
1009 tables each view has an entity relationship diagram which describes
1010 the relationships between the tables used to construct the
1011 view.</para>
1012
1013 <para>Gombe-MI also consists of a number
1014 of programs. Some of these are generic, available from third
1015 parties for use on any system, and some which have been developed
1016 specifically for the Gombe-MI project. The latter are kept to a
1017 minimum to reduce cost and leverage the use of pre-existing software
1018 whenever possible.</para>
1019
1020 <xi:include
1021 href="support_tables.xml"
1022 xmlns:xi="http://www.w3.org/2001/XInclude"/>
1023
1024 <xi:include
1025 href="main_tables.xml"
1026 xmlns:xi="http://www.w3.org/2001/XInclude"/>
1027
1028 <section xml:id="ER-Diagrams">
1029 <title>ER Diagrams</title>
1030
1031 <para>ER diagrams, Entity-Relationship diagrams, graphically show
1032 the relationships between a database's tables. ER diagrams
1033 contain a lot of information and so provide a useful high-level
1034 overview of the data contained within the database. They are
1035 particularly useful when writing queries, if there is already a
1036 general understanding of what the rows in each table
1037 represent.</para>
1038
1039 <section xml:id="ER-Diagrams-Explained">
1040 <title>ER Diagrams Explained</title>
1041
1042 <para>Most tables have have an id, or key, column that contains
1043 a number unique to that row within its table. The id can be
1044 used, in perpetuity, to refer to its related row and
1045 distinguish it from all the other rows of the table. Ids are
1046 arbitrary, although for convenience they are often sequentially
1047 generated integers.</para>
1048
1049 <para>A relationship is established between the rows of two
1050 tables when an id value from one table appears as data in the
1051 other. The <wordasword>relationship</wordasword> notion is made
1052 most clear by way of diagrams and examples. If the next
1053 paragraph is unclear, don't worry. Have a look at the Gombe-MI
1054 diagrams below by way of example and see if that does not clear
1055 things up. The relationship concept is at the heart of
1056 relational databases and, while the underlying idea is rather
1057 simple, it took many years to develop relational database
1058 concepts so don't expect a full understanding
1059 immediately.</para>
1060
1061 <para> When an id value of a row in one table appears as data in
1062 a second table, the data in the second table can be used to
1063 retrieve the identified row from the first table.<footnote>
1064
1065 <para>And the reverse is true. The id of a row in the first
1066 table can be used to find the row in the second table that
1067 holds it.</para></footnote>
1068
1069 When an id value of a row in the first table appears as data only once
1070 in the second table, the two tables are said to have a
1071 <wordasword>one-to-one</wordasword> relationship. One row in
1072 the first table relates to one (or possibly zero) row(s) in the
1073 second table. When a row's id value can appear in more than one
1074 row of a second table, the two tables are said to have a
1075 <wordasword>one-to-many</wordasword> relationship. One row of
1076 the first table can be related to many rows in the second table.
1077 One-to-many relationships are more common than one-to-one
1078 relationships. The relationship between the various Gombe-MI
1079 tables can be visualized in entity relationship diagrams, as
1080 shown here. In this diagram each table (entity) is a box, and
1081 each box contains a list of the table's columns. The lines
1082 between the boxes represent the relationships between the
1083 tables.</para>
1084
1085 <note>
1086 <para>If you have trouble viewing the diagrams in your browser,
1087 you may wish to view them in PDF format. The diagrams are
1088 available in <link xlink:href="/doc/pocket_reference.pdf">The
1089 Gombe-MI Pocket Reference</link> in PDF form.</para>
1090 </note>
1091 </section>
1092
1093 <xi:include
1094 href="diagrams.xml"
1095 xmlns:xi="http://www.w3.org/2001/XInclude"/>
1096
1097 </section>
1098
1099 <xi:include
1100 href="views.xml"
1101 xmlns:xi="http://www.w3.org/2001/XInclude"/>
1102
1103 <section xml:id="Indexes">
1104 <title>Indexes</title>
1105
1106 <para>Indexes are a feature of databases, a feature
1107 which <emphasis>greatly</emphasis> speeds data retrieval. In
1108 return there is a small cost in the time it takes to change table
1109 content, and cost in disk space used. Databases generally require
1110 indexes to perform efficiently. It is a good idea to index the
1111 tables each user has in their personal schema.</para>
1112
1113 <para>There is no documentation on the indexes used in Gombe-MI.
1114 In general, there is an index for each way the tables are commonly
1115 referenced. For example, if records are often looked up on the
1116 basis of date, there will be an index on the date. As a practical
1117 guide, there is an index on each of the columns at the endpoint of
1118 a <quote>relational line</quote> in the above entity-relationship
1119 diagrams, as well as an index on every date column. All indexes
1120 are b-tree indexes.</para>
1121
1122 </section>
1123 </chapter>
1124
1125 <chapter xml:id="Main-Tables">
1126 <title>Main Tables</title>
1127
1128 <note>
1129 <para>Unless otherwise mentioned, all time values in Gombe-MI are
1130 stored<footnote>
1131
1132 <simpara><phrase>in a database data type which ignores the time
1133 zone of the database user</phrase></simpara>
1134
1135 </footnote> in Nairobi local time.</para>
1136 </note>
1137
1138 <section xml:id="demography_main_tables">
1139 <title>&demography_section; Tables</title>
1140
1141 <section xml:id="ADOPTIONS" xreflabel="ADOPTIONS">
1142 <title>ADOPTIONS</title>
1143
1144 <para>ADOPTIONS contains one row for each adoption of a
1145 chimpanzee. For the purposes of the Gombe-MI project an adoption
1146 occurs the first time one chimpanzee acts as the mother in a
1147 follow to a chimpanzee that is not their offspring.</para>
1148
1149 <para>There is no restriction on the sex of the adopting parent,
1150 nor is there a limit on the number of times a chimpanzee can be
1151 adopted.</para>
1152
1153 <para>The adopting individual must be older than the adopted
1154 individual<footnote>
1155
1156 <para>An additional age requirement may be worthwhile;
1157 the adoptive parent could be a mere 1 day older than
1158 the adopted youth.</para>
1159
1160 </footnote>
1161 -- the <xref linkend="Adoptions-AParent"/>'s
1162 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Birthdate"/>
1163 must be before that of the adopted individual.</para>
1164
1165 <para>The date of adoption must be during the time period in which
1166 both the adopted individual and the adopting individual are alive --
1167 the ADOPTIONS.<xref linkend="Adoptions-ADate"/> value cannot be
1168 before the related
1169 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Birthdate"/>
1170 value of the ADOPTIONS.<xref linkend="Adoptions-ChimpID"/>;
1171 the
1172 ADOPTIONS.<xref linkend="Adoptions-ADate"/> value cannot be after
1173 the related
1174 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Departdate"/>
1175 value of the ADOPTIONS.<xref linkend="Adoptions-ChimpID"/>;
1176 the
1177 ADOPTIONS.<xref linkend="Adoptions-ADate"/> value cannot be after
1178 the related
1179 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Departdate"/>
1180 value of the ADOPTIONS.<xref linkend="Adoptions-AParent"/>.</para>
1181
1182 <para>The adoptive parent cannot be the biological mother of the
1183 adopted individual -- the individual's
1184 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-MomID"/>
1185 value cannot be one of the related
1186 <xref linkend="ADOPTIONS"/>.<xref linkend="Adoptions-AParent"/>
1187 values.</para>
1188
1189 <para>An individual cannot be adopted twice by the same adoptive
1190 parent.</para>
1191
1192 <!-- untested temporary adoptions allow mother/infant follow (followparts, biography_data),
1193 can't be temporarly adopted before birth or after leaving study,
1194 can't be after adopting parent's departdate,
1195 switching from adate to tmpdate or the reverse does not
1196 have mom/infant follow before the date,
1197 both may not be null, tmpdate < adate -->
1198
1199 <para>Either a permanent (<xref linkend="Adoptions-ADate"/>) or
1200 a temporary (<xref linkend="Adoptions-TmpDate"/>) adoption date
1201 must be present, both dates may not be &null;. When there is
1202 both a permanent adoption date
1203 (<xref linkend="Adoptions-ADate"/>) and a temporary adoption
1204 date (<xref linkend="Adoptions-TmpDate"/>) the temporary date
1205 must be before the permanent date.</para>
1206
1207 <caution>
1208 <para>Only permanently adopted individuals
1209 (<xref linkend="ADOPTIONS"/>.<xref linkend="Adoptions-ADate"/>
1210 is not &null;) generate warnings<footnote>
1211
1212 <para>Generated by the warning system.</para>
1213
1214 </footnote> when not with their adoptive parent in a group when
1215 young, and vice-versa. No such constraints are placed on
1216 group membership when the adoption is temporary. It is the
1217 responsibility of the data entry team to ensure that the
1218 presence of temporarily adopted individuals and their adoptive
1219 parent are recorded correctly in the appropriate group.</para>
1220
1221 <para>Temporary adoptions alter the warnings regarding
1222 mother/infant pairing within group composition. For complete
1223 information on the group membership warnings surrounding
1224 adopted individuals and their adoptive parent see the
1225 <xref linkend="GROUPMEMBERS"/> table.</para>
1226 </caution>
1227
1228 <!-- need rule: cannot have 2 permanent adoptions of
1229 - a single individual on a single date. -->
1230
1231 <section xml:id="Adoptions-AdoptID" xreflabel="AdoptID">
1232 <title>AdoptID (Adoption Identifier)</title>
1233
1234 <para>A unique integer identifying the adoption. &autoid;</para>
1235 </section>
1236
1237 <section xml:id="Adoptions-ChimpID" xreflabel="ChimpID">
1238 <title>ChimpID (Adopted Individual's Chimp Identifier)</title>
1239
1240 <para>The virtual or real identifier assigned to the adopted
1241 individual. The <xref linkend="ChimpIDs-ChimpID"/> code of
1242 the adopted individual. The ChimpID value cannot be changed.
1243 &notnull;</para>
1244 </section>
1245
1246 <section xml:id="Adoptions-AParent" xreflabel="AParent">
1247 <title>AParent (Adopting Parent)</title>
1248
1249 <para>The identifier assigned to the adoptive parent. The
1250 <xref linkend="Biography_Data-AnimID"/> code of the adopting
1251 individual. The AParent value cannot be changed.
1252 &notnull;</para>
1253 </section>
1254
1255 <section xml:id="Adoptions-ADate" xreflabel="ADate">
1256 <title>ADate (Date of Permanent Adoption)</title>
1257
1258 <para>The date of the adoption, when the adoption is
1259 permanent.</para>
1260 </section>
1261
1262 <section xml:id="Adoptions-TmpDate" xreflabel="TmpDate">
1263 <title>TmpDate (Date of Temporary Adoption)</title>
1264
1265 <para>The date of the adoption, when the adoption is
1266 temporary.</para>
1267 </section>
1268
1269 </section>
1270
1271 <section xml:id="BIOGRAPHY_DATA" xreflabel="BIOGRAPHY_DATA">
1272 <title>BIOGRAPHY_DATA (Copy of the Master Biography Access Table)</title>
1273
1274 <para>BIOGRAPHY_DATA contains one row for every chimpanzee. It is
1275 a copy of the master file kept in MS Access and described the
1276 &gcdbh;.</para>
1277
1278 <note>
1279 <para>It is recommended, and generally more convenient, to use
1280 the <xref linkend="BIOGRAPHY"/> view.
1281 <xref linkend="BIOGRAPHY"/> has all the columns of
1282 BIOGRAPHY_DATA and a few more.</para>
1283 </note>
1284
1285 <caution>
1286 <para>Two AnimID values have special meaning to Gombe-MI.
1287 The <literal>&gmi_stranger;</literal>
1288 <xref linkend="Biography_Data-AnimID"/> value is assigned to
1289 the unknown stranger. The <literal>&gmi_unk_animid;</literal>
1290 <xref linkend="Biography_Data-AnimID"/> value is assigned to
1291 the generic unknown individual. The significance of these codes
1292 is that they may have &null; values in all of their columns
1293 excepting <xref linkend="Biography_Data-AnimID"/> and
1294 <xref linkend="Biography_Data-AnimName"/>. This exception is
1295 not mentioned in the column descriptions below.</para>
1296 </caution>
1297
1298 <para>An individual's <xref linkend="Biography_Data-Birthdate"/>
1299 cannot be before the individual's
1300 <xref linkend="Biography_Data-BDMin"/>. An individual's
1301 <xref linkend="Biography_Data-BDMax"/> cannot be before the
1302 individual's <xref linkend="Biography_Data-Birthdate"/>. An
1303 individual's <xref linkend="Biography_Data-Entrydate"/> cannot be
1304 before the individual's
1305 <xref linkend="Biography_Data-Birthdate"/>. An individual's
1306 <xref linkend="Biography_Data-Departdate"/> cannot be before the
1307 individual's <xref linkend="Biography_Data-Entrydate"/>. An
1308 individual's <xref linkend="Biography_Data-Import_Datetime"/>
1309 cannot be before the individual's
1310 <xref linkend="Biography_Data-Departdate"/>.</para>
1311
1312 <para>Individuals cannot be observed, neither their
1313 <xref linkend="Biography_Data-AnimID"/> nor any of their related
1314 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>s can
1315 appear in the Gombe-MI system, after the individual's
1316 BIOGRAPHY.<xref linkend="Biography_Data-Departdate"/> when the
1317 individual's BIOGRAPHY.<xref linkend="Biography_Data-Departtype"/>
1318 indicates final departure from the study population.</para>
1319
1320 <para>The <xref linkend="Biography_Data-Dad_Prelim"/> and
1321 <xref linkend="Biography_Data-Dad_Published"/> columns must be
1322 &null; when <xref linkend="Biography_Data-DadID"/> is &null; and
1323 must not be &null; when <xref linkend="Biography_Data-DadID"/> is
1324 not &null;.</para>
1325
1326 <para>None of the following columns may be &null; unless all are
1327 &null;: <xref linkend="Biography_Data-BGCertainty"/>,
1328 <xref linkend="Biography_Data-FirstBorn"/>,
1329 <xref linkend="Biography_Data-Birthdate"/>,
1330 <xref linkend="Biography_Data-BDMin"/>,
1331 <xref linkend="Biography_Data-BDMax"/>,
1332 <xref linkend="Biography_Data-BDDist"/>,
1333 <xref linkend="Biography_Data-BirthGroup"/> ,
1334 <xref linkend="Biography_Data-Entrydate"/>,
1335 <xref linkend="Biography_Data-Entrytype"/>,
1336 <xref linkend="Biography_Data-Departdate"/>,
1337 <xref linkend="Biography_Data-DepartdateError"/>,
1338 <xref linkend="Biography_Data-Departtype"/>, and all of the
1339 following columns are null also:
1340 <xref linkend="Biography_Data-AnimID_Num"/>
1341 <xref linkend="Biography_Data-MomID"/>
1342 <xref linkend="Biography_Data-DadID"/>. This allows the creation
1343 of individuals about whom nothing is known excepting their
1344 parentage of offspring.</para>
1345
1346 <section xml:id="Biography_Data-AnimID" xreflabel="AnimID">
1347 <title>AnimID (Animal Id)</title>
1348
1349 <para>The unique identifier assigned to the individual. It is
1350 composed entirely of upper case letters and digits and is at
1351 most &gmi_animid_len; characters long.</para>
1352
1353 <para>The AnimID value cannot be changed. &emptytext;
1354 &notnull;</para>
1355
1356 <para>Some <xref linkend="Biography_Data-AnimID"/> values are
1357 reserved and cannot be used to identify individuals within the
1358 database. See the documentation
1359 on <link linkend="Reserved_AnimIDs">AnimID values with special
1360 meaning</link> to the <xref linkend="UPLOAD_BEHAVIORS"/>
1361 view.</para>
1362 </section>
1363
1364 <section xml:id="Biography_Data-AnimID_Num" xreflabel="AnimID_Num">
1365 <title>AnimID_Num (Animal Id Number)</title>
1366
1367 <para>The unique alphanumeric identifier assigned to the
1368 individual for the SIV study. This value may be up to
1369 &gmi_animid_num_len; characters long. &emptytext; This value
1370 may be &null; when no such identifier exists.</para>
1371 </section>
1372
1373 <section xml:id="Biography_Data-AnimName" xreflabel="AnimName">
1374 <title>AnimName (Animal Name)</title>
1375
1376 <para>The name of the individual. This name must be
1377 unique.</para>
1378
1379 <para>&emptytext; &notnull;</para>
1380 </section>
1381
1382 <section xml:id="Biography_Data-BirthGroup" xreflabel="BirthGroup">
1383 <title>BirthGroup (Birth Group)</title>
1384
1385 <para>Unvalidated code used to designate the community into
1386 which the individual was born. See the &gcdbh; for further
1387 information.</para>
1388
1389 <para>&emptytext; This column may be &null; when the birth
1390 community is unknown.</para>
1391 </section>
1392
1393 <section xml:id="Biography_Data-BGCertainty" xreflabel="BGCertainty">
1394 <title>BGCertainty (Birth Group Certainty)</title>
1395
1396 <para>Code used to indicate confidence in the recorded
1397 <xref linkend="Biography_Data-BirthGroup"/>.</para>
1398
1399 <variablelist>
1400 <title>BGCertainty Acceptable Values</title>
1401
1402 <varlistentry>
1403 <term><literal>&gmi_bgcertain;</literal></term>
1404
1405 <listitem><para>Certain</para></listitem>
1406 </varlistentry>
1407
1408 <varlistentry>
1409 <term><literal>&gmi_bguncertain;</literal></term>
1410
1411 <listitem><para>Uncertain</para></listitem>
1412 </varlistentry>
1413 </variablelist>
1414 </section>
1415
1416 <section xml:id="Biography_Data-Sex" xreflabel="Sex">
1417 <title>Sex (Sex)</title>
1418
1419 <para>Code indicating the sex of the individual.</para>
1420
1421 <variablelist>
1422 <title>Sex Acceptable Values</title>
1423
1424 <varlistentry>
1425 <term><literal>&gmi_male;</literal></term>
1426
1427 <listitem><para>Male</para></listitem>
1428 </varlistentry>
1429
1430 <varlistentry>
1431 <term><literal>&gmi_female;</literal></term>
1432
1433 <listitem><para>Female</para></listitem>
1434 </varlistentry>
1435
1436 <varlistentry>
1437 <term><literal>&gmi_unk_sex;</literal></term>
1438
1439 <listitem><para>Unknown</para></listitem>
1440 </varlistentry>
1441 </variablelist>
1442
1443 <para>&notnull;</para>
1444 </section>
1445
1446 <section xml:id="Biography_Data-MomID" xreflabel="MomID">
1447 <title>MomID (AnimID of Mother)</title>
1448
1449 <para>The <xref linkend="Biography_Data-AnimID"/> code of the
1450 individual's mother, when known. The mother must be
1451 female.<footnote>
1452
1453 <para xml:id="MomID_notes">There are a number of other
1454 checks which make sense, and are desirable; checking that
1455 the mother is old enough to have given birth, not yet dead,
1456 etc. However, we're leaving this to the upstream data
1457 maintainers.</para>
1458
1459 </footnote>This value may be &null; when the mother is not
1460 known.</para>
1461 </section>
1462
1463 <section xml:id="Biography_Data-DadID" xreflabel="DadID">
1464 <title>DadID (AnimID of Father)</title>
1465
1466 <para>The <xref linkend="Biography_Data-AnimID"/> code of the
1467 individual's father, when known. The father must be
1468 male.<footnote>
1469
1470 <para>See <link linkend="MomID_notes">the footnote</link>
1471 above regarding
1472 <xref linkend="Biography_Data-MomID"/>.</para>
1473
1474 </footnote>This value may be &null; when the father is not
1475 known.</para>
1476 </section>
1477
1478 <section xml:id="Biography_Data-Dad_Prelim" xreflabel="Dad_Prelim">
1479 <title>Dad_Prelim (Paternity is Preliminary)</title>
1480
1481 <para>A Boolean value indicating when paternity assignment, the
1482 <xref linkend="Biography_Data-DadID"/> column value, is
1483 preliminary. This value may be &null;, see above.</para>
1484 </section>
1485
1486 <section xml:id="Biography_Data-Dad_Published" xreflabel="Dad_Published">
1487 <title>Dad_Published (Paternity Publication Information)</title>
1488
1489 <para>Where and when paternity assignment has been published.
1490 This value may be &null;, see above.</para>
1491 </section>
1492
1493 <section xml:id="Biography_Data-FirstBorn" xreflabel="FirstBorn">
1494 <title>FirstBorn (Firstborn)</title>
1495
1496 <para>Whether or not the individual is the mother's
1497 firstborn.</para>
1498
1499 <variablelist>
1500 <title>FirstBorn Acceptable Values</title>
1501
1502 <varlistentry>
1503 <term><literal>&gmi_fb;</literal></term>
1504
1505 <listitem><para>Firstborn</para></listitem>
1506 </varlistentry>
1507
1508 <varlistentry>
1509 <term><literal>&gmi_not_fb;</literal></term>
1510
1511 <listitem><para>Not the firstborn</para></listitem>
1512 </varlistentry>
1513
1514 <varlistentry>
1515 <term><literal>&gmi_unk_fb;</literal></term>
1516
1517 <listitem><para>May or may not be the firstborn</para></listitem>
1518 </varlistentry>
1519 </variablelist>
1520 </section>
1521
1522 <section xml:id="Biography_Data-Birthdate" xreflabel="Birthdate">
1523 <title>Birthdate (Birthdate)</title>
1524
1525 <para>The individual's birth date.</para>
1526
1527 <para>When not known this is estimated.</para>
1528 </section>
1529
1530 <section xml:id="Biography_Data-BDMin" xreflabel="BDMin">
1531 <title>BDMin (Minimum Birth Date)</title>
1532
1533 <para>Minimum birth date. See the &gcdbh; for further
1534 information.</para>
1535 </section>
1536
1537 <section xml:id="Biography_Data-BDMax" xreflabel="BDMax">
1538 <title>BDMax (Maximum Birth Date)</title>
1539
1540 <para>Maximum birth date. See the &gcdbh; for further
1541 information.</para>
1542 </section>
1543
1544 <section xml:id="Biography_Data-BDDist" xreflabel="BDDist">
1545 <title>BDDist (Birth Date Distribution</title>
1546
1547 <para>Code indicating the birth date probability distribution.
1548 See the &gcdbh; for further information. The legal values for
1549 this column are defined by the <xref linkend="BDDISTS"/> support
1550 table.</para>
1551 </section>
1552
1553 <section xml:id="Biography_Data-Entrydate" xreflabel="Entrydate">
1554 <title>Entrydate (Entry Date)</title>
1555
1556 <para>Date of entry into the study.</para>
1557 </section>
1558
1559 <section xml:id="Biography_Data-Entrytype" xreflabel="Entrytype">
1560 <title>Entrytype (Entry Type)</title>
1561
1562 <para>Code indicating how the individual entered the study
1563 population. See the &gcdbh; for further information. The legal
1564 values for this column are defined by the
1565 <xref linkend="ENTRYTYPES"/> support table.</para>
1566 </section>
1567
1568 <section xml:id="Biography_Data-Departdate" xreflabel="Departdate">
1569 <title>Departdate (Depart Date)</title>
1570
1571 <para>Date last seen in the study population.</para>
1572 </section>
1573
1574 <section xml:id="Biography_Data-DepartdateError"
1575 xreflabel="DepartdateError">
1576 <title>DepartdateError (Departure Date Error Factor)</title>
1577
1578 <para>Time between <xref linkend="Biography_Data-Departdate"/>
1579 and when the individual was confirmed missing. Units are
1580 fractions of a year. Precision is 2 decimal places. This
1581 number must be non-negative. For further information see the
1582 &gcdbh;.</para>
1583 </section>
1584
1585 <section xml:id="Biography_Data-Departtype" xreflabel="Departtype">
1586 <title>Departtype (Depart Type)</title>
1587
1588 <para>Code indicating how the individual left the study
1589 population. See the &gcdbh; for further information. The legal
1590 values for this column are defined by the
1591 <xref linkend="DEPARTTYPES"/> support table.</para>
1592 </section>
1593
1594 <section xml:id="Biography_Data-Import_Datetime"
1595 xreflabel="Import_Datetime">
1596 <title>Import_Datetime (Date and Time of Data Import)</title>
1597
1598 <para>The date and time of the data import -- the time the row was
1599 created. This column defaults to the date and time of the start
1600 of the &transaction; which inserted the row. Hence when all the
1601 rows are inserted in a single &transaction; they will all have the
1602 same timestamp. Further, the column will automatically be set to
1603 the correct value upon upload when this column is omitted from the
1604 uploaded data.</para>
1605
1606 <para>This column is not part of the master Access
1607 database.</para>
1608
1609 <para>&time_zoned; &notnull;</para>
1610 </section>
1611 </section>
1612
1613 <section xml:id="CHIMPIDS" xreflabel="CHIMPIDS">
1614 <title>CHIMPIDS (Virtual and Real Chimp Identifiers)</title>
1615
1616 <para>CHIMPIDS contains one row for every chimpanzee, plus
1617 additional rows giving twins a <quote>virtual</quote> identifier.
1618 The <quote>virtual</quote> identifier is used when the
1619 individual's identity is unknown because the twins cannot be
1620 distinguished from each other. Use of the <quote>virtual</quote>
1621 identifiers indicates that either of the two twins may be the
1622 individual in question. This is true even though each twin
1623 should, in CHIMPIDS, have only a single virtual identifier (in
1624 addition to the regular <xref linkend="Biography_Data-AnimID"/>).
1625 In other words, the association between the <quote>virtual</quote>
1626 identifiers and the individual twins is arbitrary.</para>
1627
1628 <para>There must always be a row on CHIMPIDS for each row on
1629 <xref linkend="BIOGRAPHY_DATA"/>. This required row has a
1630 <xref linkend="ChimpIDs-ChimpID"/> value that duplicates the row's
1631 <xref linkend="ChimpIDs-AnimID"/> value. These requirements are
1632 enforced on &transaction; commit. The required row ensures that
1633 each chimpanzee has an identifier, one equal to the chimp's
1634 <xref linkend="Biography_Data-AnimID"/>, suitable for use
1635 throughout the Gombe-MI system.</para>
1636
1637 <para>The content of the CHIMPIDS table is automatically altered
1638 under the following circumstances: When a
1639 <xref linkend="BIOGRAPHY_DATA"/> row is inserted a row is inserted
1640 into CHIMPIDS which has a <xref linkend="ChimpIDs-AnimID"/> value
1641 and a <xref linkend="ChimpIDs-ChimpID"/> value of the inserted
1642 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>.
1643 When a <xref linkend="BIOGRAPHY_DATA"/> row is deleted the related
1644 rows are deleted from CHIMPIDS. These operations are performed at
1645 the time of &transaction; commit. This feature should eliminate
1646 any need for manual maintenance of the CHIMPIDS table, except in
1647 the case of twins.</para>
1648
1649 <tip>
1650 <para>Often the CHIMPIDS table can be ignored; when writing
1651 queries <xref linkend="ChimpIDs-ChimpID"/> values in
1652 database tables may be joined directly with
1653 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>.
1654 When this is done rows which contain the <quote>virtual</quote>
1655 twin identifiers will disappear from the query results. Whether
1656 this is desirable depends on the intended goal.</para>
1657
1658 <para>A second way to ignore the CHIMPIDS table is to use the
1659 <xref linkend="CHIMPS"/> view instead of joining to
1660 <xref linkend="BIOGRAPHY_DATA"/> or <xref linkend="BIOGRAPHY"/>.
1661 In this case, when counting, care must be taken to count
1662 distinct <xref linkend="Biography_Data-AnimID"/> values to avoid
1663 double-counting twins.</para>
1664 </tip>
1665
1666 <para>The <quote>virtual</quote> identifiers must be unique --
1667 each <xref linkend="ChimpIDs-ChimpID"/> value must be related to
1668 exactly one <xref linkend="ChimpIDs-AnimID"/> value. The twins
1669 alternate identifiers cannot be used as
1670 <xref linkend="Biography_Data-AnimID"/> values on
1671 <xref linkend="BIOGRAPHY_DATA"/> --
1672 <xref linkend="ChimpIDs-ChimpID"/> values that differ from their
1673 row's <xref linkend="ChimpIDs-AnimID"/> values cannot be
1674 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
1675 values.</para>
1676
1677 <note>
1678 <para>There is no rule requiring that twins (as defined within
1679 the <xref linkend="TWINS"/> table) have <quote>virtual
1680 ids</quote> defined on CHIMPIDS, nor is there a rule which
1681 requires that every <quote>virtual id</quote> be a twin, but
1682 violating these constraints may result in a system which behaves
1683 strangely.<footnote>
1684
1685 <para>Then again, it may not behave strangely. It is up to
1686 you to understand how the system works, the implications of
1687 your choices, and to determine how the system best meets
1688 your needs.</para>
1689
1690 </footnote></para>
1691 </note>
1692
1693 <caution>
1694 <para>There are no rules in the system which require that twins
1695 must be referenced either by their <quote>normal</quote>
1696 <xref linkend="ChimpIDs-AnimID"/> values or by
1697 their <quote>alias</quote> <xref linkend="ChimpIDs-ChimpID"/>,
1698 used when the twins cannot be distinguished,
1699 but <emphasis>not</emphasis> by a mixture of both. It is
1700 allowed to reference one twin by their <quote>normal</quote>
1701 <xref linkend="ChimpIDs-AnimID"/> and the other by the
1702 twin's <quote>alias</quote> <xref linkend="ChimpIDs-ChimpID"/>,
1703 although this is almost surely a bad idea. Data hygiene in this
1704 regard is left to the system's users.</para>
1705 </caution>
1706
1707 <section xml:id="ChimpIDs-ChimpID" xreflabel="ChimpID">
1708 <title>ChimpID (Chimp Real or Virtual Identifier)</title>
1709
1710 <para>A &gmi_animid_len; character identifier for
1711 the <quote>virtual</quote> individual. This value cannot be
1712 changed. &notnull;</para>
1713
1714 <para>Some <xref linkend="ChimpIDs-ChimpID"/> values are
1715 reserved and cannot be used to identify individuals within the
1716 database. See the documentation
1717 on <link linkend="Reserved_AnimIDs">AnimID values with special
1718 meaning</link> to the <xref linkend="UPLOAD_BEHAVIORS"/>
1719 view.</para>
1720 </section>
1721
1722 <section xml:id="ChimpIDs-AnimID" xreflabel="AnimID">
1723 <title>AnimID (Animal Identifier)</title>
1724
1725 <para>The <xref linkend="Biography_Data-AnimID"/> code of the
1726 individual. This value cannot be changed. &notnull;</para>
1727 </section>
1728 </section>
1729
1730 <section xml:id="COMMUNITY_MEMBERSHIP" xreflabel="COMMUNITY_MEMBERSHIP">
1731 <title>COMMUNITY_MEMBERSHIP (Copy of the Master
1732 Community_Membership Access Table)</title>
1733 <titleabbrev>COMMUNITY_MEMBERSHIP (Copy of the Master
1734 Community_Membership Table)</titleabbrev>
1735
1736 <para>COMMUNITY_MEMBERSHIP contains one row for every contiguous
1737 period of time each individual has spent in each community. It is a
1738 copy of the master file kept in Access. Since record keeping
1739 involving transition between communities is non-obvious users are
1740 encouraged to read the description found in the &gcdbh;.</para>
1741
1742 <para>The combination of
1743 <xref linkend="Community_Membership-AnimID"/> and
1744 <xref linkend="Community_Membership-Start_date"/> must be
1745 unique.</para>
1746
1747 <note>
1748 <para>The data in this table,
1749 <xref linkend="Community_Membership-AnimID"/> excepted, is
1750 entirely unvalidated.</para>
1751 </note>
1752
1753 <section xml:id="Community_Membership-AnimID" xreflabel="AnimID">
1754 <title>AnimID (Animal Identifier)</title>
1755
1756 <para>The unique identifier assigned to each individual. The
1757 <xref linkend="Biography_Data-AnimID"/> code of the individual
1758 who's community tenure the row represents. &notnull;</para>
1759 </section>
1760
1761 <section xml:id="Community_Membership-Start_date"
1762 xreflabel="Start_date">
1763 <title>Start_date (Start Date)</title>
1764
1765 <para>Date of entry into community (inclusive). &notnull;</para>
1766 </section>
1767
1768 <section xml:id="Community_Membership-End_date" xreflabel="End_date">
1769 <title>End_Date (End Date)</title>
1770
1771 <para>Date of exit from the community (inclusive).
1772 &notnull;</para>
1773 </section>
1774
1775 <section xml:id="Community_Membership-Community_Id"
1776 xreflabel="Community_Id">
1777 <title>Community_Id (Community Identifier)</title>
1778
1779 <para>Unvalidated code identifying the community or pair of
1780 communities of which the individual was a part.
1781 &notnull;</para>
1782 </section>
1783
1784 <section xml:id="Community_Membership-Start_source"
1785 xreflabel="Start_source">
1786 <title>Start_source (Source of Start Date)</title>
1787
1788 <para>Textual description of how the start date was determined.
1789 &notnull;</para>
1790 </section>
1791
1792 <section xml:id="Community_Membership-End_source"
1793 xreflabel="End_source">
1794 <title>End_source (Source of End Date)</title>
1795
1796 <para>Textual description of how the end date was determined.
1797 &notnull;</para>
1798 </section>
1799
1800 <section xml:id="Community_Membership-Import_Datetime"
1801 xreflabel="Import_Datetime">
1802 <title>Import_Datetime (Date and Time of Data Import)</title>
1803
1804 <para>The date and time of the data import -- the time the row was
1805 created. This column defaults to the date and time of the start
1806 of the &transaction; which inserted the row. Hence when all the
1807 rows are inserted in a single &transaction; they will all have the
1808 same timestamp. Further, the column will automatically be set to
1809 the correct value upon upload when this column is omitted from the
1810 uploaded data.</para>
1811
1812 <para>This column is not part of the master Access
1813 database.</para>
1814
1815 <para>&time_zoned; &notnull;</para>
1816 </section>
1817 </section>
1818
1819 <section xml:id="TWINS" xreflabel="TWINS">
1820 <title>TWINS</title>
1821
1822 <para>TWINS contains one row for every individual who is a twin.
1823 Twins are required to occur in pairs, so for every
1824 <xref linkend="Twins-AnimID"/>/<xref linkend="Twins-Twin"/> pair of
1825 values there must also be a row containing a corresponding reversed
1826 pair of values.<footnote>
1827
1828 <para>To be through, there should also be rules which say twins
1829 must have identical birthdays, mothers, etc. There are no such
1830 rules.</para>
1831
1832 </footnote>This rule is enforced on &transaction; commit.</para>
1833
1834 <tip>
1835 <para>Insert rows into the TWINS table in pairs, in a single
1836 &transaction;</para>
1837 </tip>
1838
1839 <section xml:id="Twins-TwinID" xreflabel="TwinID">
1840 <title>TwinID (Twin Identifier)</title>
1841
1842 <para>A unique integer identifying the twin. &autoid;</para>
1843 </section>
1844
1845 <section xml:id="Twins-AnimID" xreflabel="AnimID">
1846 <title>AnimID (Animal ID)</title>
1847
1848 <para>The identifier assigned to the individual who is a twin.
1849 The <xref linkend="Biography_Data-AnimID"/> code of the
1850 individual. This value must be unique, no other row in the
1851 table may share an AnimID value. This value cannot be changed.
1852 &notnull;</para>
1853 </section>
1854
1855 <section xml:id="Twins-Twin" xreflabel="Twin">
1856 <title>Twin</title>
1857
1858 <para>The identifier assigned to the twin sibling of the
1859 individual. The <xref linkend="Biography_Data-AnimID"/> code of
1860 the individual's twin. This value must be unique, no other row
1861 in the table may share a Twin value. This value cannot be
1862 changed. &notnull;</para>
1863 </section>
1864
1865 </section>
1866 </section>
1867
1868 <section xml:id="follow_main_tables">
1869 <title>&follow_section; Tables</title>
1870
1871 <section xml:id="FIELDFOLLOWS" xreflabel="FIELDFOLLOWS">
1872 <title>FIELDFOLLOWS</title>
1873
1874 <para>FIELDFOLLOWS contains one row for each package of
1875 Mother-Infant follow data put together by any one field researcher
1876 during the course of a day. There is one field follow for every
1877 researcher for every mother for each day for which the researcher
1878 collected data on the mother (and her infant). The mother (or
1879 infant) need not be under continuous observation for the
1880 interrupted observations to be part of a single field follow, in
1881 fact each row in FIELDFOLLOWS represents an entire day's worth of
1882 a researcher's observations of a mother (and infant). All the
1883 field follows, irrespective of the researcher in the field, which
1884 record data on any one mother (and her offspring) in any one day
1885 are combined for analysis into an <quote>analytic follow</quote>,
1886 usually referred to herein just as a <quote>follow</quote>, and
1887 are represented in the database as rows in the
1888 <xref linkend="FOLLOWS"/> table.</para>
1889
1890 <para>Each row in FIELDFOLLOWS must have at least one related row
1891 on <xref linkend="SHEETS"/>.</para>
1892
1893 <para>An observer cannot be in two places at the same time -- the
1894 combination of <xref linkend="Fieldfollows-Collector"/>,
1895 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/>, and
1896 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-Time"/> must
1897 be unique.</para>
1898
1899 <para>The date of the follow,
1900 the <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/>
1901 value, cannot be after the date of data entry, the
1902 <xref linkend="Fieldfollows-Entrydate"/> value. Likewise, the date of
1903 data entry, the <xref linkend="Fieldfollows-Entrydate"/> value, cannot
1904 be after the date the data is uploaded into the Gombe-MI system,
1905 the <xref linkend="Fieldfollows-UploadDate"/> value.</para>
1906
1907 <para>The date of data entry,
1908 <xref linkend="Fieldfollows-Entrydate"/>, may not be &null; when
1909 the <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/> is
1910 after &gmi_max_null_entrydate;.</para>
1911
1912 <para>The <xref linkend="Fieldfollows-GCStatus"/>column must be
1913 non-&null; when there is any group composition information
1914 recorded in the database which is related to the field follow,
1915 otherwise it must be &null;. This is tested for by checking for
1916 the existence of rows in the <xref linkend="RAW_GROUPS"/> table
1917 related by <xref linkend="Raw_Groups-SheetID"/> to the
1918 <xref linkend="SHEETS"/> table, related by
1919 <xref linkend="Sheets-FFID"/> to the FIELDFOLLOWS table. This
1920 check is performed upon &transaction; commit.</para>
1921
1922 <section xml:id="Fieldfollows-FFID" xreflabel="FFID">
1923 <title>FFID (Fieldfollow Identifier)</title>
1924
1925 <para>A unique integer identifying the field follow. &autoid;</para>
1926 </section>
1927
1928 <section xml:id="Fieldfollows-Collector" xreflabel="Collector">
1929 <title>Collector (Field Observer)</title>
1930
1931 <para>Code identifying the person who observed the follow and
1932 recorded it's information on the template sheets. The legal
1933 values for this column are defined by the
1934 <xref linkend="PEOPLE"/> support table.</para>
1935
1936 <para>&notnull;</para>
1937 </section>
1938
1939 <section xml:id="Fieldfollows-Entrydate" xreflabel="Entrydate">
1940 <title>Entrydate (Date of Data Entry)</title>
1941
1942 <para>The date on which the field follow's data entry was
1943 finished.</para>
1944
1945 <para>This column may sometimes be &null;, see above.</para>
1946 </section>
1947
1948 <section xml:id="Fieldfollows-Enterer" xreflabel="Enterer">
1949 <title>Enterer (Data Entry Person)</title>
1950
1951 <para>Code identifying the person who entered the field follow
1952 information recorded on the template sheets into Gombe-MI. The
1953 legal values for this column are defined by the
1954 <xref linkend="PEOPLE"/> support table.</para>
1955
1956 <para>&notnull;</para>
1957 </section>
1958
1959 <section xml:id="Fieldfollows-UploadDate" xreflabel="UploadDate">
1960 <title>UploadDate (Date of Data Upload)</title>
1961
1962 <para>The date on which the field follow's data was uploaded
1963 into the Gombe-MI system.</para>
1964
1965 <para>When values for this column are not supplied as part of
1966 the upload process, or a &null; is supplied as a data value, the
1967 UploadDate value defaults to the current date. &notnull;</para>
1968 </section>
1969
1970 <section xml:id="Fieldfollows-GCStatus" xreflabel="GCStatus">
1971 <title>GCStatus (Group Composition Status)</title>
1972
1973 <para>Code indicating the status of all of the the group
1974 composition surveys (if any) related to the field follow. This
1975 column may be &null; when there is no related group composition
1976 information.</para>
1977 </section>
1978
1979 </section>
1980
1981 <section xml:id="FOLLOWPARTS" xreflabel="FOLLOWPARTS">
1982 <title>FOLLOWPARTS (Follow Participants)</title>
1983
1984 <para>FOLLOWPARTS contains one row for every Mother-Infant follow
1985 for every individual in the family that is followed. There
1986 are at least 2 participants in every follow: there must be exactly
1987 one row for the mother and at least one row for an infant. These
1988 rules are enforced on &transaction; commit.</para>
1989
1990 <para>Each participant in a follow must be a
1991 member of the study population on the date of the follow. The
1992 <xref linkend="BIOGRAPHY_DATA"/>.<xref
1993 linkend="Biography_Data-Entrydate"/>
1994 cannot be after the follow's
1995 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/> value.
1996 The <xref linkend="BIOGRAPHY_DATA"/>.<xref
1997 linkend="Biography_Data-Departdate"/>
1998 cannot be before the follow's
1999 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/>.</para>
2000
2001 <para>The mother in a follow must be the mother of the infant
2002 (either biological or an adoptive mother) and, similarly the
2003 mother of, if any, the sibling -- the
2004 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-MomID"/>
2005 of the offspring, or one of the offspring's related
2006 <xref linkend="ADOPTIONS"/>.<xref linkend="Adoptions-AParent"/>
2007 values, must be the
2008 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
2009 of the mother, where the role of mother and infant or sibling is
2010 determined based on
2011 <xref linkend="FOLLOWROLES"/>.<xref linkend="Followroles-Function"/>
2012 value and the <xref linkend="Biography_Data-AnimID"/> value is
2013 determined using the <xref linkend="CHIMPIDS"/> table. When the
2014 mother is an an adoptive parent then the date of the follow cannot
2015 be before the adoption date -- the
2016 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/> value
2017 cannot be before the
2018 <xref linkend="ADOPTIONS"/>.<xref linkend="Adoptions-ADate"/>
2019 value. The sibling, if any, in a follow must be older than the
2020 infant. Two participants in a follow may have the same
2021 role<footnote>
2022
2023 <para>Technically, may have the same
2024 <xref linkend="FOLLOWROLES"/>.<xref linkend="Followroles-Function"/>
2025 value.</para>
2026
2027 </footnote> (e.g. twin) if and only if the two participants have
2028 the same birth date.<footnote>
2029
2030 <para>Or if any of the birth dates involved are &null;.</para>
2031
2032 </footnote></para>
2033
2034 <para>When twins are both participants in one follow the two twins
2035 must share a role in the follow -- must have identical
2036 <xref linkend="Followparts-Role"/> values.</para>
2037
2038 <para>The individual(s) in the follow with the role of infant or
2039 sibling must be less than &gmi_notmom_maxage; old on the date
2040 of the follow.</para>
2041
2042 <note>
2043 <para>There are no checks to ensure that the infant in the
2044 follow is the youngest living offspring, or that the sibling is
2045 the next youngest.</para>
2046 </note>
2047
2048 <para>An individual cannot participate twice in a single follow --
2049 there cannot be 2 FOLLOWPARTS rows with the same
2050 <xref linkend="Followparts-FollowID"/> and related
2051 <xref linkend="ChimpIDs-AnimID"/> values.</para>
2052
2053 <section xml:id="Followparts-FPID" xreflabel="FPID">
2054 <title>FPID (Followparts Identifier)</title>
2055
2056 <para>A unique integer identifying the participant in the
2057 follow. &autoid;</para>
2058 </section>
2059
2060 <section xml:id="Followparts-FollowID" xreflabel="FollowID">
2061 <title>FollowID (Follow Identifier)</title>
2062
2063 <para>The integer identifying the follow of the participant.
2064 The FollowID value cannot be changed, the row must be deleted
2065 and a new row inserted in it's place.</para>
2066
2067 <para>&notnull;</para>
2068 </section>
2069
2070 <section xml:id="Followparts-ChimpID" xreflabel="ChimpID">
2071 <title>ChimpID (Chimp Virtual Identifier)</title>
2072
2073 <para>The identifier assigned to the follow participant. The
2074 <xref linkend="ChimpIDs-ChimpID"/> code of the
2075 individual.</para>
2076
2077 <para>&notnull;</para>
2078 </section>
2079
2080 <section xml:id="Followparts-Role" xreflabel="Role">
2081 <title>Role</title>
2082
2083 <para>Code indicating the individual's role in the follow. The
2084 legal values for this column are defined by the
2085 <xref linkend="FOLLOWROLES"/> support table.</para>
2086
2087 <para>&notnull;</para>
2088 </section>
2089
2090 </section>
2091
2092 <section xml:id="FOLLOWS" xreflabel="FOLLOWS">
2093 <title>FOLLOWS</title>
2094
2095 <!--
2096 - A follow is same mom on the same day.
2097 Need not be contiguous, need not be same observer.
2098 -->
2099
2100 <para>FOLLOWS contains one row for every Mother-Infant follow.
2101 There is one follow for every mother for each day for which there
2102 is a record; a chimpanzee cannot be the focal in more than one
2103 follow on any given day. The mother (or infant) need not be under
2104 continuous observation for the interrupted observations to be part
2105 of a single follow, nor do all observations need to be made by the
2106 same person.</para>
2107
2108 <para>Each follow must have at least one time interval during
2109 which observation was made -- each FOLLOWS row must be at least
2110 one related row on <xref linkend="INTERVALS"/>.<footnote>
2111
2112 <para>Note however that nothing need be observed during a
2113 follow. Although the <xref linkend="INTERVALS"/> row must
2114 exist there is no requirement that an
2115 <xref linkend="INTERVALS"/> row have any related data, so the
2116 system does not require any behavioral or inter-focal distance
2117 data.</para>
2118
2119 </footnote> This check is performed upon &transaction; commit.</para>
2120
2121 <note>
2122 <para>Deleting a row from the FOLLOWS table will delete the
2123 entire follow -- the system will first delete all related
2124 <xref linkend="INTERVALS"/> and <xref linkend="FOLLOWPARTS"/>
2125 rows, which will in turn delete dependent rows from other
2126 tables.</para>
2127 </note>
2128
2129 <section xml:id="Follows-FollowID" xreflabel="FollowID">
2130 <title>FollowID (Follow Identifier)</title>
2131
2132 <para>A unique integer identifying the follow. &autoid;</para>
2133 </section>
2134
2135 <section xml:id="Follows-Date" xreflabel="Date">
2136 <title>Date</title>
2137
2138 <para>The date of the follow. This date cannot be
2139 before <literal>&gmi_first_date;</literal>.</para>
2140
2141 <para>&notnull;</para>
2142 </section>
2143
2144 </section>
2145
2146 <section xml:id="INTERVALS" xreflabel="INTERVALS">
2147 <title>INTERVALS (Follow Observation Time Intervals)</title>
2148
2149 <para>INTERVALS contains one row for each interval of time during
2150 which observations were recorded as part of a follow.</para>
2151
2152 <note>
2153 <para>At the time of this writing all follow observation
2154 intervals are of 1 minute duration. The Gombe-MI system
2155 contains elements which rely on per-minute
2156 granularity.<footnote>
2157
2158 <para>See <xref linkend="one_minute_interval_assumptions"/>
2159 for a list of the assumptions regarding interval
2160 duration.</para>
2161
2162 </footnote>
2163 </para>
2164 </note>
2165
2166 <para>The time intervals recorded on any given template sheet must
2167 be part of a single follow -- all of the
2168 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-FollowID"/>
2169 values must be identical for those <xref linkend="INTERVALS"/>
2170 rows having a given <xref linkend="Intervals-SheetID"/>
2171 value.</para>
2172
2173 <para>A follow cannot have overlapping intervals of observation --
2174 the combination of <xref linkend="Intervals-Time"/> and
2175 <xref linkend="Intervals-FollowID"/> must be unique.</para>
2176
2177 <!-- There is no regression test for this since it uses the
2178 same code as the similar rule regards sheets. -->
2179 <para>All of the time intervals related to a given group
2180 composition survey must be part of a single follow -- all of the
2181 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-FollowID"/>
2182 values must be identical for those <xref linkend="INTERVALS"/>
2183 rows having a given <xref linkend="Intervals-GID"/> value.</para>
2184
2185 <note>
2186 <para>Deleting a row from the INTERVALS table will delete entire
2187 interval -- the system will first delete all related
2188 <xref linkend="DISTANCES"/>, <xref linkend="EVENTS"/>, and
2189 <xref linkend="SHEETS"/> rows, which will in turn delete
2190 dependent rows from other tables.</para>
2191 </note>
2192
2193 <section xml:id="Intervals-IntID" xreflabel="IntID">
2194 <title>IntID (Interval Identifier)</title>
2195
2196 <para>A unique integer identifying an interval of observation
2197 taken during a particular follow. &autoid;</para>
2198 </section>
2199
2200 <section xml:id="Intervals-FollowID" xreflabel="FollowID">
2201 <title>FollowID (Follow Identifier)</title>
2202
2203 <para>The integer identifying the follow to which the
2204 observation interval belongs.</para>
2205
2206 <para>&notnull;</para>
2207 </section>
2208
2209 <section xml:id="Intervals-SheetID" xreflabel="SheetID">
2210 <title>SheetID (Sheet Identifier)</title>
2211
2212 <para>The integer identifying the template sheet on which the
2213 interval observation was recorded.</para>
2214
2215 <para>The SheetID value cannot be changed. &notnull;</para>
2216 </section>
2217
2218 <section xml:id="Intervals-Time" xreflabel="Time">
2219 <title>Time (Start Time of the Interval)</title>
2220
2221 <para>The time at the start of the interval of observation. The
2222 stored value has a one minute precision; the seconds portion of
2223 the Time value must be <literal>0</literal>.</para>
2224
2225 <para>The Time value cannot be
2226 before <literal>&gmi_day_start;</literal> and cannot be
2227 after <literal>&gmi_day_end;</literal>. &notnull;</para>
2228 </section>
2229
2230 <section xml:id="Intervals-GID" xreflabel="GID">
2231 <title>GID (Group Composition Identifier)</title>
2232
2233 <para>The unique identifier assigned to each record of group
2234 composition. The
2235 <xref linkend="GROUPS"/>.<xref linkend="Groups-GID"/> code of
2236 the group composition time period into which the observation
2237 interval falls.</para>
2238
2239 <note>
2240 <para>Specifying a value of &null; causes the system to
2241 automatically compute this value.</para>
2242 </note>
2243
2244 <para>The GID value may be &null; if the observation interval is
2245 not associated with a period of time during which group
2246 composition was recorded.</para>
2247 </section>
2248
2249 <section xml:id="Intervals-Comment" xreflabel="Comment">
2250 <title>Comment</title>
2251
2252 <para>Textual comments concerning the entire observational
2253 interval. These comments are those of the data collector in
2254 the field.</para>
2255
2256 <para>&emptytext; However, the Comment value may be &null; when
2257 there are no comments concerning the entire observation
2258 interval.</para>
2259 </section>
2260
2261 </section>
2262
2263 <section xml:id="SHEETS" xreflabel="Sheets">
2264 <title>SHEETS (Follow Template Sheets)</title>
2265
2266 <para>SHEETS contains one row for every template sheet used in the
2267 field when recording follows, or in those cases where there is no
2268 longer an electronic record of exactly which intervals of a follow
2269 were written on which physical piece of paper, one row per follow
2270 per field observer involved in recording the follow (i.e. per
2271 FIELDFOLLOWS row.</para>
2272
2273 <para>Every template sheet must have a record of at least one
2274 interval -- each SHEETS row must have at least one related
2275 INTERVALS row. On the SHEETS table this condition is checked at
2276 &transaction; commit time, although on the
2277 <xref linkend="INTERVALS"/> table the check is done immediately in
2278 the case of UPDATE and at transaction commit time in the case of
2279 DELETE.</para>
2280
2281 <tip>
2282 <para>Use &transaction;s when making changes to both SHEETS and
2283 <xref linkend="INTERVALS"/> to produce bundles that ensure that
2284 at &transaction; commit each row on SHEETS has at least one
2285 related row on <xref linkend="INTERVALS"/>. Insert rows first
2286 into SHEETS and then into <xref linkend="INTERVALS"/>, and
2287 reverse this order when deleting rows.</para>
2288 </tip>
2289
2290 <note>
2291 <para>Deleting a <xref linkend="FIELDFOLLOWS"/> last related row
2292 from the SHEETS table will delete the
2293 <xref linkend="FIELDFOLLOWS"/> row.</para>
2294 </note>
2295
2296 <para>The <xref linkend="Sheets-Page"/> value must be unique per
2297 field follow (per <xref linkend="FIELDFOLLOWS"/> row) and there
2298 may be at most one &null; <xref linkend="Sheets-Page"/> value per
2299 field follow.</para>
2300
2301 <section xml:id="Sheets-SheetID" xreflabel="SheetID">
2302 <title>SheetID (Sheet Identifier)</title>
2303
2304 <para>A unique integer identifying the sheet. &autoid;</para>
2305 </section>
2306
2307 <section xml:id="Sheets-FFID" xreflabel="FFID">
2308 <title>FFID (Field Follow Identifier)</title>
2309
2310 <para>The integer identifying the field follow, the set of
2311 sheets collected by a researcher in the field comprising a day's
2312 mother-infant follow, in which the sheet belongs.</para>
2313
2314 <para>The SheetID value cannot be changed. &notnull;</para>
2315 </section>
2316
2317 <section xml:id="Sheets-Followtype" xreflabel="Followtype">
2318 <title>Followtype (Follow Type)</title>
2319
2320 <para>Code identifying the type of the follow; the type of data
2321 entry template used for data collection that determined what was
2322 on the printed page.<footnote>
2323
2324 <para>Presumably, the meaning of the data collected as
2325 determined by the data collection protocol in use did not
2326 change without a change in the print format of the data
2327 collection sheet.</para>
2328
2329 </footnote> The legal values for this column are
2330 defined by the <xref linkend="FOLLOWTYPES"/> support
2331 table.</para>
2332
2333 <para>&notnull;</para>
2334 </section>
2335
2336 <section xml:id="Sheets-Page" xreflabel="Page">
2337 <title>Page (Sheet Page Number)</title>
2338
2339 <para>The page number written on the sheet. This number must be
2340 an integer larger than zero. Note that the system does not
2341 require the page number to be contiguous.</para>
2342
2343 <para>This value may be &null; when the page number is not known
2344 or not recorded in electronic form.</para>
2345 </section>
2346
2347 <section xml:id="Sheets-Location" xreflabel="Location">
2348 <title>Location (Valley or Other Location of Data
2349 Collection)</title>
2350
2351 <para>The name of the valley or other physical location where
2352 the data written on the sheet was recorded.</para>
2353
2354 <para>&emptytext; However, this column may be &null; when there
2355 is no recorded location.</para>
2356 </section>
2357 </section>
2358
2359 </section>
2360
2361 <section xml:id="event_main_tables">
2362 <title>&event_section; Tables</title>
2363
2364 <section xml:id="EATS" xreflabel="EATS">
2365 <title>EATS (Food Eaten)</title>
2366
2367 <para>EATS contains one row for every different part of every kind
2368 of food eaten during a eating event. Each eating event, each
2369 <xref linkend="EVENTS"/> row having a
2370 <xref linkend="Events-Behavior"/> value that designates eating,
2371 must have at least one related row on EATS<footnote>
2372
2373 <para>If the food eaten is unknown this should be indicated with
2374 a <xref linkend="FOODKINDS"/> code which designates an unknown
2375 food. Likewise, if the part of the food eaten is unknown
2376 indicate this with a <xref linkend="FOODPARTS"/> code which
2377 designates that the part is unknown.</para>
2378
2379 </footnote>, and may have more if different kinds of food or parts
2380 of food are eaten by the chimpanzee.</para>
2381
2382 <para>The combination of the kind of food eaten and the food part
2383 eaten must be unique per event -- the combination of
2384 <xref linkend="Eats-EID"/>, <xref linkend="Eats-Foodkind"/>, and
2385 <xref linkend="Eats-Foodpart"/> must be unique.</para>
2386
2387 <note>
2388 <para>Aside from the
2389 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> column
2390 there is no way to record the amount of any one of the different
2391 kinds of food or parts thereof eaten by the individual.</para>
2392 </note>
2393
2394 <caution>
2395 <para>The system does not presently validate that the part eaten
2396 is appropriate for the kind of food eaten.<footnote>
2397
2398 <para>While this is not hard to do this kind of validation
2399 is not a priority.</para>
2400
2401 </footnote> To the system, it is perfectly acceptable to eat the
2402 kidney of a tree. It may be prudent to manually validate the
2403 existing combinations before performing analysis.</para>
2404 </caution>
2405
2406 <section xml:id="Eats-EatID" xreflabel="EatID">
2407 <title>EatID (Eating Identifier)</title>
2408
2409 <para>A unique identifier assigned to the combination of kind of
2410 food and part of food eaten during the given behavioral event.
2411 &autoid;</para>
2412 </section>
2413
2414 <section xml:id="Eats-EID" xreflabel="EID">
2415 <title>EID (Event Identifier)</title>
2416
2417 <para>The identifier assigned to the behavioral event, the
2418 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>, value,
2419 related to the kind of food eaten and part of food eaten.</para>
2420
2421 <para>&notnull;</para>
2422 </section>
2423
2424 <section xml:id="Eats-Foodkind" xreflabel="Foodkind">
2425 <title>Foodkind (Kind of Food Eaten)</title>
2426
2427 <para>Code indicating a kind of food eaten during the event.
2428 The legal values for this column are defined by the
2429 <xref linkend="FOODKINDS"/> support table.</para>
2430
2431 <para>&notnull;</para>
2432 </section>
2433
2434 <section xml:id="Eats-Foodpart" xreflabel="Foodpart">
2435 <title>Foodpart (Part of Food Eaten)</title>
2436
2437 <para>Code indicating the food part eaten during the event.
2438 The legal values for this column are defined by the
2439 <xref linkend="FOODPARTS"/> support table.</para>
2440
2441 <para>&notnull;</para>
2442 </section>
2443 </section>
2444
2445 <section xml:id="EVENTS" xreflabel="EVENTS">
2446 <title>EVENTS (Behavioral Events)</title>
2447
2448 <para>EVENTS contains one row for every recorded non-social
2449 behavior exhibited by each focal as well as one row for every
2450 recorded social behavior exhibited by each focal for every social
2451 partner, for every follow interval. Each of the focal's
2452 non-social behaviors for the interval are represented by a single
2453 row per behavior in EVENTS. Each of the focal's social
2454 behaviors for the interval are represented by a single row in
2455 EVENTS per behavior per social partner.
2456 These rules are enforced on &transaction; commit by ensuring that
2457 the combination of EVENTS.<xref linkend="Events-Behavior"/>, and
2458 all related
2459 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
2460 values, related via
2461 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>, and
2462 the roles the participating individuals play in the interaction,
2463 the <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> values
2464 are unique per EVENTS.<xref linkend="Events-IntID"/>. The
2465 exception is that anonymous individuals are allowed duplicates;
2466 duplicates are allowed when EVENTS.<xref linkend="Events-Baboon"/>
2467 is &true; or when one of the individuals involved has a
2468 <xref linkend="Biography_Data-AnimID"/> value which is
2469 either <literal>&gmi_unk_animid;</literal>
2470 or <literal>&gmi_stranger;</literal>.</para>
2471
2472 <tip>
2473 <para>Social behaviors are recorded as dyadic interactions
2474 between 2 individuals. Record multiple interactions as pairs of
2475 dyadic interactions. When directionality is involved, as in
2476 mutual grooming between 2 individuals, 2 grooming events are
2477 recorded, identical except for reversed directionality.</para>
2478 </tip>
2479
2480 <para>There must always be a chimpanzee involved in the behavior
2481 -- each EVENTS row must have at least one row on
2482 <xref linkend="PARTS"/>, related by <xref linkend="Events-EID"/>.
2483 This rule is enforced on &transaction; commit.</para>
2484
2485 <para>At least one of the individuals involved in the behavior
2486 must be a focal of the follow -- at least one of the related
2487 <xref linkend="PARTS"/> rows must have a
2488 <xref linkend="Parts-Participant"/> value which identifies an
2489 animal also identified in one of the related
2490 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-ChimpID"/>
2491 values. This rule is enforced on &transaction; commit on
2492 <xref linkend="PARTS"/>, <xref linkend="EVENTS"/>, and
2493 <xref linkend="FOLLOWPARTS"/>, and immediately on
2494 <xref linkend="INTERVALS"/>.</para>
2495
2496 <para>The
2497 <xref linkend="BEHAVIORS"/>.<xref linkend="Behaviors-Behavior"/>
2498 value identifying the kind of behavior controls quite a lot
2499 regarding the event including: whether the behavior can occur,
2500 whether a <xref linkend="Behaviors-Position"/> value is required,
2501 the identity of the individuals allowed to be involved in the
2502 behavioral event, the fashion in which individuals are allowed to
2503 participate, and whether the behavior is a social one -- whether
2504 more than one individual is involved -- and whether a baboon can
2505 be involved. For further information see the
2506 <xref linkend="BEHAVIORS"/> table.</para>
2507
2508 <para>When the behavior is social, recording a dyadic interaction
2509 between two individuals, and one of the two individuals involved
2510 plays the active part, has a
2511 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value
2512 of <literal>&gmi_actor;</literal> (Actor), then the other
2513 individual must have the passive role, their
2514 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value must
2515 be <literal>&gmi_actee;</literal> (Actee); and the reverse is true
2516 as well. Social interactions may be non-directional as well as
2517 directional. When there is no directionality the individuals
2518 involved in the interaction are both
2519 labeled <quote>participant</quote> -- when the behavior is social
2520 and one of the individuals has a
2521 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value
2522 of <literal>&gmi_participant;</literal> (Participant) then the
2523 other individual must also have a
2524 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value
2525 of <literal>&gmi_participant;</literal>. These rules are check
2526 upon &transaction; commit.</para>
2527
2528 <para>EVENTS rows recording behaviors that are social in nature
2529 are always dyadic, there must always be two related
2530 <xref linkend="PARTS"/> rows to record the two participants
2531 involved. The exception to this is when one of the participants
2532 is a baboon. In this case there is a single related
2533 <xref linkend="PARTS"/> row recording which focal is involved in
2534 the interaction and the EVENTS.<xref linkend="Events-Baboon"/>
2535 column is set to indicate the baboon's involvement. This rule is
2536 enforced on &transaction; commit.</para>
2537
2538 <para>The individual involved in those EVENTS rows recording
2539 behaviors which are not social, those where there is a single
2540 individual involved in the behavior, those having a single related
2541 <xref linkend="PARTS"/> row, cannot be directional, their related
2542 related <xref linkend="PARTS"/> row must have a
2543 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value
2544 of <literal>&gmi_self;</literal> (Self). Further, a baboon may
2545 not be involved, EVENTS.<xref linkend="Events-Baboon"/> must be
2546 &false;. These rules are checked upon &transaction;
2547 commit.</para>
2548
2549 <note>
2550 <para>Deleting a row from the EVENTS table will delete the
2551 entire event -- the system will first delete all related
2552 <xref linkend="PARTS"/>, <xref linkend="EATS"/>,
2553 <xref linkend="FISHED"/>, <xref linkend="PLAYS"/>,
2554 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, and
2555 <xref linkend="VOCS"/> rows.</para>
2556 </note>
2557
2558 <section xml:id="Events-EID" xreflabel="EID">
2559 <title>EID (Event Identifier)</title>
2560
2561 <para>A unique identifier assigned to each behavioral
2562 event. &autoid;</para>
2563 </section>
2564
2565 <section xml:id="Events-IntID" xreflabel="IntID">
2566 <title>IntID (Interval Identifier)</title>
2567
2568 <para>The identifier assigned to the follow interval, the
2569 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-IntID"/>,
2570 value, related to the occurrence of the recorded behavior.</para>
2571
2572 <para>&notnull;</para>
2573 </section>
2574
2575 <section xml:id="Events-Behavior" xreflabel="Behavior">
2576 <title>Behavior (Behavior Engaged In)</title>
2577
2578 <para>Code indicating the behavior engaged in. The legal values
2579 for this column are defined by the <xref linkend="BEHAVIORS"/>
2580 support table.</para>
2581
2582 <para>&notnull;</para>
2583 </section>
2584
2585 <section xml:id="Events-Position" xreflabel="Position">
2586 <title>Position (Position Within the Canopy)</title>
2587
2588 <para>Code indicating the position within the forest canopy
2589 where the event occurred. The legal values for this column are
2590 defined by the <xref linkend="POSITIONS"/> support table.</para>
2591
2592 <para>&notnull;</para>
2593 </section>
2594
2595 <section xml:id="Events-Baboon" xreflabel="Baboon">
2596 <title>Baboon (Is a Baboon a Participant?)</title>
2597
2598 <para>A Boolean value. When &true; a baboon is a participant in
2599 the behavior. When &false; a baboon is not a
2600 participant.</para>
2601
2602 <para>&notnull;</para>
2603 </section>
2604
2605 <section xml:id="Events-Uncertain" xreflabel="Uncertain">
2606 <title>Uncertain (The Behavior May or May Not Have Occurred)</title>
2607
2608 <para>A Boolean value. When &true; the recorded behavior is in
2609 doubt.<footnote>
2610
2611 <para>Note that the system contains no way to designate that
2612 the identity of a participant in the behavior is
2613 uncertain.</para>
2614
2615 </footnote> When &false; the recorded behavior was clearly
2616 observed and is not in doubt. See the &gcdbh; for further
2617 information.</para>
2618
2619 <para>&notnull;</para>
2620 </section>
2621
2622 <section xml:id="Events-Comment" xreflabel="Comment">
2623 <title>Comment (Notes Regarding the Event)</title>
2624
2625 <para>Textual comments concerning the specific behavioral event.
2626 These comments are those of the data collector in the
2627 field.</para>
2628
2629 <para>&emptytext; However, the Comment value may be &null; when
2630 there are no comments concerning the event.</para>
2631 </section>
2632
2633 </section>
2634
2635 <section xml:id="FISHED" xreflabel="FISHED">
2636 <title>FISHED (Food Fished For)</title>
2637
2638 <para>FISHED contains one row to record the part and the kind of
2639 food fished for during each fishing event. Each fishing event,
2640 each <xref linkend="EVENTS"/> row having a
2641 <xref linkend="Events-Behavior"/> value that designates fishing,
2642 must have exactly one related row on FISHED<footnote>
2643
2644 <para>If the food fished for is unknown this should be indicated
2645 with a <xref linkend="FOODKINDS"/> code which designates an
2646 unknown food. Likewise, if the part of the food fished for is
2647 unknown indicate this with a <xref linkend="FOODPARTS"/> code
2648 which designates that the part is unknown.</para>
2649
2650 </footnote>, and may have more if different kinds of food are
2651 fished for by the chimpanzee.</para>
2652
2653 <para>Only those kinds of food designated
2654 as <quote>fishable</quote> may be fished for --
2655 FISHED.<xref linkend="Fished-Foodkind"/> may contain only those
2656 <xref linkend="FOODKINDS"/>.<xref linkend="Foodkinds-Foodkind"/>
2657 values where the related
2658 <xref linkend="FOODKINDS"/>.<xref linkend="Foodkinds-Fishable"/>
2659 value is &true;.
2660
2661 Only those parts of food designated
2662 as <quote>fishable</quote> may be fished for --
2663 FISHED.<xref linkend="Fished-Foodpart"/> may contain only those
2664 <xref linkend="FOODPARTS"/>.<xref linkend="Foodparts-Foodpart"/>
2665 values where the related
2666 <xref linkend="FOODPARTS"/>.<xref linkend="Foodparts-Fishable"/>
2667 value is &true;.</para>
2668
2669 <caution>
2670 <para>The system does not presently validate that the part
2671 fished for is appropriate for the kind of food fished for. It
2672 may be prudent to manually validate the existing combinations
2673 before performing analysis.</para>
2674 </caution>
2675
2676 <section xml:id="Fished-FishedID" xreflabel="FishedID">
2677 <title>FishedID (Fishing Identifier)</title>
2678
2679 <para>A unique identifier assigned to the kind of food fished
2680 for during the given behavioral event. &autoid;</para>
2681 </section>
2682
2683 <section xml:id="Fished-EID" xreflabel="EID">
2684 <title>EID (Event Identifier)</title>
2685
2686 <para>The identifier assigned to the behavioral event, the
2687 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>, value,
2688 related to the kind of food fished for.</para>
2689
2690 <para>&notnull;</para>
2691 </section>
2692
2693 <section xml:id="Fished-Foodkind" xreflabel="Foodkind">
2694 <title>Foodkind (Kind of Food Fished For)</title>
2695
2696 <para>Code indicating a kind of food fished for during the
2697 event. The legal values for this column are defined by the
2698 <xref linkend="FOODKINDS"/> support table.</para>
2699
2700 <para>&notnull;</para>
2701 </section>
2702
2703 <section xml:id="Fished-Foodpart" xreflabel="Foodpart">
2704 <title>Foodpart (Part of Food Fished For)</title>
2705
2706 <para>Code indicating the food part fished for during the event.
2707 The legal values for this column are defined by the
2708 <xref linkend="FOODPARTS"/> support table.</para>
2709
2710 <para>&notnull;</para>
2711 </section>
2712
2713 <section xml:id="Fished-Result" xreflabel="Result">
2714 <title>Result (Result of the Fishing Attempt)</title>
2715
2716 <para>Code indicating the result of the fishing attempt. The
2717 legal values for this column are defined by the FISHING_RESULTS
2718 support table.</para>
2719
2720 <para>&notnull;</para>
2721 </section>
2722 </section>
2723
2724 <section xml:id="PARTS" xreflabel="PARTS">
2725 <title>PARTS (Behavioral Participants)</title>
2726
2727 <para>PARTS contains one row for every individual, whether a focal
2728 in the follow or not<footnote>
2729
2730 <para>An improved design would have an additional column,
2731 automatically maintained by the system, on
2732 <xref linkend="PARTS"/> to record the role the participant
2733 plays in the follow, i.e., mother, infant, sib, or
2734 non-focal. This would be analogous to the
2735 <xref linkend="DISTANCEPARTS"/>.<xref linkend="Distanceparts-Role"/>
2736 column. Such a column would simplify both the data
2737 validation coding and database querying. See also
2738 the <link linkend="improved-distanceparts-design">footnote</link>
2739 regards improving the <xref linkend="DISTANCEPARTS"/>
2740 design.</para>
2741
2742 </footnote>, involved in each recorded behavior (each
2743 <xref linkend="EVENTS"/> row). Therefore there are always
2744 either 1 or 2 PARTS rows per <xref linkend="EVENTS"/> row.
2745 Individuals which are unrecognized or otherwise anonymous, the
2746 individuals with <xref linkend="Biography_Data-AnimID"/> values
2747 of <literal>&gmi_unk_animid;</literal>
2748 or <literal>&gmi_stranger;</literal>, have rows in PARTS when
2749 they are involved in the behavior, but baboons do not.</para>
2750
2751 <para>An individual can be involved in a given behavioral event
2752 only once -- the related
2753 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
2754 must be unique per <xref linkend="Parts-EID"/>.</para>
2755
2756 <para>Each participant in an event must be a
2757 member of the study population on the date of the follow. The
2758 <xref linkend="BIOGRAPHY_DATA"/>.<xref
2759 linkend="Biography_Data-Entrydate"/>
2760 cannot be after the follow's
2761 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/> value.
2762 The <xref linkend="BIOGRAPHY_DATA"/>.<xref
2763 linkend="Biography_Data-Departdate"/>
2764 cannot be before the follow's
2765 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/>.</para>
2766
2767 <section xml:id="Parts-PID" xreflabel="PID">
2768 <title>PID (Parts Identifier)</title>
2769
2770 <para>A unique identifier assigned to the individual involved in
2771 the given behavioral event. &autoid;</para>
2772 </section>
2773
2774 <section xml:id="Parts-EID" xreflabel="EID">
2775 <title>EID (Event Identifier)</title>
2776
2777 <para>The identifier assigned to the behavioral event, the
2778 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>,
2779 value, related to the recorded participant.</para>
2780
2781 <para>&notnull;</para>
2782 </section>
2783
2784 <section xml:id="Parts-Part" xreflabel="Part">
2785 <title>Part (Participant Role)</title>
2786
2787 <para>One of the following codes indicating the role the
2788 designated individual plays in the behavior:</para>
2789
2790 <variablelist>
2791 <varlistentry>
2792 <term><literal>&gmi_actor;</literal> (Actor)</term>
2793
2794 <listitem>
2795 <para>The individual has the active role in the behavior,
2796 initiating or sustaining it.</para>
2797 </listitem>
2798 </varlistentry>
2799
2800 <varlistentry>
2801 <term><literal>&gmi_actee;</literal> (Actee)</term>
2802
2803 <listitem>
2804 <para>The individual has the passive role in the
2805 behavior, receiving attention or contact.</para>
2806 </listitem>
2807 </varlistentry>
2808
2809 <varlistentry>
2810 <term><literal>&gmi_participant;</literal> (Participant)</term>
2811
2812 <listitem>
2813 <para>The individual is neither active nor passive, such
2814 concepts do not apply or are not appropriate to the
2815 behavior or the data collection protocol.</para>
2816 </listitem>
2817 </varlistentry>
2818
2819 <varlistentry>
2820 <term><literal>&gmi_self;</literal> (Self)</term>
2821
2822 <listitem>
2823 <para>The individual is the sole participant in the
2824 behavior.</para>
2825 </listitem>
2826 </varlistentry>
2827 </variablelist>
2828
2829 <para>&notnull;</para>
2830 </section>
2831
2832 <section xml:id="Parts-Participant" xreflabel="Participant">
2833 <title>Participant (Chimp Virtual Identifier)</title>
2834
2835 <para>The identifier assigned to the individual involved in the
2836 behavior. The <xref linkend="ChimpIDs-ChimpID"/> code of the
2837 individual.</para>
2838
2839 <para>&notnull;</para>
2840 </section>
2841 </section>
2842
2843 <section xml:id="PLAYS" xreflabel="PLAYS">
2844 <title>PLAYS (Playing Detail)</title>
2845
2846 <para>PLAYS contains one row for every different play activity
2847 engaged in during a play event. Each play event, each
2848 <xref linkend="EVENTS"/> row having a
2849 <xref linkend="Events-Behavior"/> value that designates a play
2850 type event, must have at least one related row on PLAYS<footnote>
2851
2852 <para>If the play activity occurring is unknown this should be
2853 indicated with a <xref linkend="PLAY_TYPES"/> code which
2854 designates an unknown play activity.</para>
2855
2856 </footnote>, and may have more if the playing chimpanzee engages
2857 in different play activities during the play event.</para>
2858
2859 <para>The play activity must be unique per event -- the
2860 combination of <xref linkend="Plays-EID"/> and
2861 <xref linkend="Plays-Play"/> must be unique.</para>
2862
2863 <note>
2864 <para>Aside from the
2865 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> column
2866 there is no way to record the number or duration of any one of
2867 the different play activities engaged in by the individual during
2868 the play event.</para>
2869 </note>
2870
2871 <section xml:id="Plays-PlayID" xreflabel="PlayID">
2872 <title>PlayID (Playing Identifier)</title>
2873
2874 <para>A unique identifier assigned to the play activity engaged
2875 in during the given behavioral event. &autoid;</para>
2876 </section>
2877
2878 <section xml:id="Plays-EID" xreflabel="EID">
2879 <title>EID (Event Identifier)</title>
2880
2881 <para>The identifier assigned to the behavioral event, the
2882 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>, value,
2883 related to the play activity.</para>
2884
2885 <para>&notnull;</para>
2886 </section>
2887
2888 <section xml:id="Plays-Play" xreflabel="Play">
2889 <title>Play (Play Activity Engaged In)</title>
2890
2891 <para>Code indicating a play activity engaged in during the
2892 event. The legal values for this column are defined by the
2893 <xref linkend="PLAY_TYPES"/> support table.</para>
2894
2895 <para>&notnull;</para>
2896 </section>
2897
2898 </section>
2899
2900 <section xml:id="RESTS" xreflabel="RESTS">
2901 <title>RESTS (Resting Detail)</title>
2902
2903 <para>RESTS contains one row to record the resting posture
2904 assumed during each resting event. Each resting event, each
2905 <xref linkend="EVENTS"/> row having a
2906 <xref linkend="Events-Behavior"/> value that designates a resting
2907 type event, must have exactly one related row on RESTS.<footnote>
2908
2909 <para>If the resting posture assumed is unknown this should be
2910 indicated with a <xref linkend="RESTING_POSTURES"/> code which
2911 designates an unknown resting posture.</para>
2912
2913 </footnote></para>
2914
2915 <note>
2916 <para>Aside from the
2917 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> column
2918 there is no way to record the duration of the resting
2919 posture assumed by the individual during the resting
2920 event.</para>
2921 </note>
2922
2923 <section xml:id="Rests-RestID" xreflabel="RestID">
2924 <title>RestID (Resting Identifier)</title>
2925
2926 <para>A unique identifier assigned to the resting posture
2927 assumed during the given behavioral event. &autoid;</para>
2928 </section>
2929
2930 <section xml:id="Rests-EID" xreflabel="EID">
2931 <title>EID (Event Identifier)</title>
2932
2933 <para>The identifier assigned to the behavioral event, the
2934 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>,
2935 value, related to the resting posture assumed.</para>
2936
2937 <para>&notnull;</para>
2938 </section>
2939
2940 <section xml:id="Rests-Rest" xreflabel="Rest">
2941 <title>Rest (Resting Posture Assumed)</title>
2942
2943 <para>Code indicating a resting posture assumed during the
2944 event. The legal values for this column are defined by the
2945 <xref linkend="RESTING_POSTURES"/> support table.</para>
2946
2947 <para>&notnull;</para>
2948 </section>
2949
2950 </section>
2951
2952 <section xml:id="RIDES" xreflabel="RIDES">
2953 <title>RIDES (Riding Detail)</title>
2954
2955 <para>RIDES contains one row which records the riding posture
2956 assumed during each riding event. Each riding event, each
2957 <xref linkend="EVENTS"/> row having a
2958 <xref linkend="Events-Behavior"/> value that designates a riding
2959 type event, must have exactly one related row on RIDES.<footnote>
2960
2961 <para>If the riding posture assumed is unknown this should be
2962 indicated with a <xref linkend="RIDING_POSTURES"/> code which
2963 designates an unknown riding posture.</para>
2964
2965 </footnote></para>
2966
2967 <note>
2968 <para>Aside from the
2969 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> column
2970 there is no way to record duration of the riding posture assumed
2971 by the individual during the riding event.</para>
2972 </note>
2973
2974 <section xml:id="Rides-RideID" xreflabel="RideID">
2975 <title>RideID (Riding Identifier)</title>
2976
2977 <para>A unique identifier assigned to the riding posture
2978 assumed during the given behavioral event. &autoid;</para>
2979 </section>
2980
2981 <section xml:id="Rides-EID" xreflabel="EID">
2982 <title>EID (Event Identifier)</title>
2983
2984 <para>The identifier assigned to the behavioral event, the
2985 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>,
2986 value, related to the riding posture assumed.</para>
2987
2988 <para>&notnull;</para>
2989 </section>
2990
2991 <section xml:id="Rides-Ride" xreflabel="Ride">
2992 <title>Ride (Riding Posture Assumed)</title>
2993
2994 <para>Code indicating a riding posture assumed during the
2995 event. The legal values for this column are defined by the
2996 <xref linkend="RIDING_POSTURES"/> support table.</para>
2997
2998 <para>&notnull;</para>
2999 </section>
3000
3001 </section>
3002
3003 <section xml:id="VOCS" xreflabel="VOCS">
3004 <title>VOCS (Vocalization Detail)</title>
3005
3006 <para>VOCS contains one row for every different kind of
3007 vocalization made during a vocalization event. Each vocalization
3008 event, each <xref linkend="EVENTS"/> row having a
3009 <xref linkend="Events-Behavior"/> value that designates a
3010 vocalization, must have at least one related row on VOCS<footnote>
3011
3012 <para>If the vocalization made is unknown this should be
3013 indicated with a <xref linkend="VOCALIZATIONS"/> code which
3014 designates an unknown vocalization.</para>
3015
3016 </footnote>, and may
3017 have more if different kinds of vocalizations are made by the
3018 vocalizing chimpanzee.</para>
3019
3020 <para>The kind of vocalization must be unique per event -- the
3021 combination of <xref linkend="Vocs-EID"/> and
3022 <xref linkend="Vocs-Vocalization"/> must be unique.</para>
3023
3024 <note>
3025 <para>Aside from the
3026 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> column
3027 there is no way to record the number or volume of any one of the
3028 different kinds of vocalizations made by the individual during
3029 the vocalization event.</para>
3030 </note>
3031
3032 <section xml:id="Vocs-VocID" xreflabel="VocID">
3033 <title>VocID (Vocalization Identifier)</title>
3034
3035 <para>A unique identifier assigned to the kind of vocalization
3036 made in the given behavioral event. &autoid;</para>
3037 </section>
3038
3039 <section xml:id="Vocs-EID" xreflabel="EID">
3040 <title>EID (Event Identifier)</title>
3041
3042 <para>The identifier assigned to the behavioral event, the
3043 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>,
3044 value, related to the kind of vocalization made.</para>
3045
3046 <para>&notnull;</para>
3047 </section>
3048
3049 <section xml:id="Vocs-Vocalization" xreflabel="Vocalization">
3050 <title>Vocalization (Kind of Vocalization Made)</title>
3051
3052 <para>Code indicating a kind of vocalization made as the event
3053 occurred. The legal values for this column are defined by the
3054 <xref linkend="VOCALIZATIONS"/> support table.</para>
3055
3056 <para>&notnull;</para>
3057 </section>
3058
3059 </section>
3060 </section>
3061
3062 <section xml:id="distance_main_tables">
3063 <title>&distance_section; Tables</title>
3064
3065 <section xml:id="DISTANCEPARTS" xreflabel="DISTANCEPARTS">
3066 <title>DISTANCEPARTS (Follow Participants Between Whom Distance
3067 Was Measured)</title>
3068
3069 <para>DISTANCEPARTS contains exactly 2 rows for each recorded
3070 distance, one row for each of the individuals between whom the
3071 distance was measured. To restate, there are always exactly 2
3072 rows on DISTANCEPARTS for every <xref linkend="DISTANCES"/> row.
3073 This check is performed on &transaction; commit.</para>
3074
3075 <para>The individuals between whom the distance is measured can
3076 only be those individuals who are participants in the follow --
3077 each <xref linkend="Distanceparts-Participant"/> value in
3078 DISTANCEPARTS has a related
3079 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-AnimID"/>
3080 value, this value must be that of a
3081 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-AnimID"/>
3082 related to one of the follows'
3083 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-ChimpID"/>
3084 values. This check is performed on &transaction; commit on update
3085 to <xref linkend="FOLLOWPARTS"/> and insert or update of
3086 DISTANCEPARTS, and otherwise immediately.</para>
3087
3088 <para>The individual must have the same role (i.e., mother,
3089 infant, twin1, etc.) on DISTANCEPARTS as the individual does in
3090 the rest of the follow -- the
3091 DISTANCEPARTS.<xref linkend="Distanceparts-Role"/> value for each
3092 individual must match the value found in the related
3093 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-Role"/>.
3094 This check is performed on &transaction; commit on changes to
3095 DISTANCEPARTS and <xref linkend="FOLLOWPARTS"/> and immediately
3096 upon changes to <xref linkend="INTERVALS"/> and
3097 <xref linkend="DISTANCES"/>.<footnote>
3098
3099 <para xml:id="improved-distanceparts-design">An improved
3100 design would have the trigger automatically set the value of
3101 <xref linkend="DISTANCEPARTS"/>.<xref linkend="Distanceparts-Role"/>
3102 based on the individual's
3103 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-Role"/>.
3104 Among other advantages, the columns on the
3105 <xref linkend="FAMILY_DISTS"/> view that expose the role could
3106 be removed.</para>
3107
3108 </footnote></para>
3109
3110 <para>Distance must be measured between two different individuals
3111 -- the combination of <xref linkend="Distanceparts-DistID"/> and
3112 the related
3113 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-AnimID"/> must
3114 be unique.</para>
3115
3116 <para>Distance can be measured between two individuals at most
3117 once per interval.</para>
3118
3119 <para>If there is a group composition survey for the related
3120 interval then the survey must include the individuals between whom
3121 the distance was measured -- when there is a related
3122 <xref linkend="GROUPS"/> row then the related
3123 <xref linkend="GROUPMEMBERS"/> rows must include rows for the
3124 individuals identified in the DISTANCEPARTS rows. This check is
3125 performed upon &transaction; commit on changes to
3126 <xref linkend="INTERVALS"/> and delete of
3127 <xref linkend="GROUPMEMBERS"/> rows, and immediately
3128 otherwise.</para>
3129
3130 <section xml:id="Distanceparts-DPID" xreflabel="DPID">
3131 <title>DPID (Distance Participant Identifier)</title>
3132
3133 <para>A unique integer identifying the row recording one
3134 participant in the inter-individual distance measurement.
3135 &autoid;</para>
3136 </section>
3137
3138 <section xml:id="Distanceparts-DistID" xreflabel="DistID">
3139 <title>DistID (Distance Identifier)</title>
3140
3141 <para>The identifier assigned to the distance measurement, the
3142 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
3143 value, of which the individual was a participant.</para>
3144
3145 <para>&notnull;</para>
3146 </section>
3147
3148 <section xml:id="Distanceparts-Role" xreflabel="Role">
3149 <title>Role</title>
3150
3151 <para>Code indicating the individual's role in the follow. The
3152 legal values for this column are defined by the
3153 <xref linkend="FOLLOWROLES"/> support table.</para>
3154
3155 <para>&notnull;</para>
3156 </section>
3157
3158 <section xml:id="Distanceparts-Participant" xreflabel="Participant">
3159 <title>Participant (Chimp Virtual Identifier)</title>
3160
3161 <para>The identifier assigned to the individual. The
3162 <xref linkend="ChimpIDs-ChimpID"/> code of the
3163 individual.</para>
3164
3165 <para>&notnull;</para>
3166 </section>
3167 </section>
3168
3169 <section xml:id="DISTANCES" xreflabel="DISTANCES">
3170 <title>DISTANCES (Distances Between Follow Participants)</title>
3171
3172 <para>DISTANCES contains one row for each recorded distance
3173 between follow participants. Note that codes are used to
3174 represent various distance ranges, and that codes have varied over
3175 time. For more information see the &gcdbh;.</para>
3176
3177 <para>When the <xref linkend="Distances-Distance"/> value
3178 is <literal>&gmi_distunk;</literal>, observed but unknown, the
3179 <xref linkend="Distances-Uncertain"/> value must be &true;.</para>
3180
3181 <note>
3182 <para>Deleting a row from the DISTANCES table will delete the
3183 entire record of the distance -- the system will first delete
3184 all related <xref linkend="DISTANCEPARTS"/> rows.</para>
3185 </note>
3186
3187 <section xml:id="Distances-DistID" xreflabel="DistID">
3188 <title>DistID (Distance Identifier)</title>
3189
3190 <para>A unique integer identifying the row recording the
3191 distance. &autoid;</para>
3192 </section>
3193
3194 <section xml:id="Distances-IntID" xreflabel="IntID">
3195 <title>IntID (Interval Identifier)</title>
3196
3197 <para>The identifier assigned to the follow interval, the
3198 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-IntID"/>,
3199 value, during which the distance measurement was taken.</para>
3200
3201 <para>&notnull;</para>
3202 </section>
3203
3204 <section xml:id="Distances-Uncertain" xreflabel="Uncertain">
3205 <title>Uncertain (Distance is Uncertain)</title>
3206
3207 <para>A Boolean flag indicating whether the observer was certain
3208 of the recorded distance measurement. &true; when the distance
3209 measurement is not certain, &false; when certain.</para>
3210
3211 <para>&notnull;</para>
3212 </section>
3213
3214 <section xml:id="Distances-Distance" xreflabel="Distance">
3215 <title>Distance (Distance Code)</title>
3216
3217 <para>Code indicating the distance between two followed
3218 individuals. The legal values for this column are defined by
3219 the <xref linkend="DISTANCECODES"/> support table.</para>
3220
3221 <para>&notnull;</para>
3222 </section>
3223 </section>
3224 </section>
3225
3226 <section xml:id="group_main_tables">
3227 <title>&group_section; Tables</title>
3228
3229 <caution>
3230 <para>The data validation rules discussed in this section are
3231 subject to change as the system continues to be developed.</para>
3232 </caution>
3233
3234 <section xml:id="GROUPMEMBERS" xreflabel="GROUPMEMBERS">
3235 <title>GROUPMEMBERS (Individuals Found in Group Composition
3236 Survey Analysis)</title>
3237
3238 <para>The data in GROUPMEMBERS is the result of an automated
3239 analysis called <wordasword>smearing</wordasword> which spreads
3240 the group composition survey results over larger time intervals.
3241 GROUPMEMBERS contains one row for each individual which analysis
3242 determines is a member of the surveyed group for each analyzed group
3243 composition time interval.</para>
3244
3245 <caution>
3246 <para>At present there is extremely limited automated group
3247 composition analysis and the GROUPMEMBERS table contains one row
3248 per <xref linkend="RAW_GROUPMEMBERS"/> row.</para>
3249 </caution>
3250
3251 <para>An individual can be recorded present in a group at most
3252 once -- the combination of <xref linkend="Groupmembers-GID"/> and
3253 the related
3254 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-AnimID"/> must
3255 be unique.</para>
3256
3257 <!-- untested -->
3258 <para>A warning is generated when an individual is in a
3259 group comp, when that individual is is less than
3260 &gmi_min_alone_age; old, and their current mother is not in the
3261 group comp. The current mother is the biological mother (the
3262 mother indicated when the young individual has a
3263 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-MomID"/>
3264 which is not &null;) if the young individual is never adopted or
3265 adopted after the date of the group comp. The current mother is
3266 the adoptive mother if the date of the group comp is after the
3267 date of permanent adoption (after the, non-&null;,
3268 <xref linkend="ADOPTIONS"/>.<xref linkend="Adoptions-ADate"/>).
3269 In the case of multiple permanent adoptions the current mother
3270 is the most recent adoptive mother as of the date of the group
3271 comp. When the biological mother is unknown and there are no
3272 known adoptive parents then there are no requirements regarding
3273 presence of a parent. These checks are performed by the warning
3274 system and so do not occur until the warning system is
3275 run.</para>
3276
3277 <!-- untested -->
3278 <para>The reverse is also true; a warning is generated when the
3279 most current <quote>mother</quote> is present in the group
3280 composition and any offspring, biological or permanently adopted
3281 on or before the date of the follow, in the study as of the date
3282 of the follow, less than &gmi_min_alone_age; old are not
3283 present. As above, in the case of adoption, only the current
3284 mother/offspring relationship is considered. As above, these
3285 checks are performed by the warning system and so do not occur
3286 until the warning system is run.</para>
3287
3288 <para>Temporary adoptions do not generate warnings, with the
3289 exception that a warning is generated if the focals of a follow
3290 are involved in a temporary adoption and either the mother or
3291 the infant appears in the group comp without the other.</para>
3292
3293 <note>
3294 <para>When an adoption is temporary the infant need not be
3295 with the temporary adoptive parent. Significantly, the
3296 infant need not be with <emphasis>any</emphasis> parent.
3297 The presumption is that temporary adoption may be due to
3298 infant abandonment, and the establishment of a temporary
3299 adoption is what the system could (but does not) use to
3300 flag this situation. But unless a temporary adoption
3301 changes at a later date into a permanent adoption,
3302 temporary adoptions have no end date.</para>
3303
3304 <para>Rather than have temporary adoptions create
3305 situations where the temporarily adopted individual
3306 thenceforth is not required to be with any parent, the
3307 system uses the existence of a mother/infant follow
3308 involving a temporary parent as the flag which triggers
3309 suspension of young-infants-must-be-with-parents
3310 warnings.</para>
3311 </note>
3312
3313 <note>
3314 <para>At the various time interval endpoints, the date of
3315 permanent adoption, the date of entry into the study, and the
3316 date of departure from the study, the enforced rules regarding
3317 chimps less than &gmi_min_alone_age; and their real or
3318 permanently adoptive mothers are interpreted in such a way as
3319 to loosen the requirements and exclude the date of the
3320 interval endpoint.<footnote>
3321
3322 <para>At any rate this is the intended design. These sorts
3323 of corner cases are always tricky and there may be
3324 bugs.</para>
3325
3326 </footnote> This is because individuals may be born, die, be
3327 adopted, etc., at any point during the day.</para>
3328 </note>
3329
3330 <caution>
3331 <para>Because the system sometimes but not always expects
3332 offspring less than &gmi_min_alone_age; to be part of
3333 their <quote>mother's</quote> group composition care must be
3334 taken during analysis to ensure that results are not skewed
3335 based on whether or not the offspring's presence is
3336 forced.</para>
3337 </caution>
3338
3339 <caution>
3340 <para>Presence in the study population is determined by whether
3341 the date of the follow is after an individual's
3342 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Entrydate"/>
3343 and before the individual's
3344 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Departdate"/>.
3345 Because the individual need not be in the study population for
3346 the entire day on the date of entry into the study population
3347 or the date of departure from the study population the above
3348 rules regarding offspring less than &gmi_min_alone_age; old do
3349 not require the mother to be with the offspring on these two
3350 days. Unless care is taken during analysis this censoring
3351 could lead to biased results.</para>
3352 </caution>
3353
3354 <para>The perineal swelling
3355 (<xref linkend="Groupmembers-Swelling"/>) value must be &null;
3356 unless the individual is female. The perineal swelling may not be
3357 more than <literal>&gmi_0;</literal> unless the individual is at
3358 least &gmi_swelling_min_age; old.</para>
3359
3360 <section xml:id="GroupMembers-GMID" xreflabel="GMID">
3361 <title>GMID (Group Composition Identifier)</title>
3362
3363 <para>A unique integer identifying the row recording an
3364 individual's presence in the group composition survey.
3365 &autoid;</para>
3366 </section>
3367
3368 <section xml:id="Groupmembers-GID" xreflabel="GID">
3369 <title>GID (Group Survey Identifier)</title>
3370
3371 <para>A unique integer identifying the group composition survey
3372 during which the individual was found. &notnull;</para>
3373
3374 </section>
3375
3376 <section xml:id="Groupmembers-ChimpID" xreflabel="ChimpID">
3377 <title>ChimpID (Chimp Virtual Identifier)</title>
3378
3379 <para>The identifier assigned to the group member. The
3380 <xref linkend="ChimpIDs-ChimpID"/> code of the
3381 individual.</para>
3382
3383 <para>&notnull;</para>
3384 </section>
3385
3386 <section xml:id="Groupmembers-Uncertain" xreflabel="Uncertain">
3387 <title>Uncertain (Identity Uncertain)</title>
3388
3389 <para>A Boolean flag indicating whether the identity of the
3390 individual is tentative. &true; when the individual's identity
3391 is not certain, &false; when certain.</para>
3392
3393 <para>&notnull;</para>
3394 </section>
3395
3396 <section xml:id="Groupmembers-Swelling" xreflabel="Swelling">
3397 <title>Swelling (Perineal Swelling)</title>
3398
3399 <para>One of the following
3400 values to indicate the degree of perineal
3401 swelling: <literal>&gmi_0;</literal>, <literal>&gmi_1_4;</literal>,
3402 <literal>&gmi_1_2;</literal>, <literal>&gmi_3_4;</literal>,
3403 <literal>&gmi_1;</literal>; <literal>&gmi_U;</literal> to
3404 indicate adolescent swelling; or &null; to indicate that
3405 perineal swelling is not applicable or not known. For further
3406 information see the &gcdbh;.</para>
3407 </section>
3408
3409 </section>
3410
3411 <section xml:id="GROUPS" xreflabel="GROUPS">
3412 <title>GROUPS (Group Composition Surveys)</title>
3413
3414 <para>The data in GROUPS is the result of an automated analysis
3415 called <wordasword>smearing</wordasword> which spreads the group
3416 composition survey results over larger time intervals.
3417 GROUPMEMBERS contains one row for every time interval over which
3418 is automatically analyzed.</para>
3419
3420 <caution>
3421 <para>At present there is extremely limited automated group
3422 composition analysis and the GROUPS table contains one row per
3423 <xref linkend="RAW_GROUPS"/> row.</para>
3424 </caution>
3425
3426 <para>The group composition membership (a GROUPS row) is related
3427 to behavioral intervals (<xref linkend="INTERVALS"/> rows) based
3428 on the group composition time (the
3429 <xref linkend="RAW_GROUPS"/>.<xref linkend="Raw_Groups-Time"/>
3430 value). -- All intervals with times starting with (inclusive
3431 of) the -- group comp time through the interval (exclusive of)
3432 the -- next group comp time are connected to the group comp.
3433
3434 </para>
3435
3436 <para>Each group composition survey must record the presence of at
3437 least one individual, the individual who has the role of mother in
3438 the follow -- there must be related row on the
3439 <xref linkend="GROUPMEMBERS"/> table with the mother's
3440 <xref linkend="ChimpIDs-AnimID"/> related to the the
3441 <xref linkend="Groupmembers-ChimpID"/> value. This check is
3442 performed upon &transaction; commit when rows are added to the
3443 GROUPS table or when rows are deleted from the
3444 <xref linkend="GROUPMEMBERS"/> table or when rows are inserted or
3445 updated on the <xref linkend="FOLLOWPARTS"/> table or when rows
3446 are updated on the <xref linkend="INTERVALS"/> table, and
3447 performed immediately when a row is updated on the
3448 <xref linkend="GROUPMEMBERS"/> table.<footnote>
3449
3450 <para>The infant and the sibling need not be in the group.</para>
3451
3452 </footnote></para>
3453
3454 <para>Each group composition survey must be related to at least
3455 one follow interval -- there must be at least one related row on
3456 the <xref linkend="INTERVALS"/> table. This check is performed
3457 upon &transaction; commit.</para>
3458
3459 <para>Note that there are some periods of time when group
3460 composition was not collected. There are no rules regarding when
3461 this occurred; the system permits group composition to be missing
3462 no matter the date.<footnote>
3463
3464 <para>The system takes advantage of this; because group
3465 composition is not required the group composition can be
3466 uploaded independently, after upload of the follow related
3467 data.</para>
3468
3469 </footnote>
3470 </para>
3471
3472 <tip>
3473 <para>Given the data integrity rules and their manner of
3474 enforcement group composition survey data must be added to the
3475 database within a single transaction is as follows: Create a
3476 GROUPS row and then those related <xref linkend="GROUPMEMBERS"/>
3477 rows required to satisfy the data integrity requirements, update
3478 the related <xref linkend="INTERVALS"/> rows with the new
3479 <xref linkend="Groups-GID"/> value, then relate the group
3480 composition survey data to a follow either by updating (a)
3481 previously created <xref linkend="INTERVALS"/> row(s) inserted
3482 with a &null;
3483 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-GID"/>
3484 value or create new <xref linkend="INTERVALS"/> row(s) with the
3485 <xref linkend="Groups-GID"/> value of the new GROUPS row.</para>
3486 </tip>
3487
3488 <section xml:id="Groups-GID" xreflabel="GID">
3489 <title>GID (Group Survey Identifier)</title>
3490
3491 <para>A unique integer identifying the group composition survey.
3492 &autoid;</para>
3493 </section>
3494
3495 </section>
3496
3497 <section xml:id="RAW_GROUPMEMBERS" xreflabel="RAW_GROUPMEMBERS">
3498 <title>RAW_GROUPMEMBERS (Raw Data on Individuals Found in Group
3499 Composition Surveys)</title>
3500 <titleabbrev>RAW_GROUPMEMBERS (Raw Data on Individuals in Group
3501 Composition Surveys)</titleabbrev>
3502
3503 <para>RAW_GROUPMEMBERS contains one row for each individual found to
3504 be a member of the surveyed group for each group composition
3505 survey.</para>
3506
3507 <note>
3508 <para>The data in RAW_GROUPMEMBERS is interpreted
3509 and <quote>smeared</quote> into the
3510 <xref linkend="GROUPMEMBERS"/> table, which provides a more
3511 direct link between the follow intervals and the group
3512 composition data. <remark>However, although the
3513 RAW_GROUPMEMBERS data is copied into the
3514 <xref linkend="GROUPMEMBERS"/> table, any sort of intelligent
3515 smearing is not yet implemented.</remark></para>
3516 </note>
3517
3518 <warning>
3519 <para>Almost none of the data validation checks described in this
3520 section are implemented. They are all subject to change.</para>
3521 </warning>
3522
3523 <!-- unimplimented, untested -->
3524 <!-- But implimented on groups, the wrong place, so things are ok. -->
3525 <para>An individual can be recorded present in a group at most
3526 once -- the combination of <xref linkend="Raw_Groupmembers-RGID"/> and
3527 the related
3528 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-AnimID"/> must
3529 be unique.</para>
3530
3531 <note>
3532 <para>See the <xref linkend="GROUPMEMBERS"/> for information
3533 regarding when mothers are expected to be present in a group
3534 composition with their young offspring.</para>
3535 </note>
3536
3537 <!-- Old group comp rules. Not sure why they were here and in GROUPMEMBERS,
3538 - but they were so we'll leave them for now until the group compostion
3539 - stuff gets a through review.
3540
3541 <para>When an individual who is less than &gmi_min_alone_age; old,
3542 who has a known biological mother (who has a
3543 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-MomID"/>
3544 which is not &null;), who is in the study population, is present
3545 in the group composition then some <quote>mother</quote>, whether
3546 biological or an adoptive parent who adopted on or before the date
3547 of the follow, must also be present in the group - - must also have
3548 a row in RAW_GROUPMEMBERS. When there is no known biological mother
3549 and an individual less than &gmi_min_alone_age; old is present in
3550 the group composition, and there is one or more adoptive parents
3551 with adoption date(s) on or after the date of the follow, then at
3552 least one of the adoptive parents must also be present in the
3553 group. When the biological mother is unknown and there are no
3554 known adoptive parents then there are no requirements regarding
3555 presence of a parent. These checks are performed immediately upon
3556 deletion of <xref linkend="ADOPTIONS"/> or insert or update of
3557 <xref linkend="FOLLOWS"/> and otherwise on &transaction;
3558 commit.</para>
3559
3560 <para>The reverse is also true; when a <quote>mother</quote> is
3561 present in the group composition then all offspring, biological or
3562 adopted on or before the date of the follow, in the study as of
3563 the date of the follow, less than &gmi_min_alone_age; old must
3564 also be present. There are 2 exceptions to this rule, both
3565 occurring when there is more than one living <quote>mother</quote>
3566 on the date of the follow<footnote>
3567
3568 <para>As would be the case if both the biological mother and the
3569 an adoptive parent were living, or 2 adoptive parents were
3570 living.</para>
3571
3572 </footnote>. The first exception is when the offspring is with
3573 another <quote>mother</quote> - - when the offspring and the
3574 other <quote>mother</quote> have <xref linkend="RAW_GROUPMEMBERS"/>
3575 rows with equal <xref linkend="Raw_Groupmembers-RGID"/> values on the
3576 given date and time. The second exception is when the whereabouts
3577 of at least one <quote>mother</quote> are unknown - - there is no
3578 row in <xref linkend="RAW_GROUPMEMBERS"/> for the given date and time
3579 related to one of the (studied) mothers. These checks are
3580 performed immediately upon deletion of
3581 <xref linkend="ADOPTIONS"/> or insert or update of
3582 <xref linkend="FOLLOWS"/> and otherwise on &transaction;
3583 commit.</para>
3584
3585 <note>
3586 <para>At the various time interval endpoints, the date of
3587 adoption, the date of entry into the study, and the date of
3588 departure from the study, the enforced rules regarding chimps
3589 less than &gmi_min_alone_age; and their real or adoptive mothers
3590 are interpreted in such a way as to loosen the requirements and
3591 exclude the date of the interval endpoint.<footnote>
3592
3593 <para>At any rate this is the intended design. These sorts
3594 of corner cases are always tricky and there may be
3595 bugs.</para>
3596
3597 </footnote> This is because individuals may be born, die, be
3598 adopted, etc., at any point during the day.</para>
3599 </note>
3600 -->
3601 <caution>
3602 <para>Because offspring less than &gmi_min_alone_age; are
3603 sometimes but not always forced to be part of
3604 their <quote>mother's</quote> group composition care must be
3605 taken during analysis to ensure that results are not skewed
3606 based on whether or not the offspring's presence is
3607 forced.</para>
3608 </caution>
3609
3610 <caution>
3611 <para>Presence in the study population is determined by whether
3612 the date of the follow is after an individual's
3613 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Entrydate"/>
3614 and before the individual's
3615 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Departdate"/>.
3616 Because the individual need not be in the study population for
3617 the entire day on the date of entry into the study population
3618 or the date of departure from the study population the above
3619 rules regarding offspring less than &gmi_min_alone_age; old do
3620 not require the mother to be with the offspring on these two
3621 days. Unless care is taken during analysis this censoring
3622 could lead to biased results.</para>
3623 </caution>
3624
3625 <para>The perineal swelling
3626 (<xref linkend="Raw_Groupmembers-Swelling"/>) value must be &null;
3627 unless the individual is female. The perineal swelling may not be
3628 more than <literal>&gmi_0;</literal> unless the individual is at
3629 least &gmi_swelling_min_age; old.</para>
3630
3631 <section xml:id="Raw_Groupmembers-RGMID" xreflabel="RGMID">
3632 <title>RGMID (Raw Group Composition Identifier)</title>
3633
3634 <para>A unique integer identifying the row recording an
3635 individual's presence in the group composition survey.
3636 &autoid;</para>
3637 </section>
3638
3639 <section xml:id="Raw_Groupmembers-RGID" xreflabel="RGID">
3640 <title>RGID (Raw Group Survey Identifier)</title>
3641
3642 <para>A unique integer identifying the group composition survey
3643 during which the individual was found. &notnull;</para>
3644
3645 </section>
3646
3647 <section xml:id="Raw_Groupmembers-ChimpID" xreflabel="ChimpID">
3648 <title>ChimpID (Chimp Virtual Identifier)</title>
3649
3650 <para>The identifier assigned to the group member. The
3651 <xref linkend="ChimpIDs-ChimpID"/> code of the
3652 individual.</para>
3653
3654 <para>&notnull;</para>
3655 </section>
3656
3657 <section xml:id="Raw_Groupmembers-Origin" xreflabel="Origin">
3658 <title>Origin (Originating Data Source)</title>
3659
3660 <para>Code indicating the source that places the individual in
3661 the group. The legal values for this column are defined by the
3662 <xref linkend="GM_ORIGINS"/> support table.</para>
3663
3664 <para>&notnull;</para>
3665 </section>
3666
3667 <section xml:id="Raw_Groupmembers-Uncertain" xreflabel="Uncertain">
3668 <title>Uncertain (Identity Uncertain)</title>
3669
3670 <para>A Boolean flag indicating whether the identity of the
3671 individual is tentative. &true; when the individual's identity
3672 is not certain, &false; when certain.</para>
3673
3674 <para>&notnull;</para>
3675 </section>
3676
3677 <section xml:id="Raw_Groupmembers-Swelling" xreflabel="Swelling">
3678 <title>Swelling (Perineal Swelling)</title>
3679
3680 <para>One of the following
3681 values to indicate the degree of perineal
3682 swelling: <literal>&gmi_0;</literal>, <literal>&gmi_1_4;</literal>,
3683 <literal>&gmi_1_2;</literal>, <literal>&gmi_3_4;</literal>,
3684 <literal>&gmi_1;</literal>; <literal>&gmi_U;</literal> to
3685 indicate adolescent swelling; or &null; to indicate that
3686 perineal swelling is not applicable or not known. For further
3687 information see the &gcdbh;.</para>
3688 </section>
3689
3690 </section>
3691
3692 <section xml:id="RAW_GROUPS" xreflabel="RAW_GROUPS">
3693 <title>RAW_GROUPS (Raw Data on Group Composition Surveys)</title>
3694
3695 <para>RAW_GROUPS contains one row for every survey of group
3696 composition.</para>
3697
3698 <note>
3699 <para>The data in RAW_GROUPS is interpreted
3700 and <quote>smeared</quote> into the GROUPS table, which provides
3701 a more direct link between the follow intervals and the group
3702 composition data. <remark>However, this is not yet
3703 implemented.</remark></para>
3704 </note>
3705
3706 <warning>
3707 <para>Almost none of the data validation checks described in this
3708 section are implemented. They are all subject to change.</para>
3709 </warning>
3710
3711 <para>Each group composition survey must record the presence of at
3712 least one individual, the individual who has the role of mother in
3713 the follow -- there must be related row on the
3714 <xref linkend="RAW_GROUPMEMBERS"/> table with the mother's
3715 <xref linkend="ChimpIDs-AnimID"/> related to the the
3716 <xref linkend="Raw_Groupmembers-ChimpID"/> value. This check is
3717 performed upon &transaction; commit when rows are added to the
3718 RAW_GROUPS table or when rows are deleted from the
3719 <xref linkend="RAW_GROUPMEMBERS"/> table or when rows are inserted or
3720 updated on the <xref linkend="FOLLOWPARTS"/> table or when rows
3721 are updated on the <xref linkend="INTERVALS"/> table, and
3722 performed immediately when a row is updated on the
3723 <xref linkend="RAW_GROUPMEMBERS"/> table.<footnote>
3724
3725 <para>The infant and the sibling need not be in the group.</para>
3726
3727 </footnote></para>
3728
3729 <para>Each group composition survey must be related to at least
3730 one follow sheet -- there must be at least one related row on
3731 the <xref linkend="SHEETS"/> table. This check is performed
3732 upon &transaction; commit.</para>
3733
3734 <para>The time of the group composition must be unique per follow;
3735 the combination of <xref linkend="Raw_Groups-Time"/> and the
3736 related
3737 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-FollowID"/>
3738 must be unique.</para>
3739
3740 <para>Note that there are some periods of time when group
3741 composition was not collected. There are no rules regarding when
3742 this occurred; the system permits group composition to be missing
3743 no matter the date.<footnote>
3744
3745 <para>The system takes advantage of this; because group
3746 composition is not required the group composition can be
3747 uploaded independently, after upload of the follow related
3748 data.</para>
3749
3750 </footnote>
3751 </para>
3752
3753 <tip>
3754 <para>Given the data integrity rules and their manner of
3755 enforcement group composition survey data must be added to the
3756 database within a single transaction is as follows: Create a
3757 RAW_GROUPS row and then those related <xref linkend="RAW_GROUPMEMBERS"/>
3758 rows required to satisfy the data integrity requirements, update
3759 the related <xref linkend="INTERVALS"/> rows with the new
3760 <xref linkend="Raw_Groups-GID"/> value, then relate the group
3761 composition survey data to a follow either by updating (a)
3762 previously created <xref linkend="INTERVALS"/> row(s) inserted
3763 with a &null;
3764 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-GID"/>
3765 value or create new <xref linkend="INTERVALS"/> row(s) with the
3766 <xref linkend="Raw_Groups-GID"/> value of the new RAW_GROUPS row.</para>
3767 </tip>
3768
3769 <section xml:id="Raw_Groups-RGID" xreflabel="RGID">
3770 <title>RGID (Raw Group Survey Identifier)</title>
3771
3772 <para>A unique integer identifying the group composition survey.
3773 &autoid;</para>
3774 </section>
3775
3776 <section xml:id="Raw_Groups-Time" xreflabel="Time">
3777 <title>Time</title>
3778
3779 <para>The time the group composition was taken &notnull;</para>
3780 </section>
3781
3782 <section xml:id="Raw_Groups-Baboons" xreflabel="Baboons">
3783 <title>Baboons</title>
3784
3785 <para>A Boolean flag indicating whether one or more baboons are
3786 present. This column may be &null; when it is not known whether
3787 a baboon is present.</para>
3788
3789 <warning>
3790 <para>In the data converted from MS Access this column is set
3791 to &false; whenever there is no data. This may or may not
3792 indicate that baboons are absent; analysis may show that this
3793 simply means that the data was not collected. At the time of
3794 this writing the database content has not been updated to
3795 reflect when group composition surveys flagged the presence of
3796 baboons and when they did not.</para>
3797 </warning>
3798 </section>
3799
3800 <section xml:id="Raw_Groups-SheetID" xreflabel="SheetID">
3801 <title>SheetID (Sheet Identifier)</title>
3802
3803 <para>The integer identifying the template sheet on which the
3804 group composition was recorded.</para>
3805
3806 <para>&notnull;</para>
3807 </section>
3808
3809 <section xml:id="Raw_Groups-GID" xreflabel="GID">
3810 <title>GID (Group Identifier)</title>
3811
3812 <para>Integer identifying the process (<quote>smeared</quote>)
3813 group survey analysis row into which the raw group survey data
3814 was incorporated.</para>
3815
3816 <para>When group survey analysis is automated this column will
3817 not allowed to be &null;. In the meantime this column may be
3818 &null; when there is no automated analysis.</para>
3819
3820 </section>
3821
3822
3823 </section>
3824 </section>
3825 </chapter>
3826
3827 <chapter xml:id="Support-Tables">
3828 <title>Support Tables</title>
3829
3830 <para>The system's support tables, sometimes
3831 called <wordasword>lookup tables</wordasword>, describe the
3832 vocabulary of the system's coded data. As such, the content of
3833 these tables defines how the system is used and so it is important
3834 to understand the content of these tables.</para>
3835
3836 <para>Each of the support tables has a column used as a key, which
3837 contains the validated vocabulary, and a column which describes the
3838 key, the <literal>Descr</literal> column. The name of the key
3839 column is chosen to describe it's content.
3840 The <literal>Descr</literal> column always has the same name. It
3841 contains a short textual description of the vocabulary item
3842 represented by the row.</para>
3843
3844 <para>The Gombe-MI system strives, as much as possible, to have the
3845 semantics of the data be encoded in support tables instead of in
3846 logic embedded within the system. In those cases where certain
3847 values have meaning that is encoded in the system's logic this is
3848 noted in each support table's <quote>Special Values</quote> section.
3849 Special values are of two kinds: values that have meaning to the
3850 system as a whole and values that are coded within the data upload
3851 process which transforms the notation used in the field into the
3852 codes and structure of the Gombe-MI system.</para>
3853
3854 <section xml:id="demography_support_tables">
3855 <title>&demography_section; Support Tables</title>
3856
3857 <section xml:id="BDDISTS" xreflabel="BDDISTS">
3858 <title>BDDISTS (Birth Date Probability Distributions)</title>
3859
3860 <para>BDDISTS contains one row for every code representing a
3861 probability distribution pertinent to birth date.</para>
3862
3863 <section xml:id="BDDist-Key" xreflabel="BDDist">
3864 <title xml:id="BDDists-BDDist" xreflabel="BDDist">Key:
3865 BDDist</title>
3866
3867 <para>The BDDISTS table is keyed by the BDDist column.</para>
3868 </section>
3869
3870 <section xml:id="BDDists-Special-Values">
3871 <title>Special Values</title>
3872
3873 <para>None.</para>
3874 </section>
3875 </section>
3876
3877 <section xml:id="ENTRYTYPES" xreflabel="ENTRYTYPES">
3878 <title>ENTRYTYPES (Entrytype codes)</title>
3879
3880 <para>ENTRYTYPES contains one row per chimpanzee entrytype.</para>
3881
3882 <section xml:id="Entrytypes-Key" xreflabel="Entrytype">
3883 <title xml:id="Entrytypes-Entrytype" xreflabel="Entrytype">Key:
3884 Entrytype</title>
3885
3886 <para>The ENTRYTYPES table is keyed by the Entrytype column.</para>
3887 </section>
3888
3889 <section xml:id="Entrytypes-Special-Values">
3890 <title>Special Values</title>
3891
3892 <para>None.</para>
3893 </section>
3894 </section>
3895
3896 <section xml:id="DEPARTTYPES" xreflabel="DEPARTTYPES">
3897 <title>DEPARTTYPES (Departtype codes)</title>
3898
3899 <para>DEPARTTYPES contains one row per chimpanzee departtype.</para>
3900
3901 <section xml:id="Departtypes-Key" xreflabel="Departtype">
3902 <title xml:id="Departtypes-Departtype"
3903 xreflabel="Departtype">Key: Departtype</title>
3904
3905 <para>The DEPARTTYPES table is keyed by the Departtype column.</para>
3906 </section>
3907
3908 <section xml:id="Departtypes-Final" xreflabel="Final">
3909 <title>Final (Departure is Final)</title>
3910
3911 <para>A Boolean value indicating whether or not there is a
3912 possibility for further observation of the individual after
3913 departure.</para>
3914
3915 <para>&notnull;</para>
3916 </section>
3917
3918 <section xml:id="Departtypes-Special-Values">
3919 <title>Special Values</title>
3920
3921 <para>None.</para>
3922 </section>
3923 </section>
3924 </section>
3925
3926 <section xml:id="follow_support_tables">
3927 <title>&follow_section; Support Tables</title>
3928
3929 <section xml:id="BEHAVIOR_TRANS" xreflabel="BEHAVIOR_TRANS">
3930 <title>BEHAVIOR_TRANS (Behavior Translation Table)</title>
3931
3932 <para>BEHAVIOR_TRANS contains one row for every behavior code as
3933 written in the field, plus one row for every column representing
3934 an observed behavior. It is used by the
3935 <xref linkend="UPLOAD_BEHAVIORS"/> view to translate the codes
3936 and column markings made in the field to the behavior codes used
3937 within the Gombe-MI system.<footnote>
3938
3939 <para>This provides a degree of flexibility when it comes to
3940 adding to the behaviors observed in the field. In cases where
3941 the field data collector writes behavior codes onto the data
3942 collection sheet there (may) need to be no changes made to the
3943 Gombe-MI system's code to accommodate the new data. In cases
3944 where the field data collector puts check-marks (or similar)
3945 into columns the <xref linkend="UPLOAD_BEHAVIORS"/> view must
3946 have the names of these kinds of columns written into it's
3947 source code and so program changes are required to accommodate
3948 additional columns of this sort.</para>
3949
3950 </footnote></para>
3951
3952 <para>The BEHAVIOR_TRANS table is different from other Gombe-MI
3953 support tables in that its values are used only to support the
3954 behavioral data upload process, the values do not define a
3955 vocabulary used for Gombe-MI database content.</para>
3956
3957 <para>The <xref linkend="Behavior_Trans-GO_Self"/> must be
3958 &null; when <xref linkend="Behavior_Trans-Grooms_Other"/> is
3959 &true; and otherwise must be non-&null;.</para>
3960
3961 <para>The <xref linkend="Behavior_Trans-With_Ma"/> column is
3962 only meaningful when <xref linkend="Behavior_Trans-Play_Val"/>
3963 and <xref linkend="Behavior_Trans-Ride_Val"/> are &null; and
3964 <xref linkend="Behavior_Trans-Grooms_Other"/> and
3965 <xref linkend="Behavior_Trans-Groomed_By"/> are &false;.
3966 Further, it is meaningful only for those rows representing
3967 behavioral codes which occur as values in columns, not for those
3968 rows representing uploaded columns, and has no effect on the
3969 mother's behavioral data.</para>
3970
3971 <section xml:id="Behavior_Trans-Key" xreflabel="Old_Behavior">
3972 <title xml:id="Behavior_Trans-Old_Behavior"
3973 xreflabel="Old_Behavior">Key: Old_Behavior</title>
3974
3975 <para>The BEHAVIOR_TRANS table is keyed by the Old_Behavior
3976 column. This column indicates how the behavior is denoted in
3977 the field on the the data collection sheet. The values in
3978 this column are unusual in that they are of one of two
3979 different sorts. When the field data collector writes one or
3980 more behavior codes onto the data collection sheet each of the
3981 codes written should appear as a Old_Behavior value in a
3982 BEHAVIOR_TRANS row. When the field data collector makes
3983 check-marks or puts similar marks on the data collection sheet
3984 to represent the observation of a behavior then there should
3985 be a row in BEHAVIOR_TRANS with a Old_Behavior value which is
3986 the name of the column into which the check-mark is made. In
3987 this case the column name value in the Old_Behavior column
3988 should be one of the column names of the
3989 <xref linkend="UPLOAD_BEHAVIORS"/> view, written in lower
3990 case.<footnote>
3991
3992 <para>The decision to use the names of the columns of the
3993 <xref linkend="UPLOAD_BEHAVIORS"/> view, in lower case,
3994 rather than an exact match of the names of the columns that
3995 are written on the field data collection sheets is somewhat
3996 arbitrary. The system as written does make it simpler to
3997 maintain the <xref linkend="UPLOAD_BEHAVIORS"/> view since
3998 the programmer can be less aware of the details of data
3999 entry as it occurs in the field.</para>
4000
4001 </footnote></para>
4002 </section>
4003
4004 <section xml:id="Behavior_Trans-New_Behavior" xreflabel="New_Behavior">
4005 <title>New_Behavior (Behavior Code)</title>
4006
4007 <para>Behavior code to be used within Gombe-MI. The legal values
4008 for this column are defined by the <xref linkend="BEHAVIORS"/>
4009 support table.</para>
4010
4011 <para>&notnull;</para>
4012 </section>
4013
4014 <section xml:id="Behavior_Trans-Position_Val" xreflabel="Position_Val">
4015 <title>Position_Val (Default Position Value)</title>
4016
4017 <para>Position code to be used when the uploaded row contains
4018 no indication of what position within the canopy is associated
4019 with the behavior. The legal values for this column are
4020 defined by the <xref linkend="POSITIONS"/> support
4021 table.</para>
4022
4023 <para>This value must be &null; when a position value is not
4024 required by the behavior.</para>
4025 </section>
4026
4027 <section xml:id="Behavior_Trans-Uncertain" xreflabel="Uncertain">
4028 <title>Uncertain</title>
4029
4030 <para>A Boolean value indicating whether behavioral
4031 events deriving from the given old behavior code should always
4032 be denoted uncertain
4033 (<xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>).</para>
4034
4035 <para>&notnull;</para>
4036 </section>
4037
4038 <section xml:id="Behavior_Trans-Grooms_Other" xreflabel="Grooms_Other">
4039 <title>Grooms_Other</title>
4040
4041 <para>A Boolean value indicating whether another uploaded column
4042 contains the chimpids (animids) of individuals groomed by the
4043 focal. The actual referenced chimpid containing column and the
4044 treatment of its content is determined by the
4045 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4046 </section>
4047
4048 <section xml:id="Behavior_Trans-GO_Self" xreflabel="GO_Self">
4049 <title>GO_Self (Grooms Other indicates Self-grooming)</title>
4050
4051 <para>A Boolean value indicating whether self-grooming is
4052 denoted by having the focal's own chimpid listed along with
4053 the other individuals the focal is grooming. A value of
4054 &true; indicates that self-grooming is denoted by listing the
4055 focal's chimpid along with the other groomed individuals. A
4056 value of &false; indicates that self-grooming is not denoted
4057 in this fashion.</para>
4058
4059 <para>This value may be &null;. See above.</para>
4060 </section>
4061
4062 <section xml:id="Behavior_Trans-Groomed_By" xreflabel="Grooms_By">
4063 <title>Grooms_By</title>
4064
4065 <para>A Boolean value indicating whether another uploaded column
4066 contains the chimpids (animids) of individuals who groomed the
4067 focal. The actual referenced chimpid containing column and the
4068 treatment of its content is determined by the
4069 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4070 </section>
4071
4072 <section xml:id="Behavior_Trans-Play_Val" xreflabel="Play_Val">
4073 <title>Play_Val (Default Play Value)</title>
4074
4075 <para>Play code to be used when the uploaded row contains no
4076 indication of what play code is associated with the behavior.
4077 The legal values for this column are defined by the
4078 <xref linkend="PLAY_TYPES"/> support table.</para>
4079
4080 <para>When this value is not &null; another uploaded column
4081 contains the chimpids (animids) of individuals who played with the
4082 focal. The actual referenced chimpid containing column and the
4083 treatment of its content is determined by the
4084 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4085
4086 <para>This value must be &null; when a play value is not
4087 required/when the behavior is not a play behavior.</para>
4088 </section>
4089
4090 <section xml:id="Behavior_Trans-Rest_Val" xreflabel="Rest_Val">
4091 <title>Rest_Val (Default Resting Posture Value)</title>
4092
4093 <para>Resting posture code to be used when the uploaded row
4094 contains no indication of what resting posture code is
4095 associated with the behavior. The legal values for this
4096 column are defined by the <xref linkend="RESTING_POSTURES"/>
4097 support table.</para>
4098
4099 <para>This value must be &null; when a resting value is not
4100 required/when the behavior is not a resting behavior.</para>
4101 </section>
4102
4103 <section xml:id="Behavior_Trans-Ride_Val" xreflabel="Ride_Val">
4104 <title>Ride_Val (Default Riding Posture Value)</title>
4105
4106 <para>Riding posture code to be used when the uploaded row
4107 contains no indication of what riding posture code is
4108 associated with the behavior. The legal values for this
4109 column are defined by the <xref linkend="RIDING_POSTURES"/>
4110 support table.</para>
4111
4112 <para>This value must be &null; when a riding value is not
4113 required/when the behavior is not a riding behavior.</para>
4114 </section>
4115
4116 <section xml:id="Behavior_Trans-Vocalization_Val"
4117 xreflabel="Vocalization_Val">
4118 <title>Vocalization_Val (Default Vocalization Value)</title>
4119
4120 <para>Vocalization code to be used when the uploaded row
4121 contains no indication of what vocalization code is associated
4122 with the behavior. The legal values for this column are
4123 defined by the <xref linkend="RIDING_POSTURES"/> support
4124 table.</para>
4125
4126 <para>This value must be &null; when a vocalization value is
4127 not required/when the behavior is not a vocalization
4128 behavior.</para>
4129 </section>
4130
4131 <section xml:id="Behavior_Trans-Eats" xreflabel="Eats">
4132 <title>Eats</title>
4133
4134 <para>A Boolean value indicating whether another pair of
4135 uploaded columns contains the food parts and food kinds
4136 detailing the food eaten by the focal. The actual referenced
4137 columns containing food detail and the treatment of its
4138 content is determined by the
4139 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4140 </section>
4141
4142 <section xml:id="Behavior_Trans-Fished" xreflabel="Fished">
4143 <title>Fished</title>
4144
4145 <para>A Boolean value indicating whether another pair of
4146 uploaded columns contains the food parts and food kinds
4147 detailing the food fished for by the focal. The actual referenced
4148 columns containing food detail and the treatment of its
4149 content is determined by the
4150 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4151 </section>
4152
4153 <section xml:id="Behavior_Trans-Fishpart_Val" xreflabel="Fishpart_Val">
4154 <title>Fishpart_Val (Default Fishpart Value)</title>
4155
4156 <para>Default Foodpart code to be used when the uploaded row
4157 contains no indication of what foodpart code is
4158 associated with the fishing behavior. The legal values for this
4159 column are defined by the <xref linkend="FOODPARTS"/>
4160 support table.</para>
4161
4162 <para>This value must be &null; when a foodpart is not
4163 required/when the behavior is not a fishing behavior.</para>
4164 </section>
4165
4166 <section xml:id="Behavior_Trans-Fishkind_Val" xreflabel="Fishkind_Val">
4167 <title>Fishkind_Val (Default Fishkind Value)</title>
4168
4169 <para>Default Foodkind code to be used when the uploaded row
4170 contains no indication of what foodkind code is
4171 associated with the fishing behavior. The legal values for this
4172 column are defined by the <xref linkend="FOODKINDS"/>
4173 support table.</para>
4174
4175 <para>This value must be &null; when a foodpart is not
4176 required/when the behavior is not a fishing behavior.</para>
4177 </section>
4178
4179 <section xml:id="Behavior_Trans-Inf_Allowed" xreflabel="Inf_Allowed">
4180 <title>Inf_Allowed (Is the Infant Allowed to have this
4181 behavior code)</title>
4182
4183 <para>A Boolean value indicating whether or not the infant is
4184 allowed to have this behavior code written into the
4185 <xref linkend="Upload_Behaviors-Inf_Behavior"/> column. A
4186 value of &true; indicates the infant is allowed to have the
4187 behavior code. A value of &false; indicates the infant is not
4188 allowed to have the behavior code. &notnull;</para>
4189
4190 <caution>
4191 <para>Do not rely on this column as a means of preventing
4192 the database from recording certain infant behaviors. The
4193 <xref linkend="BEHAVIORS"/> table should be used for that
4194 purpose. This column serves only to help ensure that
4195 uploaded data is not misinterpreted when transformed into
4196 database content.</para>
4197 </caution>
4198 </section>
4199
4200 <section xml:id="Behavior_Trans-With_Ma" xreflabel="With_Ma">
4201 <title>With_Ma</title>
4202
4203 <para>A Boolean value indicating whether or not individuals
4204 exhibiting this behavior are doing so in a directed fashion
4205 with the mother. &true; means the mother is a social partner,
4206 the <quote>actee</quote>, even though there is no other
4207 indication of this. &false; means the mother is not
4208 automatically made a social partner. &notnull;</para>
4209 </section>
4210
4211 <section xml:id="Behavior_Trans-Dups" xreflabel="Dups">
4212 <title>Dups</title>
4213
4214 <para>A Boolean value indicating whether the behavior is
4215 recorded twice on the data collection sheet, once for each
4216 focal.</para>
4217
4218 <para>For further
4219 information <link linkend="UB_Duplicate_Control">see
4220 above</link>.</para>
4221 </section>
4222
4223 <section xml:id="Behavior_Trans-Special-Values">
4224 <title>Special Values</title>
4225
4226 <para>In order to process the indicated columns the
4227 <xref linkend="UPLOAD_BEHAVIORS"/> view requires that
4228 BEHAVIOR_TRANS contain rows for the following
4229 <xref linkend="Behavior_Trans-Old_Behavior"/> values:</para>
4230
4231 <itemizedlist>
4232 <listitem><para><literal>&gmi_ma_foodpart;</literal></para></listitem>
4233 <listitem><para><literal>&gmi_ma_fishpart;</literal></para></listitem>
4234 <listitem><para><literal>&gmi_ma_grooming;</literal></para></listitem>
4235 <listitem><para><literal>&gmi_ma_groomed_by;</literal></para></listitem>
4236 <listitem><para><literal>&gmi_ma_play;</literal></para></listitem>
4237 <listitem><para><literal>&gmi_ma_voc;</literal></para></listitem>
4238 <listitem><para><literal>&gmi_inf_foodpart;</literal></para></listitem>
4239 <listitem><para><literal>&gmi_inf_fishpart;</literal></para></listitem>
4240 <listitem><para><literal>&gmi_inf_nurse;</literal></para></listitem>
4241 <listitem><para><literal>&gmi_inf_travel;</literal></para></listitem>
4242 <listitem><para><literal>&gmi_inf_eat;</literal></para></listitem>
4243 <listitem><para><literal>&gmi_inf_solitary_play;</literal></para></listitem>
4244 <listitem><para><literal>&gmi_inf_rest;</literal></para></listitem>
4245 <listitem><para><literal>&gmi_inf_ride_on_belly;</literal></para></listitem>
4246 <listitem><para><literal>&gmi_inf_ride_on_back;</literal></para></listitem>
4247 <listitem><para><literal>&gmi_inf_ride_on_unk;</literal></para></listitem>
4248 <listitem><para><literal>&gmi_inf_dangle;</literal></para></listitem>
4249 <listitem><para><literal>&gmi_inf_rejection;</literal></para></listitem>
4250 <listitem><para><literal>&gmi_inf_touching_another;</literal></para></listitem>
4251 <listitem><para><literal>&gmi_inf_grooming;</literal></para></listitem>
4252 <listitem><para><literal>&gmi_inf_being_groomed;</literal></para></listitem>
4253 <listitem><para><literal>&gmi_inf_social_play;</literal></para></listitem>
4254 <listitem><para><literal>&gmi_inf_display;</literal></para></listitem>
4255 <listitem><para><literal>&gmi_inf_cry;</literal></para></listitem>
4256 <listitem><para><literal>&gmi_inf_voc;</literal></para></listitem>
4257 <listitem><para><literal>&gmi_inf_beg;</literal></para></listitem>
4258 <listitem><para><literal>&gmi_inf_assr;</literal></para></listitem>
4259 <listitem><para><literal>&gmi_inf_sex_related;</literal></para></listitem>
4260 <listitem><para><literal>&gmi_inf_tooluse;</literal></para></listitem>
4261 <listitem><para><literal>&gmi_inf_directaggression;</literal></para></listitem>
4262 <listitem><para><literal>&gmi_devbeh_col;</literal></para></listitem>
4263 <listitem><para><literal>&gmi_sib_foodpart;</literal></para></listitem>
4264 <listitem><para><literal>&gmi_sib_fishpart;</literal></para></listitem>
4265 <listitem><para><literal>&gmi_sib_grooming;</literal></para></listitem>
4266 <listitem><para><literal>&gmi_sib_groomed_by;</literal></para></listitem>
4267 <listitem><para><literal>&gmi_sib_play;</literal></para></listitem>
4268 <listitem><para><literal>&gmi_sib_voc;</literal></para></listitem>
4269 </itemizedlist>
4270
4271 </section>
4272 </section>
4273
4274 <section xml:id="DISTANCE_TRANS" xreflabel="DISTANCE_TRANS">
4275 <title>DISTANCE_TRANS (Distance Translation Table)</title>
4276
4277 <para>DISTANCE_TRANS contains one row for every distance code as
4278 written in the field, plus one row for every column representing
4279 an observed inter-focal distance. It is used by the
4280 <xref linkend="UPLOAD_BEHAVIORS"/> view to translate the codes
4281 and markings in columns which are made in the field to the
4282 distance codes used within the Gombe-MI system.<footnote>
4283
4284 <para>See the above footnote regarding the flexibility
4285 provided by the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
4286
4287 </footnote></para>
4288
4289 <para>The DISTANCE_TRANS table is different from other Gombe-MI
4290 support tables in that its values are used only to support the
4291 behavioral data upload process, the values do not define a
4292 vocabulary used for Gombe-MI database content.</para>
4293
4294 <section xml:id="Distance_Trans-Key" xreflabel="Old_Distance">
4295 <title xml:id="Distance_Trans-Old_Distance"
4296 xreflabel="Old_Distance">Key: Old_Distance</title>
4297
4298 <para>The DISTANCE_TRANS table is keyed by the Old_Distance
4299 column. This column indicates how the distance is denoted in
4300 the field on the the data collection sheet. The values in
4301 this column are unusual in that they are of one of two
4302 different sorts. When the field data collector writes one or
4303 more distance codes onto the data collection sheet each of the
4304 codes written should appear as a Old_Distance value in a
4305 DISTANCE_TRANS row. When the field data collector makes
4306 check-marks or puts similar marks on the data collection sheet
4307 to represent the observation of a distance then there should
4308 be a row in DISTANCE_TRANS with a Old_Distance value which is
4309 the name of the column into which the check-mark is made. In
4310 this case the column name value in the Old_Distance column
4311 should be one of the column names of the
4312 <xref linkend="UPLOAD_BEHAVIORS"/> view, written in lower
4313 case.<footnote>
4314
4315 <para>See the above footnote in the
4316 <xref linkend="BEHAVIOR_TRANS"/> documentation regarding the
4317 design decisions surrounding the use of column names.</para>
4318
4319 </footnote></para>
4320 </section>
4321
4322 <section xml:id="Distance_Trans-New_Distance" xreflabel="New_Distance">
4323 <title>New_Distance (Distance Code)</title>
4324
4325 <para>Distance code to be used within Gombe-MI. The legal values
4326 for this column are defined by the <xref linkend="DISTANCECODES"/>
4327 support table.</para>
4328
4329 <para>&notnull;</para>
4330 </section>
4331
4332 <section xml:id="Distance_Trans-Uncertain" xreflabel="Uncertain">
4333 <title>Uncertain</title>
4334
4335 <para>A Boolean value indicating whether inter-focal distance
4336 measurements deriving from the given old distance code should
4337 always be denoted uncertain
4338 (<xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>).</para>
4339
4340 <para>&notnull;</para>
4341 </section>
4342
4343 <section xml:id="Distance_Trans-Special-Values">
4344 <title>Special Values</title>
4345
4346 <para>In order to process the indicated columns the
4347 <xref linkend="UPLOAD_BEHAVIORS"/> view requires that
4348 DISTANCE_TRANS contain rows for the following
4349 <xref linkend="Distance_Trans-Old_Distance"/> values:</para>
4350
4351 <itemizedlist>
4352 <listitem><para><literal>&gmi_inf_distance_1;</literal></para></listitem>
4353 <listitem><para><literal>&gmi_inf_distance_2;</literal></para></listitem>
4354 <listitem><para><literal>&gmi_inf_distance_3;</literal></para></listitem>
4355 <listitem><para><literal>&gmi_inf_distance_4;</literal></para></listitem>
4356 <listitem><para><literal>&gmi_inf_distance_5;</literal></para></listitem>
4357 <listitem><para><literal>&gmi_inf_distance_over_5m;</literal></para></listitem>
4358 </itemizedlist>
4359
4360 </section>
4361 </section>
4362
4363 <section xml:id="FOLLOWROLES" xreflabel="FOLLOWROLES">
4364 <title>FOLLOWROLES (Roles of Follow Participants)</title>
4365
4366 <para>FOLLOWROLES contains one row for every possible role of the
4367 individuals which are followed. E.g. Mother, Infant, Sibling,
4368 Twin1<footnote>
4369
4370 <para>Note that the system does not require a separate
4371 <xref linkend="FOLLOWROLES"/> row for, e.g., twins since when
4372 there are multiple infants or siblings they must have the same
4373 birth date.</para>
4374
4375 </footnote>, etc.</para>
4376
4377 <section xml:id="Followroles-Key" xreflabel="Role">
4378 <title xml:id="Followroles-Role" xreflabel="Role">Key:
4379 Role</title>
4380
4381 <para>The FOLLOWROLES table is keyed by the Role column.</para>
4382 </section>
4383
4384 <section xml:id="Followroles-Function" xreflabel="Function">
4385 <title>Function (Biological Function)</title>
4386
4387 <para>The biological relationship of the role. Must be one of:</para>
4388
4389 <variablelist>
4390 <varlistentry>
4391 <term><literal>&gmi_mom;</literal></term>
4392 <listitem><para>Mother</para></listitem>
4393 </varlistentry>
4394
4395 <varlistentry>
4396 <term><literal>&gmi_infant;</literal></term>
4397 <listitem><para>Infant</para></listitem>
4398 </varlistentry>
4399
4400 <varlistentry>
4401 <term><literal>&gmi_sib;</literal></term>
4402 <listitem><para>Sibling</para></listitem>
4403 </varlistentry>
4404 </variablelist>
4405
4406 <para>The Function value cannot be changed. &notnull;</para>
4407 </section>
4408
4409 <section xml:id="Followroles-Special-Values">
4410 <title>Special Values</title>
4411
4412 <para>The Role may not have a value
4413 of <literal>&gmi_nonfocal;</literal>.
4414 The <literal>&gmi_nonfocal;</literal> code has the reserved
4415 meaning <quote>Not a focal in the follow</quote>.</para>
4416
4417 <para>The Role
4418 values <literal>&gmi_mom_role;</literal>,
4419 <literal>&gmi_infant_role;</literal>,
4420 and <literal>&gmi_sib_role;</literal> have special meaning to
4421 the <xref linkend="UPLOAD_BEHAVIORS"/> view. See the
4422 documentation of the view for more information.</para>
4423 </section>
4424 </section>
4425
4426 <section xml:id="FOLLOWTYPES" xreflabel="FOLLOWTYPES">
4427 <title>FOLLOWTYPES (Follow Data Entry Sheet Types)</title>
4428
4429 <para>FOLLOWTYPES contains one row for every type of data entry
4430 sheet (template) used in the field. For further information see
4431 the <code>templates.xlsx</code> spreadsheet and related
4432 documentation.</para>
4433
4434 <para>The Descr column is the appropriate place to put notes on the
4435 data collection protocol(s) or template sheets used with the given
4436 type of follow, as well as the list of templates which make up
4437 the type.<footnote>
4438
4439 <para>It might or might not make sense to have a separate
4440 textual column which lists the templates that make up the
4441 type.</para>
4442
4443 </footnote></para>
4444
4445 <section xml:id="Followtypes-Key" xreflabel="Type">
4446 <title xml:id="Followtypes-Type" xreflabel="Type">Key: Type</title>
4447
4448 <para>The FOLLOWTYPES table is keyed by the Type column.</para>
4449 </section>
4450
4451 <section xml:id="Followtypes-Implied_Behavior"
4452 xreflabel="Implied_Behavior">
4453 <title>Implied_Behavior</title>
4454
4455 <para>A Boolean value indicating whether a behavior code is
4456 always recorded on the sheet, for particular
4457 mother/infant/sibling behaviors, or whether the behavior
4458 code is implied by the presence of data in another column.
4459 A value of &true; means that the behavior code is implied by
4460 the presence of data in certain columns. A value of &false;
4461 means that behavior codes are always present in the data for
4462 these columns.</para>
4463
4464 <para>For further information on which behaviors and which
4465 columns are affected by the Implied_Behavior value
4466 see <link linkend="UB_Implied_Behaviors">the
4467 documentation</link> of the
4468 <xref linkend="UPLOAD_BEHAVIORS"/> view.</para>
4469
4470 <para>&notnull;</para>
4471 </section>
4472
4473 <section xml:id="Followtypes-boolean-columns">
4474 <title>The Boolean Columns of FOLLOWTYPES</title>
4475
4476 <para>All columns but <xref linkend="Followtypes-Type"/>,
4477 <xref linkend="Followtypes-Implied_Behavior"/>, and
4478 Descr are Boolean.<footnote>
4479
4480 <para>These Boolean columns are documented in a table,
4481 differently from the documentation of other columns in this
4482 document, due to their substantial similarity.</para>
4483
4484 </footnote>True indicates that the data represented by the
4485 column name was collected using the data collection protocol
4486 associated with the data entry sheets of the given follow type.
4487 Note that the data may have been collected either as a column or
4488 in notes.</para>
4489
4490 <informaltable frame="none">
4491
4492 <tgroup cols="2" align="left" colsep="1" rowsep="1">
4493 <thead>
4494 <row>
4495 <entry>Column Name</entry>
4496 <entry>Column Heading on Template</entry>
4497 </row>
4498 </thead>
4499
4500 <tbody>
4501 <row xml:id="Followtypes-Researcher"
4502 xreflabel="Researcher">
4503 <entry>Researcher</entry>
4504 <entry>Mchunguzi (Researcher)</entry>
4505 </row>
4506 <row xml:id="Followtypes-Date"
4507 xreflabel="Date">
4508 <entry>Date</entry>
4509 <entry>Tarehe (Date)</entry>
4510 </row>
4511 <row xml:id="Followtypes-Page"
4512 xreflabel="Page">
4513 <entry>Page</entry>
4514 <entry>Na. Ya Karatasi (Page)</entry>
4515 </row>
4516 <row xml:id="Followtypes-InOutOfCamp"
4517 xreflabel="InOutOfCamp">
4518 <entry>InOutOfCamp</entry>
4519 <entry>Kambini/Porini (In Camp/Out of Camp)</entry>
4520 </row>
4521 <row xml:id="Followtypes-Focals"
4522 xreflabel="Focals">
4523 <entry>Focals</entry>
4524 <entry>Sokwe (Focals)</entry>
4525 </row>
4526 <row xml:id="Followtypes-Time"
4527 xreflabel="Time">
4528 <entry>Time</entry>
4529 <entry>Muda/Saa (Time)</entry>
4530 </row>
4531 <row xml:id="Followtypes-Tape"
4532 xreflabel="Tape">
4533 <entry>Tape</entry>
4534 <entry>Tepu (Tape)</entry>
4535 </row>
4536 <row xml:id="Followtypes-BadObs"
4537 xreflabel="BadObs">
4538 <entry>BadObs</entry>
4539 <entry>Uchunguzi Mbaya (Bad obs)</entry>
4540 </row>
4541 <row xml:id="Followtypes-Rain"
4542 xreflabel="Rain">
4543 <entry>Rain</entry>
4544 <entry>Mvua (Rain)</entry>
4545 </row>
4546 <row xml:id="Followtypes-MomBehavior"
4547 xreflabel="MomBehavior">
4548 <entry>MomBehavior</entry>
4549 <entry>Vitendo vya Mama (behavior)</entry>
4550 </row>
4551 <row xml:id="Followtypes-MomGroomingPlay"
4552 xreflabel="MomGroomingPlay">
4553 <entry>MomGroomingPlay</entry>
4554 <entry>Grooming/Play</entry>
4555 </row>
4556 <row xml:id="Followtypes-MomGroomed"
4557 xreflabel="MomGroomed">
4558 <entry>MomGroomed</entry>
4559 <entry>Groomed</entry>
4560 </row>
4561 <row xml:id="Followtypes-MomVocalization"
4562 xreflabel="MomVocalization">
4563 <entry>MomVocalization</entry>
4564 <entry>Vocalization</entry>
4565 </row>
4566 <row xml:id="Followtypes-BadObsInfant"
4567 xreflabel="BadObsInfant">
4568 <entry>BadObsInfant</entry>
4569 <entry>Uchunguzi Mbaya (Bad Obs - Infant)</entry>
4570 </row>
4571 <row xml:id="Followtypes-Nurse"
4572 xreflabel="Nurse">
4573 <entry>Nurse</entry>
4574 <entry>Nyonya (Nurse)</entry>
4575 </row>
4576 <row xml:id="Followtypes-Travel"
4577 xreflabel="Travel">
4578 <entry>Travel</entry>
4579 <entry>Tembea (Travel)</entry>
4580 </row>
4581 <row xml:id="Followtypes-Eat"
4582 xreflabel="Eat">
4583 <entry>Eat</entry>
4584 <entry>Kula (Eat)</entry>
4585 </row>
4586 <row xml:id="Followtypes-SolitaryPlay"
4587 xreflabel="SolitaryPlay">
4588 <entry>SolitaryPlay</entry>
4589 <entry>Cheza Mwenyewe (Solitary play)</entry>
4590 </row>
4591 <row xml:id="Followtypes-RestWatch"
4592 xreflabel="RestWatch">
4593 <entry>RestWatch</entry>
4594 <entry>Pumzika/Tazama (Rest/Watch)</entry>
4595 </row>
4596 <row xml:id="Followtypes-MomDistance"
4597 xreflabel="MomDistance">
4598 <entry>MomDistance</entry>
4599 <entry>Gusana na Mama (Distance Touching (1))</entry>
4600 </row>
4601 <row xml:id="Followtypes-MomWithinArmsReach"
4602 xreflabel="MomWithinArmsReach">
4603 <entry>MomWithinArmsReach</entry>
4604 <entry>Distance w/in arms reach (2)</entry>
4605 </row>
4606 <row xml:id="Followtypes-Mom0to5"
4607 xreflabel="Mom0to5">
4608 <entry>Mom0to5</entry>
4609 <entry>Mita 0-5 (Distance 0-5m (3))</entry>
4610 </row>
4611 <row xml:id="Followtypes-Mom5plus"
4612 xreflabel="Mom5plus">
4613 <entry>Mom5plus</entry>
4614 <entry>Zaida ya m 5 (Distance >5m)</entry>
4615 </row>
4616 <row xml:id="Followtypes-Mom5to15"
4617 xreflabel="Mom5to15">
4618 <entry>Mom5to15</entry>
4619 <entry>Mita 5-15 (Distance 5-15m (4))</entry>
4620 </row>
4621 <row xml:id="Followtypes-Mom15plus"
4622 xreflabel="Mom15plus">
4623 <entry>Mom15plus</entry>
4624 <entry>Mita 15 na zaidi (Distance >15m (5))</entry>
4625 </row>
4626 <row xml:id="Followtypes-RideVentral"
4627 xreflabel="RideVentral">
4628 <entry>RideVentral</entry>
4629 <entry>Bebwa Tumboni (Ride Ventral)</entry>
4630 </row>
4631 <row xml:id="Followtypes-RideDorsal"
4632 xreflabel="RideDorsal">
4633 <entry>RideDorsal</entry>
4634 <entry>Bebwa Mgongoni (Ride Dorsal)</entry>
4635 </row>
4636 <row xml:id="Followtypes-Dangle"
4637 xreflabel="Dangle">
4638 <entry>Dangle</entry>
4639 <entry>Dangle</entry>
4640 </row>
4641 <row xml:id="Followtypes-RejectTravel"
4642 xreflabel="RejectTravel">
4643 <entry>RejectTravel</entry>
4644 <entry>Kataliwa (Reject [travel])</entry>
4645 </row>
4646 <row xml:id="Followtypes-TouchingAnother"
4647 xreflabel="TouchingAnother">
4648 <entry>TouchingAnother</entry>
4649 <entry>Gusana na mwengine (Touching Another)</entry>
4650 </row>
4651 <row xml:id="Followtypes-InfantGrooming"
4652 xreflabel="InfantGrooming">
4653 <entry>InfantGrooming</entry>
4654 <entry>Kwatua (Grooming)</entry>
4655 </row>
4656 <row xml:id="Followtypes-InfantGroomed"
4657 xreflabel="InfantGroomed">
4658 <entry>InfantGroomed</entry>
4659 <entry>Kwatulia na (Groomed)</entry>
4660 </row>
4661 <row xml:id="InfantPlay"
4662 xreflabel="InfantPlay">
4663 <entry>InfantPlay</entry>
4664 <entry>Cheza (Social Play)</entry>
4665 </row>
4666 <row xml:id="InfantDisplay"
4667 xreflabel="InfantDisplay">
4668 <entry>InfantDisplay</entry>
4669 <entry>Jijenga (Display)</entry>
4670 </row>
4671 <row xml:id="Followtypes-InfantCry"
4672 xreflabel="InfantCry">
4673 <entry>InfantCry</entry>
4674 <entry>Lia lia (Cry)</entry>
4675 </row>
4676 <row xml:id="Followtypes-InfantVocal"
4677 xreflabel="InfantVocal">
4678 <entry>InfantVocal</entry>
4679 <entry>Sauti nyingine (Inf Voc/Other vocal)</entry>
4680 </row>
4681 <row xml:id="Followtypes-InfantBeg"
4682 xreflabel="InfantBeg">
4683 <entry>InfantBeg</entry>
4684 <entry>Omba (Beg)</entry>
4685 </row>
4686 <row xml:id="Followtypes-InfantASSR"
4687 xreflabel="InfantASSR">
4688 <entry>InfantASSR</entry>
4689 <entry>UUJB (ASSR)</entry>
4690 </row>
4691 <row xml:id="Followtypes-InfantTwinDistance"
4692 xreflabel="InfantTwinDistance">
4693 <entry>InfantTwinDistance</entry>
4694 <entry>Umbali (Distance between infants)</entry>
4695 </row>
4696 <row xml:id="Followtypes-SiblingPresent"
4697 xreflabel="SiblingPresent">
4698 <entry>SiblingPresent</entry>
4699 <entry>Uchunguzi mbaya</entry>
4700 </row>
4701 <row xml:id="Followtypes-SiblingBehavior"
4702 xreflabel="SiblingBehavior">
4703 <entry>SiblingBehavior</entry>
4704 <entry>Behavior</entry>
4705 </row>
4706 <row xml:id="Followtypes-SiblingMotherDistance"
4707 xreflabel="SiblingMotherDistance">
4708 <entry>SiblingMotherDistance</entry>
4709 <entry>Distance to Mother</entry>
4710 </row>
4711 <row xml:id="Followtypes-SiblingVocalization"
4712 xreflabel="SiblingVocalization">
4713 <entry>SiblingVocalization</entry>
4714 <entry>Vocalization</entry>
4715 </row>
4716 <row xml:id="Followtypes-SiblingPlay"
4717 xreflabel="SiblingPlay">
4718 <entry>SiblingPlay</entry>
4719 <entry>Play</entry>
4720 </row>
4721 <row xml:id="Followtypes-SiblingGrooming"
4722 xreflabel="SiblingGrooming">
4723 <entry>SiblingGrooming</entry>
4724 <entry>Grooming</entry>
4725 </row>
4726 <row xml:id="Followtypes-SiblingGroomed"
4727 xreflabel="SiblingGroomed">
4728 <entry>SiblingGroomed</entry>
4729 <entry>Groomed</entry>
4730 </row>
4731 <row xml:id="Followtypes-SiblingInfantDistance"
4732 xreflabel="SiblingInfantDistance">
4733 <entry>SiblingInfantDistance</entry>
4734 <entry>Distance to Infant</entry>
4735 </row>
4736 <row xml:id="Followtypes-SiblingInfant2Distance"
4737 xreflabel="SiblingInfant2Distance">
4738 <entry>SiblingInfant2Distance</entry>
4739 <entry>Distance to Second Infant</entry>
4740 </row>
4741 <row xml:id="Followtypes-SiblingSiblingDistance"
4742 xreflabel="SiblingSiblingDistance">
4743 <entry>SiblingSiblingDistance</entry>
4744 <entry>Umbali (Distance between siblings)</entry>
4745 </row>
4746 <row xml:id="Followtypes-Comments"
4747 xreflabel="Comments">
4748 <entry>Comments</entry>
4749 <entry>Comments</entry>
4750 </row>
4751 <row xml:id="Followtypes-GroupComp"
4752 xreflabel="GroupComp">
4753 <entry>GroupComp</entry>
4754 <entry>Group Comp</entry>
4755 </row>
4756 </tbody>
4757 </tgroup>
4758 </informaltable>
4759 </section>
4760
4761 <section xml:id="Followtypes-Special-Values">
4762 <title>Special Values</title>
4763
4764 <para>None.</para>
4765 </section>
4766 </section>
4767
4768 <section xml:id="FOODPART_TRANS" xreflabel="FOODPART_TRANS">
4769 <title>FOODPART_TRANS (Food Part Translation Table)</title>
4770
4771 <para>FOODPART_TRANS contains one row for every food part code
4772 as written in the field. It is used by the
4773 <xref linkend="UPLOAD_BEHAVIORS"/> program to translate the
4774 foodpart codes as written in the field to the food part codes
4775 used within the Gombe-MI system.<footnote>
4776
4777 <para>See the above footnote regarding the flexibility
4778 provided by the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
4779
4780 </footnote></para>
4781
4782 <para>The FOODPART_TRANS table is different from other Gombe-MI
4783 support tables in that its values are used only to support the
4784 behavioral data upload process, the values do not define a
4785 vocabulary used for Gombe-MI database content.</para>
4786
4787 <section xml:id="Foodpart_Trans-Key" xreflabel="Old_Foodpart">
4788 <title xml:id="Foodpart_Trans-Old_Foodpart"
4789 xreflabel="Mark">Key: Old_Foodpart</title>
4790
4791 <para>The FOODPART_TRANS table is keyed by the Old_Foodpart
4792 column. This column contains the foodpart codes written onto
4793 the data collection sheet in the field.</para>
4794 </section>
4795
4796 <section xml:id="Foodpart_Trans-New_Foodpart" xreflabel="New_Foodpart">
4797 <title>New_Foodpart</title>
4798
4799 <para>Foodpart code to be used within Gombe-MI. The legal values
4800 for this column are defined by the <xref linkend="FOODPARTS"/>
4801 support table.</para>
4802
4803 <para>&notnull;</para>
4804 </section>
4805
4806 <section xml:id="FOODPART_Trans-Special-Values">
4807 <title>Special Values</title>
4808
4809 <para>None</para>
4810
4811 </section>
4812 </section>
4813
4814 <section xml:id="GC_TRANS" xreflabel="GC_TRANS">
4815 <title>GC_TRANS (Group Composition Translation Table)</title>
4816
4817 <para>GC_TRANS contains one row for every mark written in the
4818 field onto the group composition portion of the data
4819 collection sheets, in the cells of the columns which record
4820 chimpanzee or baboon presence. It is used by the
4821 <xref linkend="Upload_GC"/> program to translate the codes and
4822 markings in columns as made in the field to determine how the
4823 information is represented within the Gombe-MI
4824 system.<footnote>
4825
4826 <para>See the above footnote regarding the flexibility
4827 provided by the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
4828
4829 </footnote></para>
4830
4831 <para>The GC_TRANS table is different from other Gombe-MI
4832 support tables in that its values are used only to support the
4833 group composition data upload process, the values do not define
4834 a vocabulary used for Gombe-MI database content.</para>
4835
4836 <para>There can only be a swelling when the individual is in the
4837 group composition -- the <xref linkend="GC_Trans-Swelling"/>
4838 value must be &null; when <xref linkend="GC_Trans-Present"/> is
4839 &false;.</para>
4840
4841 <para>There must be a code indicating where the data came from
4842 when the individual is present, and otherwise there must not --
4843 the <xref linkend="GC_Trans-Origin"/> column cannot be &null;
4844 when <xref linkend="GC_Trans-Present"/> is &true;, and the
4845 <xref linkend="GC_Trans-Origin"/> column must be &null; when
4846 <xref linkend="GC_Trans-Present"/> is &false;.</para>
4847
4848 <section xml:id="GC_Trans-Key" xreflabel="Mark">
4849 <title xml:id="GC_Trans-Mark"
4850 xreflabel="Mark">Key: Mark</title>
4851
4852 <para>The GC_TRANS table is keyed by the Mark column. This
4853 column indicates what marks are made in the cells of the
4854 columns which correspond to chimpanzees. The Mark column may
4855 not be &null;, but may be the empty string.</para>
4856 </section>
4857
4858 <section xml:id="GC_Trans-Present" xreflabel="Present">
4859 <title>Present</title>
4860
4861 <para>A Boolean value indicating whether the designated mark
4862 means the individual should be included in the group
4863 composition -- whether there should be a row on
4864 <xref linkend="RAW_GROUPMEMBERS"/>.</para>
4865
4866 <para>&notnull;</para>
4867 </section>
4868
4869 <section xml:id="GC_Trans-Uncertain" xreflabel="Uncertain">
4870 <title>Uncertain</title>
4871
4872 <para>A Boolean value indicating the
4873 <xref linkend="RAW_GROUPMEMBERS"/>.<xref
4874 linkend="Raw_Groupmembers-Uncertain"/>
4875 value to use when this mark appears on the group comp
4876 sheet.</para>
4877
4878 <para>&notnull;</para>
4879 </section>
4880
4881 <section xml:id="GC_Trans-Swelling" xreflabel="Swelling">
4882 <title>Swelling (Swelling Code)</title>
4883
4884 <para>Swelling value to be stored in the
4885 <xref linkend="RAW_GROUPMEMBERS"/>.<xref
4886 linkend="Raw_Groupmembers-Swelling"/>
4887 when the designated mark is used.</para>
4888
4889 <para>This value may be &null; when the <xref
4890 linkend="RAW_GROUPMEMBERS"/>.<xref
4891 linkend="Raw_Groupmembers-Swelling"/> value is to be NULL.</para>
4892 </section>
4893
4894 <section xml:id="GC_Trans-Origin" xreflabel="Origin">
4895 <title>Origin (Origin Code)</title>
4896
4897 <para>Origin value to be stored in the
4898 <xref linkend="RAW_GROUPMEMBERS"/>.<xref
4899 linkend="Raw_Groupmembers-Origin"/>
4900 when the designated mark is used.</para>
4901
4902 <para>See the <xref linkend="GC_TRANS"/> description above for
4903 when this value may and may not be &null;.</para>
4904 </section>
4905
4906 <section xml:id="GC_Trans-Notes" xreflabel="Notes">
4907 <title>Notes</title>
4908
4909 <para>Notes on the GC_TRANS row and the
4910 <xref linkend="GC_Trans-Mark"/> value. Because it can be hard
4911 to distinguish &null; from the empty string, no characters,
4912 the Notes column is provided. Any notes on the row's
4913 <xref linkend="GC_Trans-Mark"/> value or anything else related
4914 to the row may be be stored in this column.</para>
4915
4916 <para>This value may be &null; when notes are not needed.</para>
4917 </section>
4918
4919 <section xml:id="GC_Trans-Special-Values">
4920 <title>Special Values</title>
4921
4922 <para>None</para>
4923
4924 </section>
4925 </section>
4926
4927 <section xml:id="PEOPLE" xreflabel="PEOPLE">
4928 <title>PEOPLE</title>
4929
4930 <para>PEOPLE contains one row for every person involved in data
4931 collection or data entry.</para>
4932
4933 <section xml:id="People-Key" xreflabel="Person">
4934 <title xml:id="People-Person" xreflabel="Person">Key:
4935 Person</title>
4936
4937 <para>The PEOPLE table is keyed by the Person column.</para>
4938 </section>
4939
4940 <section xml:id="People-Special-Values">
4941 <title>Special Values</title>
4942
4943 <para>None.</para>
4944 </section>
4945 </section>
4946
4947 <section xml:id="PLAY_TRANS" xreflabel="PLAY_TRANS">
4948 <title>PLAY_TRANS (Play Translation Table)</title>
4949
4950 <para>PLAY_TRANS contains one row for every play code as
4951 written in the field. It is used by the
4952 <xref linkend="UPLOAD_BEHAVIORS"/> view to translate the codes
4953 written in the field to the play codes used within the
4954 Gombe-MI system.</para>
4955
4956 <para>The PLAY_TRANS table is different from other Gombe-MI
4957 support tables in that it's values are used only to support the
4958 behavioral data upload process, the values do not define a
4959 vocabulary used for Gombe-MI database content.</para>
4960
4961 <section xml:id="Play_Trans-Key" xreflabel="Old_Play">
4962 <title xml:id="Play_Trans-Old_Play"
4963 xreflabel="Old_Play">Key: Old_Play</title>
4964
4965 <para>The PLAY_TRANS table is keyed by the Old_Play
4966 column.</para>
4967 </section>
4968
4969 <section xml:id="Play_Trans-New_Play" xreflabel="New_Play">
4970 <title>New_Play (Play Code)</title>
4971
4972 <para>Play code to be used within Gombe-MI. The legal values
4973 for this column are defined by the <xref linkend="PLAY_TYPES"/>
4974 support table.</para>
4975
4976 <para>&notnull;</para>
4977 </section>
4978
4979 <section xml:id="Play_Trans-Uncertain" xreflabel="Uncertain">
4980 <title>Uncertain</title>
4981
4982 <para>A Boolean value indicating whether play
4983 events deriving from the given old play code should always
4984 be denoted uncertain
4985 (<xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>).</para>
4986
4987 <para>&notnull;</para>
4988 </section>
4989
4990 <section xml:id="Play_Trans-Special-Values">
4991 <title>Special Values</title>
4992
4993 <para>None.</para>
4994 </section>
4995 </section>
4996
4997 <section xml:id="VOC_TRANS" xreflabel="VOC_TRANS">
4998 <title>VOC_TRANS (Vocalization Translation Table)</title>
4999
5000 <para>VOC_TRANS contains one row for every vocalization code as
5001 written in the field. It is used by the
5002 <xref linkend="UPLOAD_BEHAVIORS"/> view to translate the codes
5003 written in the field to the vocalization codes used within the
5004 Gombe-MI system.</para>
5005
5006 <para>The VOC_TRANS table is different from other Gombe-MI
5007 support tables in that it's values are used only to support the
5008 behavioral data upload process, the values do not define a
5009 vocabulary used for Gombe-MI database content.</para>
5010
5011 <section xml:id="Voc_Trans-Key" xreflabel="Old_Voc">
5012 <title xml:id="Voc_Trans-Old_Voc"
5013 xreflabel="Old_Voc">Key: Old_Voc</title>
5014
5015 <para>The VOC_TRANS table is keyed by the Old_Voc
5016 column.</para>
5017 </section>
5018
5019 <section xml:id="Voc_Trans-New_Voc" xreflabel="New_Voc">
5020 <title>New_Voc (Vocalization Code)</title>
5021
5022 <para>Vocalization code to be used within Gombe-MI. The legal values
5023 for this column are defined by the <xref linkend="VOCALIZATIONS"/>
5024 support table.</para>
5025
5026 <para>&notnull;</para>
5027 </section>
5028
5029 <section xml:id="Voc_Trans-Uncertain" xreflabel="Uncertain">
5030 <title>Uncertain</title>
5031
5032 <para>A Boolean value indicating whether vocalization events
5033 deriving from the given old vocalization code should always be
5034 denoted uncertain
5035 (<xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>).
5036 When multiple vocalizations are uploaded if any of them are
5037 uncertain then all vocalizations are uncertain.<footnote>
5038
5039 <para>The database contains no provision for recording the
5040 certainty of individual vocalizations. The
5041 <xref linkend="Events-Uncertain"/> column is related to
5042 the entire <xref linkend="EVENTS"/> row.</para>
5043
5044 </footnote></para>
5045
5046 <para>&notnull;</para>
5047 </section>
5048
5049 <section xml:id="Voc_Trans-Special-Values">
5050 <title>Special Values</title>
5051
5052 <para>None.</para>
5053 </section>
5054 </section>
5055 </section>
5056
5057 <section xml:id="event_support_tables">
5058 <title>&event_section; Support Tables</title>
5059
5060 <section xml:id="BEHAVIORS" xreflabel="BEHAVIORS">
5061 <title>BEHAVIORS</title>
5062
5063 <para>BEHAVIORS contains one row for every category of behavior
5064 defined (past or present) in the data collection protocol. The
5065 BEHAVIORS table controls many aspects of the validation that
5066 occurs involving behavioral events, it is central to the
5067 system.</para>
5068
5069 <para>Behavior codes are classified into particular types,
5070 depending on what sort of supplemental information on the behavior
5071 is recorded. The classification is driven by code value in the
5072 BEHAVIORS.<xref linkend="Behaviors-Type"/> column. The type codes
5073 are as follows:</para>
5074
5075 <variablelist>
5076 <title>The BEHAVIORS.Type values</title>
5077 <varlistentry>
5078 <term><literal>&gmi_eating;</literal></term>
5079
5080 <listitem><para>Eating. There must be one or more related
5081 rows on the <xref linkend="EATS"/> table with further
5082 information on what was eaten. There can be no related rows
5083 on the <xref linkend="FISHED"/>, <xref linkend="PLAYS"/>,
5084 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, or
5085 <xref linkend="VOCS"/> tables.</para></listitem>
5086 </varlistentry>
5087
5088 <varlistentry>
5089 <term><literal>&gmi_fish;</literal></term>
5090
5091 <listitem><para>Fishing. There must be exactly one related
5092 rows on the <xref linkend="FISHED"/> table with further
5093 information on what was eaten. There can be no related rows on the
5094 <xref linkend="EATS"/>, <xref linkend="PLAYS"/>,
5095 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, or
5096 <xref linkend="VOCS"/> tables.</para></listitem>
5097 </varlistentry>
5098
5099 <varlistentry>
5100 <term><literal>&gmi_other;</literal></term>
5101
5102 <listitem><para>Other. There can be no related rows on the
5103 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
5104 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
5105 <xref linkend="RIDES"/>, or <xref linkend="VOCS"/>
5106 tables.</para></listitem>
5107 </varlistentry>
5108
5109 <varlistentry>
5110 <term><literal>&gmi_play;</literal></term>
5111
5112 <listitem><para>Playing. There must be one or more related
5113 rows on the <xref linkend="PLAYS"/> table with further
5114 information regarding the play. There can be no related rows on the
5115 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
5116 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, or
5117 <xref linkend="VOCS"/> tables.</para></listitem>
5118 </varlistentry>
5119
5120 <varlistentry>
5121 <term><literal>&gmi_ride;</literal></term>
5122
5123 <listitem><para>Riding. There must be exactly one related
5124 rows on the <xref linkend="RIDES"/> table with further
5125 information on riding posture. There can be no related rows
5126 on the <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
5127 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>, or
5128 <xref linkend="VOCS"/> tables.</para></listitem>
5129 </varlistentry>
5130
5131 <varlistentry>
5132 <term><literal>&gmi_rest;</literal></term>
5133
5134 <listitem><para>Resting. There must be exactly one related
5135 rows on the <xref linkend="RESTS"/> table with further
5136 information on resting posture. There can be no related rows
5137 on the <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
5138 <xref linkend="PLAYS"/>, <xref linkend="RIDES"/>, or
5139 <xref linkend="VOCS"/> tables.</para></listitem>
5140 </varlistentry>
5141
5142 <varlistentry>
5143 <term><literal>&gmi_vocal;</literal></term>
5144
5145
5146 <listitem><para>Vocalization. There must be one or more
5147 related rows on the <xref linkend="VOCS"/> table with further
5148 information on the vocalization. There can be no related rows
5149 on the <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
5150 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>, or
5151 <xref linkend="RIDES"/> tables.</para></listitem>
5152 </varlistentry>
5153 </variablelist>
5154
5155 <para>The <xref linkend="Behaviors-Position"/> value determines
5156 whether a position within the forest canopy is required to be part
5157 of the record of the event. When &true; <xref linkend="EVENTS"/>
5158 rows having this <xref linkend="Behaviors-Behavior"/> value must
5159 have a non-&null;
5160 <xref linkend="EVENTS"/>.<xref linkend="Events-Position"/> value.
5161 When &false; the <xref linkend="EVENTS"/> row must have a &null;
5162 <xref linkend="EVENTS"/>.<xref linkend="Events-Position"/> value.
5163 This check is performed immediately on insert or update of
5164 <xref linkend="EVENTS"/> and upon &transaction; commit on update
5165 of BEHAVIORS.</para>
5166
5167 <para>The control over which behaviors can occur when others occur
5168 is supplied by the 4 Boolean columns
5169 <xref linkend="Behaviors-Restricted"/>,
5170 <xref linkend="Behaviors-Exclusive_Behavior"/>.
5171 <xref linkend="Behaviors-Mom_Restricted"/> and,
5172 <xref linkend="Behaviors-Mom_Exclusive_Behavior"/>. The
5173 <xref linkend="Behaviors-Restricted"/> and
5174 <xref linkend="Behaviors-Exclusive_Behavior"/> columns apply to the
5175 infant and the sibling. The <xref linkend="Behaviors-Mom_Restricted"/>
5176 and <xref linkend="Behaviors-Mom_Exclusive_Behavior"/> columns apply to
5177 the mother, otherwise the functionality supplied is identical.
5178 For this reason only the <xref linkend="Behaviors-Restricted"/> and
5179 <xref linkend="Behaviors-Exclusive_Behavior"/> columns are described in
5180 the following few paragraphs.</para>
5181
5182 <para>When <xref linkend="Behaviors-Restricted"/> is &true; the
5183 behavior cannot be related to an <xref linkend="INTERVALS"/> row
5184 also related to another behavior involving the same focal
5185 designated <xref linkend="Behaviors-Exclusive_Behavior"/> unless
5186 the focal is the actee
5187 (<xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> =
5188 '&gmi_actee;'), or unless all such behavioral events are
5189 uncertain<footnote>
5190
5191 <para>To be specific: unless the
5192 <xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>
5193 values of all such behaviors are &true;.</para>
5194
5195 </footnote>. When &false; the behavior can occur with any other.
5196 This check is performed immediately, except when data in the
5197 <xref linkend="EVENTS"/> is changed table in which case the check
5198 takes place upon &transaction; commit.</para>
5199
5200 <tip>
5201 <para>It is expected that many point sample behaviors
5202 will have a &true; Exclusive_Behavior value to ensure that
5203 they do not happen when, e.g, resting or dangling is occurring,
5204 although this does not have to be the case.</para>
5205 </tip>
5206
5207 <para>Behaviors that exclude some others, those with a &true;
5208 <xref linkend="Behaviors-Restricted"/> value, must also be behaviors
5209 that are excluded, they must have a &true;
5210 <xref linkend="Behaviors-Exclusive_Behavior"/> value.</para>
5211
5212 <para>Social behaviors, behaviors involving 2 individuals<footnote>
5213
5214 <para>Non-social behaviors, the only other sort, involve a
5215 single individual.</para>
5216
5217 </footnote>, are said to be either directional or
5218 non-directional. Directional behaviors are those where one of the
5219 individuals involved initiates or sustains the behavior
5220 (the <quote>actor</quote>), the code for which
5221 is <literal>&gmi_actor;</literal> (actoR), and the other
5222 individual is acted upon (the "actee"), the code for which
5223 is <literal>&gmi_actee;</literal> (acteE). In non-directional
5224 social behavior either the 2 individuals involved play an equal
5225 part or directionality is simply unknown. In either case the 2
5226 individuals involved in social non-directed behavior are both
5227 labeled <quote>participant</quote>, the code for which
5228 is <literal>&gmi_participant;</literal> (Participant).</para>
5229
5230 <para>The individual involved in non-social behaviors, those that
5231 involve only a single individual, are designated
5232 as <quote>self</quote> -- the single
5233 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value is
5234 always <literal>&gmi_self;</literal> (Self).</para>
5235
5236 <!-- Testing matrix. 'Y' means tested, '' means untested.
5237 - Not in matrix means tested.
5238 -
5239 - behaviors parts events intervals followparts fp
5240 - update delete
5241 - mom_actor Y Y Y
5242 - mom_actee Y Y Y
5243 - mom_participant Y Y Y
5244 - mom_self Y Y Y
5245 - mom_w_nf_actor Y Y Y
5246 - mom_w_nf_actee Y Y Y
5247 - mom_w_nf_participant Y Y
5248 - infant_actor Y
5249 - infant_actee Y
5250 - infant_participant Y
5251 - infant_self Y
5252 - infant_w_nf_actor Y
5253 - infant_w_nf_actee Y
5254 - infant_w_nf_participant Y
5255 - sib_actor Y
5256 - sib_actee Y
5257 - sib_participant Y
5258 - sib_self Y
5259 - sib_w_nf_actor Y
5260 - sib_w_nf_actee Y
5261 - sib_w_nf_participant Y
5262 - baboon Y
5263 -->
5264 <para>The BEHAVIORS columns <xref linkend="Behaviors-Mom_Actor"/>,
5265 <xref linkend="Behaviors-Sib_Actor"/>, and
5266 <xref linkend="Behaviors-Infant_Actor"/> control whether,
5267 respectively, the mother in the follow, the sibling in the follow,
5268 or the infant in the follow are allowed to be actors -- whether
5269 their respective
5270 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value is
5271 allowed to be <literal>&gmi_actor;</literal>. Should the mother,
5272 sibling, or infant be allowed to be an actor then the respective
5273 <xref linkend="Behaviors-Mom_W_NF_Actee"/>,
5274 <xref linkend="Behaviors-Sib_W_NF_Actee"/>, and
5275 <xref linkend="Behaviors-Infant_W_NF_Actee"/> column must contain
5276 a value, otherwise the respective column must be &null;. The
5277 <xref linkend="Behaviors-Mom_W_NF_Actee"/>,
5278 <xref linkend="Behaviors-Sib_W_NF_Actee"/>, and
5279 <xref linkend="Behaviors-Infant_W_NF_Actee"/> columns determine
5280 whether an individual who is not a focal in the follow is allowed
5281 to be involved in the behavioral event as an actee.</para>
5282
5283 <para>The <xref linkend="Behaviors-Both_Directions"/> column
5284 controls whether or not reciprocal directed behaviors are allowed.
5285 I.e., whether or not behaviors which are directed, have an actor
5286 and an actee, such as grooming, are allowed to be mutual;
5287 e.g. whether simultaneous mutual grooming is allowed between any
5288 given pair of individuals. &true; means that reciprocal directed
5289 behaviors are allowed. &false; means they are not. The
5290 <xref linkend="Behaviors-Both_Directions"/> column must be
5291 non-&null; when there is a possibility of directed interaction --
5292 when any of the BEHAVIORS columns
5293 <xref linkend="Behaviors-Mom_Actor"/>,
5294 <xref linkend="Behaviors-Mom_Actee"/>,
5295 <xref linkend="Behaviors-Mom_W_NF_Actor"/>,
5296 <xref linkend="Behaviors-Mom_W_NF_Actee"/>,
5297 <xref linkend="Behaviors-Sib_Actor"/>,
5298 <xref linkend="Behaviors-Sib_Actee"/>,
5299 <xref linkend="Behaviors-Sib_W_NF_Actor"/>,
5300 <xref linkend="Behaviors-Sib_W_NF_Actee"/>,
5301 <xref linkend="Behaviors-Infant_Actor"/>,
5302 <xref linkend="Behaviors-Infant_Actee"/>,
5303 <xref linkend="Behaviors-Infant_W_NF_Actor"/>, or
5304 <xref linkend="Behaviors-Infant_W_NF_Actee"/> are &true; and must
5305 be &null; otherwise. This check is performed upon &transaction;
5306 commit, except that when the <xref linkend="BEHAVIORS"/> table is
5307 updated the check is performed immediately.</para>
5308
5309 <para>The BEHAVIORS columns
5310 <xref linkend="Behaviors-Mom_Participant"/>,
5311 <xref linkend="Behaviors-Sib_Participant"/>,
5312 <xref linkend="Behaviors-Infant_Participant"/> and their
5313 respective <xref linkend="Behaviors-Mom_W_NF_Actor"/>,
5314 <xref linkend="Behaviors-Sib_W_NF_Actor"/>, and
5315 <xref linkend="Behaviors-Infant_W_NF_Actor"/> columns behave as
5316 the columns described just above only with respect to
5317 the <quote>participant</quote> role.</para>
5318
5319 <para>The BEHAVIORS columns <xref linkend="Behaviors-Mom_Self"/>,
5320 <xref linkend="Behaviors-Sib_Self"/>,
5321 <xref linkend="Behaviors-Infant_Self"/> control whether,
5322 respectively, the mother in the follow, the sibling in the follow,
5323 or the infant in the follow are allowed to be involved in the
5324 behavior without another individual -- whether their respective
5325 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value is
5326 allowed to be <literal>&gmi_self;</literal>.</para>
5327
5328 <para>If there is a record of a non-social interaction for an
5329 individual then the individual may not also be involved in a
5330 non-directed social interaction of this kind during the interval
5331 -- if an <xref linkend="EVENTS"/> row exists with a single related
5332 <xref linkend="PARTS"/> row<footnote>
5333
5334 <para>Necessarily having a
5335 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> value
5336 of <literal>&gmi_self;</literal>.</para>
5337
5338 </footnote>then there may not be other <xref linkend="EVENTS"/>
5339 rows related to the <xref linkend="INTERVALS"/> row with 2 related
5340 <xref linkend="PARTS"/> rows where either of the 2
5341 <xref linkend="PARTS"/> rows has a
5342 <xref linkend="Parts-Participant"/> value identifying the
5343 individual in question.<footnote>
5344
5345 <para>So, for example, an individual may not self-play while
5346 playing with another individual. The general notion of
5347 non-directed social interactions is such that, we hope, this
5348 rule excludes dis-allowed behavioral combinations but does not
5349 interfere with the storage of legitimate behaviors in the
5350 database.</para>
5351
5352 </footnote> This check occurs upon &transaction; commit.</para>
5353
5354 <para>The <xref linkend="Behaviors-Baboon"/> column must be
5355 non-&null; when the other BEHAVIORS columns allow a non-focal to
5356 be involved in the behavior, otherwise
5357 <xref linkend="Behaviors-Baboon"/> must be &null;.</para>
5358
5359 <section xml:id="Behaviors-Key" xreflabel="Behavior">
5360 <title xml:id="Behaviors-Behavior" xreflabel="Behavior">Key:
5361 Behavior</title>
5362
5363 <para>The BEHAVIORS table is keyed by the Behavior column.</para>
5364 </section>
5365
5366 <section xml:id="Behaviors-Swahili" xreflabel="Swahili">
5367 <title>Swahili (Swahili Name)</title>
5368
5369 <para>The Swahili name of the behavior. &emptytext; This column
5370 may be &null;, which is usually an indication that no Swahili
5371 name was used on the data collection templates.<footnote>
5372
5373 <para>And is not, of course, any reflection on the richness
5374 of the Swahili language vocabulary, which, based on this
5375 author's brief encounter with Gombe-MI project's data
5376 collection templates, was thought be so rich as to have a
5377 single word for
5378 vocalizations-uttered-while-engaged-in-copulation. As it
5379 turns out, the word translates
5380 as <wordasword>romance</wordasword> -- which was a little
5381 disappointing.</para>
5382
5383 </footnote></para>
5384 </section>
5385
5386 <section xml:id="Behaviors-Type" xreflabel="Type">
5387 <title>Type (Behavior Type)</title>
5388
5389 <para>A code designating the behavior as one of a certain type.
5390 See the overall description of <xref linkend="BEHAVIORS"/> above
5391 for further information.</para>
5392
5393 <para>&notnull; The value of this column cannot be
5394 changed.</para>
5395 </section>
5396
5397 <section xml:id="Behaviors-Position" xreflabel="Position">
5398 <title>Position (Position Required)</title>
5399
5400 <para>A Boolean value; whether or not the event must have a
5401 <xref linkend="Events-Position"/> value.</para>
5402
5403 <para>&notnull;</para>
5404 </section>
5405
5406 <section xml:id="Behaviors-Both_Directions" xreflabel="Both_Directions">
5407 <title>Both_Directions (Mutual Directed Behavior is Allowed)</title>
5408
5409 <para>A Boolean value. When &true; pairs of individuals may
5410 exhibit the behavior twice, each with the directionality of the
5411 other reversed. See the overall description of
5412 <xref linkend="BEHAVIORS"/> above for further
5413 information.</para>
5414
5415 <para>This column must be &null; when directed behavior is
5416 allowed and otherwise must not be &null;. See the overall
5417 description of <xref linkend="BEHAVIORS"/> above for further
5418 information.</para>
5419 </section>
5420
5421 <section xml:id="Behaviors-Restricted" xreflabel="Restricted">
5422 <title>Restricted (Infant or Sib's Behavior is Exclusive of Some
5423 Others)</title>
5424
5425 <para>A Boolean value. When &true; the behavior is designated
5426 as one that excludes the possibility of the infant or
5427 sibling simultaneously having one of the behaviors
5428 marked <quote>on the minute</quote>. When &false; the
5429 behavior does not exclude any others. See the overall
5430 description of <xref linkend="BEHAVIORS"/> above for further
5431 information.</para>
5432
5433 <para>&notnull;</para>
5434 </section>
5435
5436 <section xml:id="Behaviors-Exclusive_Behavior" xreflabel="Exclusive_Behavior">
5437 <title>Exclusive_Behavior (Behavior is Excluded by Restricted Behaviors)</title>
5438
5439 <para>A Boolean value. When &true; the behavior is designated as
5440 an infant or sibling behavior that cannot occur with behaviors
5441 designated as occurring <quote>restricted</quote>. When &false;
5442 the behavior can occur with any other. See the overall
5443 description of <xref linkend="BEHAVIORS"/> above for further
5444 information.</para>
5445
5446 <para>&notnull;</para>
5447 </section>
5448
5449 <section xml:id="Behaviors-Mom_Restricted" xreflabel="Mom_Restricted">
5450 <title>Mom_Restricted (Mom's Behavior is Exclusive of Some Others)</title>
5451
5452 <para>A Boolean value. When &true; the behavior is designated
5453 as one that excludes the possibility of the mother
5454 simultaneously having one of the behaviors marked <quote>on
5455 the minute for the mom</quote>. When &false; the behavior
5456 does not exclude any others. See the overall description of
5457 <xref linkend="BEHAVIORS"/> above for further
5458 information.</para>
5459
5460 <para>&notnull;</para>
5461 </section>
5462
5463 <section xml:id="Behaviors-Mom_Exclusive_Behavior" xreflabel="Mom_Exclusive_Behavior">
5464 <title>Mom_Exclusive_Behavior (Behavior is Excluded by Mom_Restricted
5465 Behaviors)</title>
5466
5467 <para>A Boolean value. When &true; the behavior is designated as
5468 one that cannot involve the mother at the same time as those
5469 behaviors designated as <quote>mom restricted</quote>. When
5470 &false; the behavior can occur with any other. See the
5471 overall description of <xref linkend="BEHAVIORS"/> above for
5472 further information.</para>
5473
5474 <para>&notnull;</para>
5475 </section>
5476
5477 <section xml:id="Behaviors-Mom_Actor" xreflabel="Mom_Actor">
5478 <title>Mom_Actor (Mother May be Actor)</title>
5479
5480 <para>A Boolean value. Whether or not the focal that is the
5481 mother may be an actor in this kind of behavioral event. See
5482 the overall description of <xref linkend="BEHAVIORS"/> above for
5483 further information.</para>
5484
5485 <para>&notnull;</para>
5486 </section>
5487
5488 <section xml:id="Behaviors-Mom_Actee" xreflabel="Mom_Actee">
5489 <title>Mom_Actee (Mother May be Actee)</title>
5490
5491 <para>A Boolean value. Whether or not the focal that is the
5492 mother may be an actee in this kind of behavioral event. See
5493 the overall description of <xref linkend="BEHAVIORS"/> above for
5494 further information.</para>
5495
5496 <para>&notnull;</para>
5497 </section>
5498
5499 <section xml:id="Behaviors-Mom_Participant" xreflabel="Mom_Participant">
5500 <title>Mom_Participant (Mother May be Participant)</title>
5501
5502 <para>A Boolean value. Whether or not the focal that is the
5503 mother may be a participant in this kind of behavior in a
5504 non-directed but social way, a way involving 2 individuals. See
5505 the overall description of <xref linkend="BEHAVIORS"/> above for
5506 further information.</para>
5507
5508 <para>&notnull;</para>
5509 </section>
5510
5511 <section xml:id="Behaviors-Mom_Self" xreflabel="Mom_Self">
5512 <title>Mom_Self (Mother May Engage in the Behavior Solo)</title>
5513
5514 <para>A Boolean value. Whether or not the focal that is the
5515 mother may be involved this kind of behavior in a non-social
5516 way, as the sole individual involved. See the overall
5517 description of <xref linkend="BEHAVIORS"/> above for further
5518 information.</para>
5519
5520 <para>&notnull;</para>
5521 </section>
5522
5523 <section xml:id="Behaviors-Mom_W_NF_Actor"
5524 xreflabel="Mom_W_NF_Actor">
5525 <title>Mom_W_NF_Actor (Mom With Non-Focal Actor)</title>
5526
5527 <para>A Boolean value. Whether or not an individual who is not
5528 a focal may be involved in the behavioral event as an actor when
5529 the focal mother is also involved in the behavioral event. See
5530 the overall description of <xref linkend="BEHAVIORS"/> above for
5531 further information.</para>
5532
5533 <para>The value of this column may be &null;; see the overall
5534 description of <xref linkend="BEHAVIORS"/> above for further
5535 information.</para>
5536 </section>
5537
5538 <section xml:id="Behaviors-Mom_W_NF_Actee"
5539 xreflabel="Mom_W_NF_Actee">
5540 <title>Mom_W_NF_Actee (Mom With Non-Focal Actee)</title>
5541
5542 <para>A Boolean value. Whether or not an individual who is not
5543 a focal may be involved in the behavioral event as an actee when
5544 the focal mother is also involved in the behavioral event. See
5545 the overall description of <xref linkend="BEHAVIORS"/> above for
5546 further information.</para>
5547
5548 <para>The value of this column may be &null;; see the overall
5549 description of <xref linkend="BEHAVIORS"/> above for further
5550 information.</para>
5551 </section>
5552
5553 <section xml:id="Behaviors-Mom_W_NF_Participant"
5554 xreflabel="Mom_W_NF_Participant">
5555 <title>Mom_W_NF_Participant (Mom With Non-Focal Participant)</title>
5556
5557 <para>A Boolean value. Whether or not an individual who is not
5558 a focal may be involved in the behavioral event as a
5559 non-directional participant when the focal mother is also
5560 involved in the behavioral event. See the overall description
5561 of <xref linkend="BEHAVIORS"/> above for further
5562 information.</para>
5563
5564 <para>The value of this column may be &null;; see the overall
5565 description of <xref linkend="BEHAVIORS"/> above for further
5566 information.</para>
5567 </section>
5568
5569 <section xml:id="Behaviors-Sib_Actor" xreflabel="Sib_Actor">
5570 <title>Sib_Actor (Sibling May be Actor)</title>
5571
5572 <para>A Boolean value. Whether or not the focal that is the
5573 sibling may be an actor in this kind of behavioral event. See
5574 the overall description of <xref linkend="BEHAVIORS"/> above for
5575 further information.</para>
5576
5577 <para>&notnull;</para>
5578 </section>
5579
5580 <section xml:id="Behaviors-Sib_Actee" xreflabel="Sib_Actee">
5581 <title>Sib_Actee (Sibling May be Actee)</title>
5582
5583 <para>A Boolean value. Whether or not the focal that is the
5584 sibling may be an actee in this kind of behavioral event. See
5585 the overall description of <xref linkend="BEHAVIORS"/> above for
5586 further information.</para>
5587
5588 <para>&notnull;</para>
5589 </section>
5590
5591 <section xml:id="Behaviors-Sib_Participant" xreflabel="Sib_Participant">
5592 <title>Sib_Participant (Sibling May be Participant)</title>
5593
5594 <para>A Boolean value. Whether or not the focal that is the
5595 sibling may be a participant in this kind of behavior in a
5596 non-directed but social way, a way involving 2 individuals. See
5597 the overall description of <xref linkend="BEHAVIORS"/> above for
5598 further information.</para>
5599
5600 <para>&notnull;</para>
5601 </section>
5602
5603 <section xml:id="Behaviors-Sib_Self" xreflabel="Sib_Self">
5604 <title>Sib_Self (Sibling May Engage in the Behavior Solo)</title>
5605
5606 <para>A Boolean value. Whether or not the focal that is the
5607 sibling may be involved this kind of behavior in a non-social
5608 way, as the sole individual involved. See the overall
5609 description of <xref linkend="BEHAVIORS"/> above for further
5610 information.</para>
5611
5612 <para>&notnull;</para>
5613 </section>
5614
5615 <section xml:id="Behaviors-Sib_W_NF_Actor"
5616 xreflabel="Sib_W_NF_Actor">
5617 <title>Sib_W_NF_Actor (Sib With Non-Focal Actor)</title>
5618
5619 <para>A Boolean value. Whether or not an individual who is not
5620 a focal may be involved in the behavioral event as an actor when
5621 the focal sibling is also involved in the behavioral event. See
5622 the overall description of <xref linkend="BEHAVIORS"/> above for
5623 further information.</para>
5624
5625 <para>The value of this column may be &null;; see the overall
5626 description of <xref linkend="BEHAVIORS"/> above for further
5627 information.</para>
5628 </section>
5629
5630 <section xml:id="Behaviors-Sib_W_NF_Actee"
5631 xreflabel="Sib_W_NF_Actee">
5632 <title>Sib_W_NF_Actee (Sib With Non-Focal Actee)</title>
5633
5634 <para>A Boolean value. Whether or not an individual who is not
5635 a focal may be involved in the behavioral event as an actee when
5636 the focal sibling is also involved in the behavioral event. See
5637 the overall description of <xref linkend="BEHAVIORS"/> above for
5638 further information.</para>
5639
5640 <para>The value of this column may be &null;; see the overall
5641 description of <xref linkend="BEHAVIORS"/> above for further
5642 information.</para>
5643 </section>
5644
5645 <section xml:id="Behaviors-Sib_W_NF_Participant"
5646 xreflabel="Sib_W_NF_Participant">
5647 <title>Sib_W_NF_Participant (Sib With Non-Focal Participant)</title>
5648
5649 <para>A Boolean value. Whether or not an individual who is not
5650 a focal may be involved in the behavioral event as a
5651 non-directional participant when the focal sibling is also
5652 involved in the behavioral event. See the overall description
5653 of <xref linkend="BEHAVIORS"/> above for further
5654 information.</para>
5655
5656 <para>The value of this column may be &null;; see the overall
5657 description of <xref linkend="BEHAVIORS"/> above for further
5658 information.</para>
5659 </section>
5660
5661 <section xml:id="Behaviors-Infant_Actor" xreflabel="Infant_Actor">
5662 <title>Infant_Actor (Infant May be Actor)</title>
5663
5664 <para>A Boolean value. Whether or not the focal that is the
5665 infant may be an actor in this kind of behavioral event. See
5666 the overall description of <xref linkend="BEHAVIORS"/> above for
5667 further information.</para>
5668
5669 <para>&notnull;</para>
5670 </section>
5671
5672 <section xml:id="Behaviors-Infant_Actee" xreflabel="Infant_Actee">
5673 <title>Infant_Actee (Infant May be Actee)</title>
5674
5675 <para>A Boolean value. Whether or not the focal that is the
5676 infant may be an actee in this kind of behavioral event. See
5677 the overall description of <xref linkend="BEHAVIORS"/> above for
5678 further information.</para>
5679
5680 <para>&notnull;</para>
5681 </section>
5682
5683 <section xml:id="Behaviors-Infant_Participant"
5684 xreflabel="Infant_Participant">
5685 <title>Infant_Participant (Infant May be Participant)</title>
5686
5687 <para>A Boolean value. Whether or not the focal that is the
5688 infant may be a participant in this kind of behavior in a
5689 non-directed but social way, a way involving 2 individuals. See
5690 the overall description of <xref linkend="BEHAVIORS"/> above for
5691 further information.</para>
5692
5693 <para>&notnull;</para>
5694 </section>
5695
5696 <section xml:id="Behaviors-Infant_Self" xreflabel="Infant_Self">
5697 <title>Infant_Self (Infant May Engage in the Behavior Solo)</title>
5698
5699 <para>A Boolean value. Whether or not the focal that is the
5700 infant may be involved this kind of behavior in a non-social
5701 way, as the sole individual involved. See the overall
5702 description of <xref linkend="BEHAVIORS"/> above for further
5703 information.</para>
5704
5705 <para>&notnull;</para>
5706 </section>
5707
5708 <section xml:id="Behaviors-Infant_W_NF_Actor"
5709 xreflabel="Infant_W_NF_Actor">
5710 <title>Infant_W_NF_Actor (Infant With Non-Focal Actor)</title>
5711
5712 <para>A Boolean value. Whether or not an individual who is not
5713 a focal may be involved in the behavioral event as an actor when
5714 the focal infant is also involved in the behavioral event. See
5715 the overall description of <xref linkend="BEHAVIORS"/> above for
5716 further information.</para>
5717
5718 <para>The value of this column may be &null;; see the overall
5719 description of <xref linkend="BEHAVIORS"/> above for further
5720 information.</para>
5721 </section>
5722
5723 <section xml:id="Behaviors-Infant_W_NF_Actee"
5724 xreflabel="Infant_W_NF_Actee">
5725 <title>Infant_W_NF_Actee (Infant With Non-Focal Actee)</title>
5726
5727 <para>A Boolean value. Whether or not an individual who is not
5728 a focal may be involved in the behavioral event as an actee when
5729 the focal infant is also involved in the behavioral event. See
5730 the overall description of <xref linkend="BEHAVIORS"/> above for
5731 further information.</para>
5732
5733 <para>The value of this column may be &null;; see the overall
5734 description of <xref linkend="BEHAVIORS"/> above for further
5735 information.</para>
5736 </section>
5737
5738 <section xml:id="Behaviors-Infant_W_NF_Participant"
5739 xreflabel="Infant_W_NF_Participant">
5740 <title>Infant_W_NF_Participant (Infant With Non-Focal
5741 Participant)</title>
5742
5743 <para>A Boolean value. Whether or not an individual who is not
5744 a focal may be involved in the behavioral event as a
5745 non-directional participant when the focal infant is also
5746 involved in the behavioral event. See the overall description
5747 of <xref linkend="BEHAVIORS"/> above for further
5748 information.</para>
5749
5750 <para>The value of this column may be &null;; see the overall
5751 description of <xref linkend="BEHAVIORS"/> above for further
5752 information.</para>
5753 </section>
5754
5755 <section xml:id="Behaviors-Baboon" xreflabel="Baboon">
5756 <title>Baboon (Is a Baboon Allowed to Interact?)</title>
5757
5758 <para> A Boolean value. When &true; baboons are allowed to be
5759 involved in this kind of behavioral event in place of a
5760 non-focal chimpanzee -- the related
5761 <xref linkend="EVENTS"/>.<xref linkend="Events-Baboon"/> column
5762 may be &true;. When &false; baboons may not be involved in this
5763 kind of behavioral event -- the related
5764 <xref linkend="EVENTS"/>.<xref linkend="Events-Baboon"/> column
5765 must be &false;.</para>
5766
5767 <para>The value of this column may be &null;; see the overall
5768 description of <xref linkend="BEHAVIORS"/> above for further
5769 information.</para>
5770 </section>
5771
5772 <section xml:id="Behaviors-Special-Values">
5773 <title>Special Values</title>
5774
5775 <para>None.</para>
5776 </section>
5777 </section>
5778
5779 <section xml:id="FISHING_RESULTS" xreflabel="FISHING_RESULTS">
5780 <title>FISHING_RESULTS</title>
5781
5782 <para>FISHING_RESULTS contains one row for every code designating
5783 a fishing attempt result.</para>
5784
5785 <section xml:id="Fishing_Results-Key" xreflabel="Fishing_Result">
5786 <title xml:id="Fishing_Results-Fishing_Result"
5787 xreflabel="Fishing_Result">Key: Result</title>
5788
5789 <para>The FISHING_RESULTS table is keyed by the Result column.</para>
5790 </section>
5791
5792 <section xml:id="Fishing_Results-Special-Values">
5793 <title>Special Values</title>
5794
5795 <para>None.</para>
5796 </section>
5797 </section>
5798
5799 <section xml:id="FOODKINDS" xreflabel="FOODKINDS">
5800 <title>FOODKINDS</title>
5801
5802 <para>FOODKINDS contains one row for every code designating
5803 a kind of food eaten by chimpanzees.</para>
5804
5805 <para>The <xref linkend="Foodkinds-Scientific"/> value (when
5806 non-&null;) must be unique.</para>
5807
5808 <section xml:id="Foodkinds-Key" xreflabel="Foodkind">
5809 <title xml:id="Foodkinds-Foodkind" xreflabel="Foodkind">Key:
5810 Foodkind</title>
5811
5812 <para>The FOODKINDS table is keyed by the Foodkind column.</para>
5813 </section>
5814
5815 <section xml:id="Foodkinds-Scientific" xreflabel="Scientific">
5816 <title>Scientific (Scientific Name)</title>
5817
5818 <para>The scientific name for the kind of food. &emptytext;
5819 &notnull;</para>
5820 </section>
5821
5822 <section xml:id="Foodkinds-Fishable" xreflabel="Fishable">
5823 <title>Fishable (Can the Food be Fished For?)</title>
5824
5825 <para>A Boolean value indicating whether the food can be fished
5826 for. &true; indicates that the food can be fished for.</para>
5827 </section>
5828
5829 <section xml:id="Foodkinds-Special-Values">
5830 <title>Special Values</title>
5831
5832 <para>None.</para>
5833 </section>
5834 </section>
5835
5836 <section xml:id="FOODPARTS" xreflabel="FOODPARTS">
5837 <title>FOODPARTS</title>
5838
5839 <para>FOODPARTS contains one row for every code designating
5840 a kind of food eaten by chimpanzees.</para>
5841
5842 <para>The <xref linkend="Foodparts-Swahili"/> value (when
5843 non-&null;) must be unique.</para>
5844
5845 <section xml:id="Foodparts-Key" xreflabel="Foodpart">
5846 <title xml:id="Foodparts-Foodpart" xreflabel="Foodpart">Key:
5847 Foodpart</title>
5848
5849 <para>The FOODPARTS table is keyed by the Foodpart column.</para>
5850 </section>
5851
5852 <section xml:id="Foodparts-Swahili" xreflabel="Swahili">
5853 <title>Swahili (Swahili Name)</title>
5854
5855 <para>The Swahili name for the kind of food. &emptytext;
5856 &null;</para>
5857 </section>
5858
5859 <section xml:id="Foodparts-Fishable" xreflabel="Fishable">
5860 <title>Fishable (Can the Food be Fished For?)</title>
5861
5862 <para>A Boolean value indicating whether the food can be fished
5863 for. &true; indicates that the food can be fished for.</para>
5864 </section>
5865
5866 <section xml:id="Foodparts-Special-Values">
5867 <title>Special Values</title>
5868
5869 <para>None.</para>
5870 </section>
5871 </section>
5872
5873 <section xml:id="POSITIONS" xreflabel="POSITIONS">
5874 <title>POSITIONS</title>
5875
5876 <para>POSITIONS contains one row for every code designating
5877 position within the forest canopy defined (past or present) in the
5878 data collection protocol.</para>
5879
5880 <section xml:id="Positions-Key" xreflabel="Position">
5881 <title xml:id="Positions-Position" xreflabel="Position">Key:
5882 Position</title>
5883
5884 <para>The POSITIONS table is keyed by the Position column.</para>
5885 </section>
5886
5887 <section xml:id="Positions-Special-Values">
5888 <title>Special Values</title>
5889
5890 <para>None.</para>
5891 </section>
5892 </section>
5893
5894 <section xml:id="PLAY_TYPES" xreflabel="PLAY_TYPES">
5895 <title>PLAY_TYPES</title>
5896
5897 <para>PLAY_TYPES contains one row for every designated
5898 play activity defined (past or present) in the data collection
5899 protocol.</para>
5900
5901 <section xml:id="Play_Types-Key" xreflabel="Play">
5902 <title xml:id="Play_Types-Play" xreflabel="Play">Key:
5903 Play</title>
5904
5905 <para>The PLAY_TYPES table is keyed by the Play column.</para>
5906 </section>
5907
5908 <section xml:id="Play_Types-Special-Values">
5909 <title>Special Values</title>
5910
5911 <para>None.</para>
5912 </section>
5913 </section>
5914
5915 <section xml:id="RESTING_POSTURES" xreflabel="RESTING_POSTURES">
5916 <title>RESTING_POSTURES</title>
5917
5918 <para>RESTING_POSTURES contains one row for every designated
5919 resting posture defined (past or present) in the data collection
5920 protocol.</para>
5921
5922 <section xml:id="Resting_Postures-Key" xreflabel="Rest">
5923 <title xml:id="Resting_Postures-Rest" xreflabel="Rest">Key:
5924 Rest</title>
5925
5926 <para>The RESTING_POSTURES table is keyed by the Rest column.</para>
5927 </section>
5928
5929 <section xml:id="Resting_Postures-Special-Values">
5930 <title>Special Values</title>
5931
5932 <para>None.</para>
5933 </section>
5934 </section>
5935
5936 <section xml:id="RIDING_POSTURES" xreflabel="RIDING_POSTURES">
5937 <title>RIDING_POSTURES</title>
5938
5939 <para>RIDING_POSTURES contains one row for every designated
5940 riding posture defined (past or present) in the data collection
5941 protocol.</para>
5942
5943 <section xml:id="Riding_Postures-Key" xreflabel="Ride">
5944 <title xml:id="Riding_Postures-Ride" xreflabel="Ride">Key:
5945 Ride</title>
5946
5947 <para>The RIDING_POSTURES table is keyed by the Ride column.</para>
5948 </section>
5949
5950 <section xml:id="Riding_Postures-Special-Values">
5951 <title>Special Values</title>
5952
5953 <para>None.</para>
5954 </section>
5955 </section>
5956
5957 <section xml:id="VOCALIZATIONS" xreflabel="VOCALIZATIONS">
5958 <title>VOCALIZATIONS</title>
5959
5960 <para>VOCALIZATIONS contains one row for every code designating a
5961 kind of vocalization made by chimpanzees as defined (past or
5962 present) in the data collection protocol.</para>
5963
5964 <section xml:id="Vocalizations-Key" xreflabel="Vocalization">
5965 <title xml:id="Vocalizations-Vocalization"
5966 xreflabel="Vocalization">Key: Vocalization</title>
5967
5968 <para>The VOCALIZATIONS table is keyed by the Vocalization
5969 column.</para>
5970 </section>
5971
5972 <section xml:id="Vocalizations-Special-Values">
5973 <title>Special Values</title>
5974
5975 <para>None.</para>
5976 </section>
5977 </section>
5978
5979 </section>
5980
5981 <section xml:id="distance_support_tables">
5982 <title>&distance_section; Support Tables</title>
5983
5984
5985 <section xml:id="DISTANCECODES" xreflabel="DISTANCECODES">
5986 <title>DISTANCECODES</title>
5987
5988 <para>DISTANCECODES contains one row for every distance category
5989 defined (past or present) in the data collection protocol.</para>
5990
5991 <section xml:id="Distancecodes-Key" xreflabel="Distance">
5992 <title xml:id="Distancecodes-Distance" xreflabel="Distance">Key:
5993 Distance</title>
5994
5995 <para>The DISTANCECODES table is keyed by the Distance column.</para>
5996 </section>
5997
5998 <section xml:id="Distancecodes-Special-Values">
5999 <title>Special Values</title>
6000
6001 <para>The value <literal>&gmi_distunk;</literal> is used to
6002 specify that a distance was observed but the true value cannot
6003 now be determined.</para>
6004 </section>
6005 </section>
6006
6007 </section>
6008
6009 <section xml:id="group_support_tables">
6010 <title>&group_section; Support Tables</title>
6011
6012
6013 <section xml:id="GCSTATUSES" xreflabel="GCSTATUSES">
6014 <title>GCSTATUSES</title>
6015
6016 <para>GCSTATUSES contains one row for every group composition
6017 status. These values indicate the state or source of all the
6018 group composition information related to any one follow.</para>
6019
6020 <section xml:id="GCStatuses-Key" xreflabel="GCStatus">
6021 <title xml:id="GCStatuses-GCStatus" xreflabel="GCStatus">Key:
6022 GCStatus</title>
6023
6024 <para>The GCSTATUSES table is keyed by the GCStatus column.</para>
6025 </section>
6026
6027 <section xml:id="GCStatuses-Special-Values">
6028 <title>Special Values</title>
6029
6030 <para>The value <literal>&gmi_automatic_gcstatus;</literal>
6031 indicates that the row has been automatically created by the
6032 system.<footnote>
6033
6034 <para>By the <xref linkend="infer_gc"/> function.</para>
6035
6036 </footnote></para>
6037 </section>
6038 </section>
6039
6040
6041 <section xml:id="GM_ORIGINS" xreflabel="GM_ORIGINS">
6042 <title>GM_ORIGINS</title>
6043
6044 <para>GM_ORIGINS contains one row for every group membership
6045 origin code. These codes indicate the origin of the group
6046 composition data for the particular group member.</para>
6047
6048 <section xml:id="Gm_Origins-Key" xreflabel="Origin">
6049 <title xml:id="Gm_Origins-Origin" xreflabel="Origin">Key:
6050 Origin</title>
6051
6052 <para>The GM_ORIGINS table is keyed by the Origin column.</para>
6053 </section>
6054
6055 <section xml:id="Gm_Origins-Special-Values">
6056 <title>Special Values</title>
6057
6058 <para>The value <literal>&gmi_automatic_origin;</literal>
6059 indicates that the row has been automatically created by the
6060 system.</para>
6061 </section>
6062 </section>
6063
6064 </section>
6065
6066 </chapter>
6067
6068 <chapter xml:id="The-Gombe-MI-Views">
6069 <title>The Gombe-MI Views</title>
6070
6071 <para>The database structures holding the Gombe-MI data are
6072 constructed in a fashion which enables arbitrary and efficient data
6073 retrieval. Because these tables and their relationships are not
6074 necessarily convenient or understandable to the average user of the
6075 Gombe-MI system, the system uses the <wordasword>view</wordasword>
6076 database feature to provide simplified <quote>pictures</quote> of
6077 the data. Views are nothing more than queries, queries which appear
6078 to be tables. Views differ from tables only in that some views may
6079 not be used to change (insert, update, or delete) the underlying
6080 data.</para>
6081
6082 <section xml:id="Demography-Related-Views">
6083 <title>&demography_section; Views</title>
6084
6085 <section xml:id="BIOGRAPHY" xreflabel="BIOGRAPHY">
6086 <title>BIOGRAPHY</title>
6087
6088 <para>BIOGRAPHY contains one row per
6089 <xref linkend="BIOGRAPHY_DATA"/> row. It provides a stable
6090 interface into the imported Access table
6091 <xref linkend="BIOGRAPHY_DATA"/>, allowing the underlying table
6092 to change without affecting Gombe-MI.</para>
6093
6094 <para>This view should be used instead of
6095 <xref linkend="BIOGRAPHY_DATA"/>. The view contains all of
6096 <xref linkend="BIOGRAPHY_DATA"/>'s columns, plus the
6097 <xref linkend="Biography_Data-AnimID"/> of the individual's twin,
6098 from <xref linkend="TWINS"/>.<xref linkend="Twins-Twin"/>, if a
6099 twin. Of course in most cases there is no twin and the
6100 <xref linkend="Biography-Twin"/> column will be &null;.</para>
6101
6102 <section xml:id="BIOGRAPHY-Definition">
6103 <title>BIOGRAPHY Definition</title>
6104
6105 <xi:include
6106 href="views/biography.xml"
6107 xmlns:xi="http://www.w3.org/2001/XInclude"/>
6108 </section>
6109
6110 <section xml:id="Biography-Columns">
6111 <title>BIOGRAPHY Columns</title>
6112 <informaltable frame="topbot">
6113 <tgroup cols="3" colsep="0" rowsep="0">
6114 <colspec colnum="3" rowsep="1"/>
6115 <thead>
6116 <row rowsep="1">
6117 <entry>Column</entry>
6118 <entry>From</entry>
6119 <entry>Description</entry>
6120 </row>
6121 </thead>
6122 <tbody>
6123 <row xml:id="Biography-AnimID" xreflabel="AnimID">
6124 <entry>AnimID</entry>
6125
6126 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6127 linkend="Biography_Data-AnimID"/></entry>
6128
6129 <entry>Identifier of the individual.</entry>
6130 </row>
6131
6132 <row xml:id="Biography-AnimID_Num" xreflabel="AnimID_Num">
6133 <entry>AnimID_Num</entry>
6134
6135 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6136 linkend="Biography_Data-AnimID_Num"/></entry>
6137
6138 <entry>Identifier for the individual in the SIV
6139 study.</entry>
6140 </row>
6141
6142 <row xml:id="Biography-AnimName" xreflabel="AnimName">
6143 <entry>AnimName</entry>
6144
6145 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6146 linkend="Biography_Data-AnimName"/></entry>
6147
6148 <entry>Name of the individual.</entry>
6149 </row>
6150
6151 <row xml:id="Biography-BirthGroup" xreflabel="BirthGroup">
6152 <entry>BirthGroup</entry>
6153
6154 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6155 linkend="Biography_Data-BirthGroup"/></entry>
6156
6157 <entry>Birth community of the individual.</entry>
6158 </row>
6159
6160 <row xml:id="Biography-BGCertainty" xreflabel="BGCertainty">
6161 <entry>BGCertainty</entry>
6162
6163 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6164 linkend="Biography_Data-BGCertainty"/></entry>
6165
6166 <entry>Certainty of the individual's birth community.</entry>
6167 </row>
6168
6169 <row xml:id="Biography-Sex" xreflabel="Sex">
6170 <entry>Sex</entry>
6171
6172 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6173 linkend="Biography_Data-Sex"/></entry>
6174
6175 <entry>Sex of the individual.</entry>
6176 </row>
6177
6178 <row xml:id="Biography-MomID" xreflabel="MomID">
6179 <entry>MomID</entry>
6180
6181 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6182 linkend="Biography_Data-MomID"/></entry>
6183
6184 <entry>Identifier of the individual's mother.</entry>
6185 </row>
6186
6187 <row xml:id="Biography-DadID" xreflabel="DadID">
6188 <entry>DadID</entry>
6189
6190 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6191 linkend="Biography_Data-DadID"/></entry>
6192
6193 <entry>Identifier of the individual's father.</entry>
6194 </row>
6195
6196 <row xml:id="Biography-Dad_Prelim" xreflabel="Dad_Prelim">
6197 <entry>Dad_Prelim</entry>
6198
6199 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6200 linkend="Biography_Data-Dad_Prelim"/></entry>
6201
6202 <entry>Whether paternity is preliminary.</entry>
6203 </row>
6204
6205 <row xml:id="Biography-Dad_Published" xreflabel="Dad_Published">
6206 <entry>Dad_Published</entry>
6207
6208 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6209 linkend="Biography_Data-Dad_Published"/></entry>
6210
6211 <entry>Whether paternity has been published.</entry>
6212 </row>
6213
6214 <row xml:id="Biography-FirstBorn" xreflabel="FirstBorn">
6215 <entry>FirstBorn</entry>
6216
6217 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6218 linkend="Biography_Data-FirstBorn"/></entry>
6219
6220 <entry>Whether the individual is the mother's
6221 firstborn.</entry>
6222 </row>
6223
6224 <row xml:id="Biography-Birthdate" xreflabel="Birthdate">
6225 <entry>Birthdate</entry>
6226
6227 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6228 linkend="Biography_Data-Birthdate"/></entry>
6229
6230 <entry>Birth date of the individual.</entry>
6231 </row>
6232
6233 <row xml:id="Biography-BDMin" xreflabel="BDMin">
6234 <entry>BDMin</entry>
6235
6236 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6237 linkend="Biography_Data-BDMin"/></entry>
6238
6239 <entry>Minimum possible birth date.</entry>
6240 </row>
6241
6242 <row xml:id="Biography-BDMax" xreflabel="BDMax">
6243 <entry>BDMax</entry>
6244
6245 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6246 linkend="Biography_Data-BDMax"/></entry>
6247
6248 <entry>Maximum possible birth date.</entry>
6249 </row>
6250
6251 <row xml:id="Biography-BDDist" xreflabel="BDDist">
6252 <entry>BDDist</entry>
6253
6254 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6255 linkend="Biography_Data-BDDist"/></entry>
6256
6257 <entry>Probability distribution of the individual's birth
6258 date estimate.</entry>
6259 </row>
6260
6261 <row xml:id="Biography-Entrydate" xreflabel="Entrydate">
6262 <entry>Entrydate</entry>
6263
6264 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6265 linkend="Biography_Data-Entrydate"/></entry>
6266
6267 <entry>Individual's date of entry into the study.</entry>
6268 </row>
6269
6270 <row xml:id="Biography-Entrytype" xreflabel="Entrytype">
6271 <entry>Entrytype</entry>
6272
6273 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6274 linkend="Biography_Data-Entrytype"/></entry>
6275
6276 <entry>Individual's method of entry into the study.</entry>
6277 </row>
6278
6279 <row xml:id="Biography-Departdate" xreflabel="Departdate">
6280 <entry>Departdate</entry>
6281
6282 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6283 linkend="Biography_Data-Departdate"/></entry>
6284
6285 <entry>Individual's date of departure from the study.</entry>
6286 </row>
6287
6288 <row xml:id="Biography-DepartdateError"
6289 xreflabel="DepartdateError">
6290 <entry>DepartdateError</entry>
6291
6292 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6293 linkend="Biography_Data-DepartdateError"/></entry>
6294
6295 <entry>Degree of error in departure date.</entry>
6296 </row>
6297
6298 <row xml:id="Biography-Departtype" xreflabel="Departtype">
6299 <entry>Departtype</entry>
6300
6301 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6302 linkend="Biography_Data-Departtype"/></entry>
6303
6304 <entry>Method of individual's departure from the
6305 study.</entry>
6306 </row>
6307
6308 <row xml:id="Biography-Import_Datetime"
6309 xreflabel="Import_Datetime">
6310 <entry>ImportDatetime</entry>
6311
6312 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6313 linkend="Biography_Data-Import_Datetime"/></entry>
6314
6315 <entry>Timestamp of import from the master Access
6316 database.</entry>
6317 </row>
6318
6319 <row xml:id="Biography-Twin" xreflabel="Twin">
6320 <entry>Twin</entry>
6321
6322 <entry><xref linkend="TWINS"/>.<xref
6323 linkend="Twins-Twin"/></entry>
6324
6325 <entry>Identifier of the individual's twin.</entry>
6326 </row>
6327
6328 </tbody>
6329 </tgroup>
6330 </informaltable>
6331
6332 </section>
6333
6334 <section xml:id="BIOGRAPHY-Usage-Guidelines">
6335 <title>BIOGRAPHY Usage Guidelines</title>
6336
6337 <section xml:id="BIOGRAPHY-Insert">
6338 <title>INSERTing Into BIOGRAPHY</title>
6339
6340 <para>INSERTing into BIOGRAPHY inserts rows into
6341 <xref linkend="BIOGRAPHY_DATA"/> as expected. A row is
6342 inserted into the <xref linkend="TWINS"/> table if the
6343 <xref linkend="Twins-Twin"/> value is non-&null;, otherwise a
6344 <xref linkend="TWINS"/> row is not inserted.</para>
6345 </section>
6346
6347 <section xml:id="BIOGRAPHY-Update">
6348 <title>UPDATEing BIOGRAPHY</title>
6349
6350 <para>Updating BIOGRAPHY updates the rows of
6351 <xref linkend="BIOGRAPHY_DATA"/> as expected. Setting the
6352 Twin column to &null; results in deletion of a related
6353 <xref linkend="TWINS"/> row, if any exists. Setting the Twin
6354 column to a non-&null; value either updates the existing
6355 <xref linkend="TWINS"/>.<xref linkend="Twins-Twin"/> value or
6356 creates a new <xref linkend="TWINS"/> row, as
6357 necessary.</para>
6358 </section>
6359
6360 <section xml:id="BIOGRAPHY-Delete">
6361 <title>DELETEing from BIOGRAPHY</title>
6362
6363 <para>Deleting rows from BIOGRAPHY deletes rows from
6364 <xref linkend="BIOGRAPHY_DATA"/> and <xref linkend="TWINS"/>,
6365 as expected.</para>
6366 </section>
6367
6368 </section>
6369 </section>
6370
6371 <section xml:id="BIOGRAPHY_UPLOAD" xreflabel="BIOGRAPHY_UPLOAD">
6372 <title>BIOGRAPHY_UPLOAD (Upload into BIOGRAPHY_DATA)</title>
6373
6374 <para>The purpose of the BIOGRAPHY_UPLOAD view is to provide a
6375 convenient interface for uploading the master Access biography
6376 table into the Gombe-MI <xref linkend="BIOGRAPHY_DATA"/> table.
6377 It contains columns for each of the columns in the master Access
6378 biography table, named as they are named in the master
6379 table.</para>
6380
6381 <caution>
6382 <para>Character case is significant in BIOGRAPHY_UPLOAD's column
6383 names. The column names must be written exactly as shown (and
6384 enclosed in double quote characters (") when used in SQL). This
6385 is to match Duke's column names and avoid having to change the
6386 column headings when uploading Duke's data.</para>
6387 </caution>
6388
6389 <para>BIOGRAPHY_UPLOAD provides features upon data INSERT to ease
6390 the upload process. It serves to translate the column names in
6391 the master Access biography table into the column names in
6392 <xref linkend="BIOGRAPHY_DATA"/>. It removes trailing spaces from
6393 all textual columns. The
6394 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-Dad_Prelim"/>
6395 column is set to &true; when the BIOGRAPHY_UPLOAD.B_DadID column
6396 ends in <literal>&gmi_dadid_prelim;</literal> and &false;
6397 otherwise. The suffix <literal>&gmi_dadid_prelim;</literal> is
6398 removed from the BIOGRAPHY_UPLOAD.B_DadID value when it is stored
6399 in the
6400 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-DadID"/>
6401 column.</para>
6402
6403 <section xml:id="BIOGRAPHY_UPLOAD-Definition">
6404 <title>BIOGRAPHY_UPLOAD Definition</title>
6405
6406 <xi:include
6407 href="views/biography_upload.xml"
6408 xmlns:xi="http://www.w3.org/2001/XInclude"/>
6409
6410 <para>Because there is nearly<footnote>
6411
6412 <para>The exception being the
6413 <xref linkend="Biography_Data-Import_Datetime"/> column,
6414 which is not included in the
6415 <xref linkend="BIOGRAPHY_UPLOAD"/> view.</para>
6416
6417 </footnote> a one-to-one match between the columns in this
6418 view and the master Access table there is no additional
6419 documentation of this view's columns. See the &gcdbh; and the
6420 <xref linkend="BIOGRAPHY_DATA"/> table for further
6421 information.</para>
6422 </section>
6423
6424 <section xml:id="BIOGRAPHY_UPLOAD-Usage-Guidelines">
6425 <title>BIOGRAPHY_UPLOAD Usage Guidelines</title>
6426
6427 <para>INSERTing into this view trims trailing spaces from all
6428 inserted textual data. Non-textual data is inserted
6429 unaltered.</para>
6430
6431 <para>Although it is not recommended to do anything other than
6432 INSERT into this view as part of a bulk upload of the master
6433 Access biography table, there are no special restrictions on
6434 the use of this view. SELECT, INSERT, UPDATE, and DELETE are
6435 all allowed and perform the expected operations on the
6436 underlying table.</para>
6437 </section>
6438 </section>
6439
6440 <section xml:id="CHIMPS" xreflabel="CHIMPS">
6441 <title>CHIMPS (Real and Virtual Chimpanzees)</title>
6442
6443 <para>CHIMPS contains one row per <xref linkend="BIOGRAPHY_DATA"/>
6444 row plus one extra row for each twin. The additional rows are
6445 duplicates of each twin, and are used only when the twins are were
6446 indistinguishable in the field (e.g., observers
6447 used <literal>TW1</literal> or <literal>TW2</literal> in place of
6448 the twin's name).</para>
6449
6450 <para>This view should be used for querying instead of
6451 <xref linkend="BIOGRAPHY_DATA"/>, so long as it is safe to
6452 consider the temporary identifiers used when the twins cannot be
6453 distinguished as representative of individuals that are identical
6454 to, but distinct from, the twins themselves.<footnote>
6455
6456 <para>This might be never. Which is why the
6457 <xref linkend="CHIMPIDS"/> table exists; so that use of the
6458 temporary twin identifiers does not imply existence of
6459 additional individuals. Twins will always cause headaches, but
6460 at least the database can recognize the temporary identifiers as
6461 representing virtual rather than real individuals.</para>
6462
6463 <para>Using the <xref linkend="CHIMPS"/> view should be safe
6464 enough when simply retrieving demographic data from
6465 <xref linkend="BIOGRAPHY_DATA"/>, but care must be taken when
6466 using <xref linkend="CHIMPS"/> and doing any sort of counting of
6467 individuals. One way to take care is to pay attention to
6468 <xref linkend="Chimps-AnimID"/> values.</para>
6469
6470 </footnote> The CHIMPS view contains all of
6471 <xref linkend="BIOGRAPHY_DATA"/>'s columns, plus the
6472 <xref linkend="ChimpIDs-ChimpID"/> column, plus the
6473 <xref linkend="Biography_Data-AnimID"/> of the individual's twin,
6474 from <xref linkend="TWINS"/>.<xref linkend="Twins-Twin"/>, if a
6475 twin. Of course in most cases there is no twin and the
6476 <xref linkend="Biography-Twin"/> column will be &null;.<footnote>
6477
6478 <para>Note that while <xref linkend="BIOGRAPHY"/> and
6479 <xref linkend="BIOGRAPHY_DATA"/> have the
6480 <xref linkend="CHIMPS"/> view there is no corresponding view
6481 for <xref linkend="COMMUNITY_MEMBERSHIP"/>, although such a view
6482 could be created.</para>
6483
6484 </footnote></para>
6485
6486 <section xml:id="CHIMPS-Definition">
6487 <title>CHIMPS Definition</title>
6488
6489 <xi:include
6490 href="views/chimps.xml"
6491 xmlns:xi="http://www.w3.org/2001/XInclude"/>
6492
6493 </section>
6494 <section xml:id="Chimps-Columns">
6495 <title>CHIMPS Columns</title>
6496
6497 <informaltable frame="topbot">
6498 <tgroup cols="3" colsep="0" rowsep="0">
6499 <colspec colnum="3" rowsep="1"/>
6500 <thead>
6501 <row rowsep="1">
6502 <entry>Column</entry>
6503 <entry>From</entry>
6504 <entry>Description</entry>
6505 </row>
6506 </thead>
6507 <tbody>
6508 <row xml:id="Chimps-ChimpID" xreflabel="ChimpID">
6509 <entry>ChimpID</entry>
6510
6511 <entry><xref linkend="CHIMPIDS"/>.<xref
6512 linkend="ChimpIDs-ChimpID"/></entry>
6513
6514 <entry>Identifier or alternate identifier of the
6515 individual.</entry>
6516 </row>
6517
6518 <row xml:id="Chimps-AnimID" xreflabel="AnimID">
6519 <entry>AnimID</entry>
6520
6521 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6522 linkend="Biography_Data-AnimID"/></entry>
6523
6524 <entry>Identifier of the individual.</entry>
6525 </row>
6526
6527 <row xml:id="Chimps-AnimID_Num" xreflabel="AnimID_Num">
6528 <entry>AnimID_Num</entry>
6529
6530 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6531 linkend="Biography_Data-AnimID_Num"/></entry>
6532
6533 <entry>Identifier of the individual used in SIV
6534 study.</entry>
6535 </row>
6536
6537 <row xml:id="Chimps-AnimName" xreflabel="AnimName">
6538 <entry>AnimName</entry>
6539
6540 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6541 linkend="Biography_Data-AnimName"/></entry>
6542
6543 <entry>Name of the individual.</entry>
6544 </row>
6545
6546 <row xml:id="Chimps-BirthGroup" xreflabel="BirthGroup">
6547 <entry>BirthGroup</entry>
6548
6549 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6550 linkend="Biography_Data-BirthGroup"/></entry>
6551
6552 <entry>Birth community of the individual.</entry>
6553 </row>
6554
6555 <row xml:id="Chimps-BGCertainty" xreflabel="BGCertainty">
6556 <entry>BGCertainty</entry>
6557
6558 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6559 linkend="Biography_Data-BGCertainty"/></entry>
6560
6561 <entry>Certainty of the individual's birth community.</entry>
6562 </row>
6563
6564 <row xml:id="Chimps-Sex" xreflabel="Sex">
6565 <entry>Sex</entry>
6566
6567 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6568 linkend="Biography_Data-Sex"/></entry>
6569
6570 <entry>Sex of the individual.</entry>
6571 </row>
6572
6573 <row xml:id="Chimps-MomID" xreflabel="MomID">
6574 <entry>MomID</entry>
6575
6576 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6577 linkend="Biography_Data-MomID"/></entry>
6578
6579 <entry>Identifier of the individual's mother.</entry>
6580 </row>
6581
6582 <row xml:id="Chimps-DadID" xreflabel="DadID">
6583 <entry>DadID</entry>
6584
6585 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6586 linkend="Biography_Data-DadID"/></entry>
6587
6588 <entry>Identifier of the individual's father.</entry>
6589 </row>
6590
6591 <row xml:id="Chimps-Dad_Prelim" xreflabel="Dad_Prelim">
6592 <entry>Dad_Prelim</entry>
6593
6594 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6595 linkend="Biography_Data-Dad_Prelim"/></entry>
6596
6597 <entry>Whether paternity is preliminary.</entry>
6598 </row>
6599
6600 <row xml:id="Chimps-Dad_Published" xreflabel="Dad_Published">
6601 <entry>Dad_Published</entry>
6602
6603 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6604 linkend="Biography_Data-Dad_Published"/></entry>
6605
6606 <entry>Whether paternity has been published.</entry>
6607 </row>
6608
6609 <row xml:id="Chimps-FirstBorn" xreflabel="FirstBorn">
6610 <entry>FirstBorn</entry>
6611
6612 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6613 linkend="Biography_Data-FirstBorn"/></entry>
6614
6615 <entry>Whether the individual is the mother's
6616 firstborn.</entry>
6617 </row>
6618
6619 <row xml:id="Chimps-Birthdate" xreflabel="Birthdate">
6620 <entry>Birthdate</entry>
6621
6622 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6623 linkend="Biography_Data-Birthdate"/></entry>
6624
6625 <entry>Birth date of the individual.</entry>
6626 </row>
6627
6628 <row xml:id="Chimps-BDMin" xreflabel="BDMin">
6629 <entry>BDMin</entry>
6630
6631 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6632 linkend="Biography_Data-BDMin"/></entry>
6633
6634 <entry>Minimum possible birth date.</entry>
6635 </row>
6636
6637 <row xml:id="Chimps-BDMax" xreflabel="BDMax">
6638 <entry>BDMax</entry>
6639
6640 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6641 linkend="Biography_Data-BDMax"/></entry>
6642
6643 <entry>Maximum possible birth date.</entry>
6644 </row>
6645
6646 <row xml:id="Chimps-BDDist" xreflabel="BDDist">
6647 <entry>BDDist</entry>
6648
6649 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6650 linkend="Biography_Data-BDDist"/></entry>
6651
6652 <entry>Probability distribution of the individual's birth
6653 date estimate.</entry>
6654 </row>
6655
6656 <row xml:id="Chimps-Entrydate" xreflabel="Entrydate">
6657 <entry>Entrydate</entry>
6658
6659 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6660 linkend="Biography_Data-Entrydate"/></entry>
6661
6662 <entry>Individual's date of entry into the study.</entry>
6663 </row>
6664
6665 <row xml:id="Chimps-Entrytype" xreflabel="Entrytype">
6666 <entry>Entrytype</entry>
6667
6668 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6669 linkend="Biography_Data-Entrytype"/></entry>
6670
6671 <entry>Individual's method of entry into the study.</entry>
6672 </row>
6673
6674 <row xml:id="Chimps-Departdate" xreflabel="Departdate">
6675 <entry>Departdate</entry>
6676
6677 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6678 linkend="Biography_Data-Departdate"/></entry>
6679
6680 <entry>Individual's date of departure from the study.</entry>
6681 </row>
6682
6683 <row xml:id="Chimps-DepartdateError"
6684 xreflabel="DepartdateError">
6685 <entry>DepartdateError</entry>
6686
6687 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6688 linkend="Biography_Data-DepartdateError"/></entry>
6689
6690 <entry>Degree of error in departure date.</entry>
6691 </row>
6692
6693 <row xml:id="Chimps-Departtype" xreflabel="Departtype">
6694 <entry>Departtype</entry>
6695
6696 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6697 linkend="Biography_Data-Departtype"/></entry>
6698
6699 <entry>Method of individual's departure from the
6700 study.</entry>
6701 </row>
6702
6703 <row xml:id="Chimps-Import_Datetime"
6704 xreflabel="Import_Datetime">
6705 <entry>ImportDatetime</entry>
6706
6707 <entry><xref linkend="BIOGRAPHY_DATA"/>.<xref
6708 linkend="Biography_Data-Import_Datetime"/></entry>
6709
6710 <entry>Timestamp of import from the master Access
6711 database.</entry>
6712 </row>
6713
6714 <row xml:id="Chimps-Twin" xreflabel="Twin">
6715 <entry>Twin</entry>
6716
6717 <entry><xref linkend="TWINS"/>.<xref
6718 linkend="Twins-Twin"/></entry>
6719
6720 <entry>Identifier of the individual's twin.</entry>
6721 </row>
6722
6723 </tbody>
6724 </tgroup>
6725 </informaltable>
6726
6727 </section>
6728
6729 <section xml:id="CHIMPS-Usage-Guidelines">
6730 <title>CHIMPS Usage Guidelines</title>
6731
6732 <para>The CHIMPS view cannot be INSERTed into, UPDATEed, or
6733 DELETEd from.</para>
6734
6735 <tip>
6736 <para>Use the <xref linkend="BIOGRAPHY"/> view instead.</para>
6737 </tip>
6738
6739 </section>
6740 </section>
6741
6742 <section xml:id="COMMUNITY_MEMBERSHIP_UPLOAD"
6743 xreflabel="COMMUNITY_MEMBERSHIP_UPLOAD">
6744 <title>COMMUNITY_MEMBERSHIP_UPLOAD (Upload into
6745 COMMUNITY_MEMBERSHIP)</title>
6746 <titleabbrev>COMMUNITY_MEMBERSHIP_UPLOAD (Upload
6747 COMMUNITY_MEMBERSHIP)</titleabbrev>
6748
6749 <para>The purpose of the COMMUNITY_MEMBERSHIP_UPLOAD view is to
6750 provide a convenient interface for uploading the master Access
6751 community_membership table into the Gombe-MI
6752 <xref linkend="COMMUNITY_MEMBERSHIP"/> table. It contains columns
6753 for each of the columns in the master Access community_membership
6754 table, named as they are named in the master table.</para>
6755
6756 <para>COMMUNITY_MEMBERSHIP_UPLOAD provides two features to ease
6757 the upload process. It serves to translate the column names in
6758 the master Access community_membership table into the column names
6759 in <xref linkend="COMMUNITY_MEMBERSHIP"/>. And it removes
6760 trailing spaces from all textual columns.</para>
6761
6762 <section xml:id="COMMUNITY_MEMBERSHIP_UPLOAD-Definition">
6763 <title>COMMUNITY_MEMBERSHIP_UPLOAD Definition</title>
6764
6765 <xi:include
6766 href="views/community_membership_upload.xml"
6767 xmlns:xi="http://www.w3.org/2001/XInclude"/>
6768
6769 <para>Because there is a one-to-one match between the columns in
6770 this view and the master Access table there is no additional
6771 documentation of this view's columns. See the &gcdbh; and the
6772 <xref linkend="COMMUNITY_MEMBERSHIP"/> table for further
6773 information.</para>
6774 </section>
6775
6776 <section xml:id="COMMUNITY_MEMBERSHIP_UPLOAD-Usage-Guidelines">
6777 <title>COMMUNITY_MEMBERSHIP_UPLOAD Usage Guidelines</title>
6778
6779 <para>INSERTing into this view trims trailing spaces from all
6780 inserted textual data. Non-textual data is inserted
6781 unaltered.</para>
6782
6783 <para>Although it is not recommended to do anything other than
6784 INSERT into this view as part of a bulk upload of the master
6785 Access community_membership table, there are no special
6786 restrictions on the use of this view. SELECT, INSERT, UPDATE,
6787 and DELETE are all allowed and perform the expected operations
6788 on the underlying table.</para>
6789 </section>
6790 </section>
6791
6792 </section>
6793
6794 <section xml:id="Follow-Related-Views">
6795 <title>&follow_section; Views</title>
6796
6797 <section xml:id="FOCAL_FOLLOWS" xreflabel="FOCAL_FOLLOWS">
6798 <title>FOCAL_FOLLOWS (Follows and their Focals)</title>
6799
6800 <para>FOCAL_FOLLOWS contains one row per
6801 <xref linkend="FOLLOWS"/> row.</para>
6802
6803 <para>The purpose of the FOCAL_FOLLOWS view is to provide a
6804 convenient interface for deleting and creating follows.</para>
6805
6806 <para>In the case of twins, the column suffixed with the
6807 number <quote>2</quote> always contains the twin with the
6808 <xref linkend="Followparts-ChimpID"/> which is alphabetically
6809 last.</para>
6810
6811 <section xml:id="FOCAL_FOLLOWS-Definition">
6812 <title>FOCAL_FOLLOWS Definition</title>
6813
6814 <xi:include
6815 href="views/focal_follows.xml"
6816 xmlns:xi="http://www.w3.org/2001/XInclude"/>
6817 </section>
6818
6819 <section xml:id="Focal_Follows-Columns">
6820 <title>FOCAL_FOLLOWS Columns</title>
6821
6822 <informaltable frame="topbot">
6823 <tgroup cols="3" colsep="0" rowsep="0">
6824 <colspec colnum="3" rowsep="1"/>
6825 <thead>
6826 <row rowsep="1">
6827 <entry>Column</entry>
6828 <entry>From</entry>
6829 <entry>Description</entry>
6830 </row>
6831 </thead>
6832 <tbody>
6833 <row xml:id="Focal_Follows-FollowID" xreflabel="FollowID">
6834 <entry>FollowID</entry>
6835
6836 <entry><xref linkend="FOLLOWS"/>.<xref
6837 linkend="Follows-FollowID"/></entry>
6838
6839 <entry>Unique integer identifying the follow.</entry>
6840 </row>
6841
6842 <row xml:id="Focal_Follows-Date" xreflabel="Date">
6843 <entry>Date</entry>
6844
6845 <entry><xref linkend="FOLLOWS"/>.<xref
6846 linkend="Follows-Date"/></entry>
6847
6848 <entry>The date of the follow.</entry>
6849 </row>
6850
6851 <row xml:id="Focal_Follows-Mom" xreflabel="Mom">
6852 <entry>Mom</entry>
6853
6854 <entry><xref linkend="FOLLOWPARTS"/>.<xref
6855 linkend="Followparts-ChimpID"/></entry>
6856
6857 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of the
6858 mother in the follow.</entry>
6859 </row>
6860
6861 <row xml:id="Focal_Follows-Infant" xreflabel="Infant">
6862 <entry>Infant</entry>
6863
6864 <entry><xref linkend="FOLLOWPARTS"/>.<xref
6865 linkend="Followparts-ChimpID"/></entry>
6866
6867 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of an
6868 infant in the follow.</entry>
6869 </row>
6870
6871 <row xml:id="Focal_Follows-Infant2" xreflabel="Infant2">
6872 <entry>Infant2</entry>
6873
6874 <entry><xref linkend="FOLLOWPARTS"/>.<xref
6875 linkend="Followparts-ChimpID"/></entry>
6876
6877 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
6878 second infant in the follow, or &null; if the infant
6879 is not a twin.</entry>
6880 </row>
6881
6882 <row xml:id="Focal_Follows-Sib" xreflabel="Sib">
6883 <entry>Sib</entry>
6884
6885 <entry><xref linkend="FOLLOWPARTS"/>.<xref
6886 linkend="Followparts-ChimpID"/></entry>
6887
6888 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
6889 sibling in the follow, or &null; if there is no
6890 sibling focal.</entry>
6891 </row>
6892
6893 <row xml:id="Focal_Follows-Sib2" xreflabel="Sib2">
6894 <entry>Sib2</entry>
6895
6896 <entry><xref linkend="FOLLOWPARTS"/>.<xref
6897 linkend="Followparts-ChimpID"/></entry>
6898
6899 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
6900 second sibling in the follow, or &null; if the sibling
6901 is not a twin.</entry>
6902 </row>
6903
6904 </tbody>
6905 </tgroup>
6906 </informaltable>
6907 </section>
6908
6909 <section xml:id="FOCAL_FOLLOWS-Usage-Guidelines">
6910 <title>FOCAL_FOLLOWS Usage Guidelines</title>
6911
6912 <para>Altering the FOCAL_FOLLOWS view alters the content of the
6913 underlying tables in the fashion described below.</para>
6914
6915 <section xml:id="Focal_Follows-Insert">
6916 <title>INSERT</title>
6917
6918 <para>Inserting a row into the FOCAL_FOLLOWS view inserts a
6919 row into the <xref linkend="FOLLOWS"/> table, as expected.
6920 A row is also inserted into the
6921 <xref linkend="FOLLOWPARTS"/> table for each non-&null;
6922 <xref linkend="Focal_Follows-Mom"/>,
6923 <xref linkend="Focal_Follows-Infant"/>,
6924 <xref linkend="Focal_Follows-Infant2"/>,
6925 <xref linkend="Focal_Follows-Sib"/>, and
6926 <xref linkend="Focal_Follows-Sib2"/> value. The inserted
6927 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-ChimpID"/>
6928 value is the <xref linkend="Focal_Follows-Mom"/>,
6929 <xref linkend="Focal_Follows-Infant"/>,
6930 <xref linkend="Focal_Follows-Infant2"/>,
6931 <xref linkend="Focal_Follows-Sib"/>, or
6932 <xref linkend="Focal_Follows-Sib2"/> value and the
6933 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-Role"/>
6934 value is set to the
6935 corresponding <literal>&gmi_mom_role;</literal>,
6936 <literal>&gmi_infant_role;</literal>,
6937 or <literal>&gmi_sib_role;</literal> value.</para>
6938
6939 <note>
6940 <para>On insert there is no distinction between
6941 <xref linkend="Focal_Follows-Infant"/> and
6942 <xref linkend="Focal_Follows-Infant2"/>, nor a distinction
6943 between <xref linkend="Focal_Follows-Sib"/> and
6944 <xref linkend="Focal_Follows-Sib2"/>. Either may contain
6945 the alphabetically larger
6946 <xref linkend="Followparts-ChimpID"/>, and when not a
6947 twin, either may be &null;.</para>
6948 </note>
6949
6950 <note>
6951 <para>When inserting into FOCAL_FOLLOWS it is not
6952 recommended to set the
6953 <xref linkend="Focal_Follows-FollowID"/> value. Omitting
6954 this column or supplying a &null; value will allow the
6955 system to automatically generate an id.</para>
6956 </note>
6957 </section>
6958
6959 <section xml:id="Focal_Follows-Update">
6960 <title>UPDATE</title>
6961
6962 <para>Updating the columns of the FOCAL_FOLLOWS view updates
6963 the underlying tables as expected with the following
6964 exceptions:</para>
6965
6966 <para>Setting any one of the
6967 <xref linkend="Focal_Follows-Mom"/>,
6968 <xref linkend="Focal_Follows-Infant"/>, or
6969 <xref linkend="Focal_Follows-Sib"/> values to &null; deletes
6970 the corresponding <xref linkend="FOLLOWPARTS"/> row.</para>
6971
6972 <para>Setting any one of the
6973 <xref linkend="Focal_Follows-Mom"/>,
6974 <xref linkend="Focal_Follows-Infant"/>, or
6975 <xref linkend="Focal_Follows-Sib"/> values to non-&null;,
6976 where the original value was &null; inserts a corresponding
6977 row into the <xref linkend="FOLLOWPARTS"/> table as
6978 described above regards insertion into FOCAL_FOLLOWS.</para>
6979
6980 <tip>
6981 <para>Updating the columns of FOCAL_FOLLOWS,
6982 <xref linkend="Focal_Follows-Date"/> excepted, will
6983 probably result in data integrity violations. Deleting
6984 and re-uploading the follow may be a better option.</para>
6985 </tip>
6986
6987 <note>
6988 <para>On update there is no distinction between
6989 <xref linkend="Focal_Follows-Infant"/> and
6990 <xref linkend="Focal_Follows-Infant2"/>, nor a distinction
6991 between <xref linkend="Focal_Follows-Sib"/> and
6992 <xref linkend="Focal_Follows-Sib2"/>. Either may contain
6993 the alphabetically larger
6994 <xref linkend="Followparts-ChimpID"/>, and when not a
6995 twin, either may be &null;.</para>
6996
6997 <para>However, it is an error to attempt
6998 to <quote>swap</quote> twins -- e.g., by setting the
6999 <xref linkend="Focal_Follows-Infant"/> value to the
7000 <xref linkend="Focal_Follows-Infant2"/> value or
7001 vice-versa.</para>
7002 </note>
7003
7004 </section>
7005
7006 <section xml:id="Focal_Follows-Delete">
7007 <title>DELETE</title>
7008
7009 <para>Deleting rows from FOCAL_FOLLOWS deletes rows from the
7010 underlying tables as expected. Because deleting a row from
7011 <xref linkend="FOLLOWS"/> automatically deletes all
7012 information related to the follow this is a convenient way
7013 to remove follows from the database.</para>
7014 </section>
7015
7016 </section>
7017 </section>
7018
7019 <section xml:id="DATASHEETS"
7020 xreflabel="DATASHEETS">
7021 <title>DATASHEETS (A Field Datasheet-Like Report)</title>
7022
7023 <para>DATASHEETS contains one row per <xref linkend="EVENTS"/> row
7024 plus one row per <xref linkend="DISTANCES"/> row. It's purpose is
7025 to produce a report resembling<footnote>
7026
7027 <para>While it is possible to use the <quote>window
7028 function</quote> &postgresql; feature to produce an improved
7029 report-like format by eliminating rectangular areas of empty
7030 space in the query output, this was not deemed important enough
7031 to justify the time required. The reader is left to to
7032 complete this as an exercise in query construction.</para>
7033
7034 </footnote> the data entry sheets.</para>
7035
7036 <para>The columns of the DATASHEETS view resemble the columns on
7037 the field data entry collection sheets. Due to the large number
7038 of these columns and the degree to which data is transformed when
7039 uploaded into GOMBE-MI the details regarding individual columns are
7040 not documented.</para>
7041
7042 <section xml:id="DATASHEETS-Definition">
7043 <title>DATASHEETS Definition</title>
7044
7045 <xi:include
7046 href="views/datasheets.xml"
7047 xmlns:xi="http://www.w3.org/2001/XInclude"/>
7048
7049 <para>The DATASHEETS view is a combination of the
7050 <xref linkend="DATASHEET_EVENTS"/> and
7051 <xref linkend="FAMILY_DISTS"/> views, organized and sorted in
7052 a fashion such that the rows <quote>interleave</quote>. See
7053 the documentation on these views for further detail regards
7054 the content of the DATASHEETS view.</para>
7055
7056 </section>
7057
7058 <section xml:id="DATASHEETS-Usage-Guidelines">
7059 <title>DATASHEETS Usage Guidelines</title>
7060
7061 <para>Only <literal>SELECT</literal> is allowed on
7062 DATASHEETS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
7063 and <literal>DELETE</literal> are not allowed.</para>
7064
7065 <para>Related views which may be used to modify the database
7066 are: <xref linkend="DATASHEET_EVENTS"/>,
7067 <xref linkend="FAMILY_EVENTS"/>,
7068 <xref linkend="FAMILY_DISTS"/>, and
7069 <xref linkend="FOLLOW_INTERVALS"/>.</para>
7070
7071 </section>
7072 </section>
7073
7074 <section xml:id="DATASHEET_EVENTS"
7075 xreflabel="DATASHEET_EVENTS">
7076 <title>DATASHEET_EVENTS (A Field Datasheet-Like Report Of
7077 Behavioral Events)</title>
7078
7079 <para>DATASHEET_EVENTS contains one row per
7080 <xref linkend="EVENTS"/> row. It's primary purpose is to
7081 produce a report resembling the behavioral event portion of the
7082 data entry sheets. It is also possible to use the
7083 DATASHEET_EVENTS view to alter database content. For more on
7084 this see below.</para>
7085
7086 <para>The columns of the DATASHEET_EVENTS view resemble the
7087 behavior related columns on the field data entry collection
7088 sheets. Due to the large number of these columns and the degree
7089 to which data is transformed when uploaded into GOMBE-MI the
7090 details regarding individual columns are not documented.</para>
7091
7092 <para>The overall structure of the DATASHEET_EVENTS view is as
7093 follows: The <xref linkend="FAMILY_EVENTS"/> view is extended,
7094 per possible participant, with all of the columns that appear in
7095 the <xref linkend="EVENTS"/> related <quote>sub-tables</quote>.
7096 So, for example, there are vocalization columns containing
7097 <xref linkend="VOCS"/>.<xref linkend="Vocs-Vocalization"/>
7098 values for each of: mother, infant, sib, and non-focal. If the
7099 behavioral event is not a vocalization or respective individual
7100 is not involved in the behavioral event then the value of the
7101 individual's vocalization column is &null;. If the behavioral
7102 event is a vocalization then the column(s) corresponding to the
7103 individual(s) involved in the event contain the vocalization
7104 made by the respective individual. This pattern is repeated for
7105 all of the <xref linkend="EVENTS"/>
7106 table's <quote>sub-tables</quote>.</para>
7107
7108 <section xml:id="DATASHEET_EVENTS-Definition">
7109 <title>DATASHEET_EVENTS Definition</title>
7110
7111 <xi:include
7112 href="views/datasheet_events.xml"
7113 xmlns:xi="http://www.w3.org/2001/XInclude"/>
7114
7115
7116 <para>The DATASHEET_EVENTS view contains all the columns in
7117 the <xref linkend="FAMILY_EVENTS"/> view. In the interest of
7118 brevity these columns are not documented here. Please refer
7119 to the table describing the
7120 <link linkend="Family_Events-Columns">columns of
7121 FAMILY_EVENTS</link> for information on these columns.</para>
7122
7123 <para>The columns on DATASHEET_EVENTS that are unique to the
7124 view are all from the
7125 <xref linkend="EVENTS"/> <quote>sub-tables</quote>:
7126 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7127 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7128 <xref linkend="RIDES"/>, and <xref linkend="VOCS"/>. Each
7129 column in these <quote>sub-tables</quote> occurs three times
7130 in the DATASHEET_EVENTS view, once for the mother, once for
7131 the infant and once for the sibling. Rather than document
7132 each column 3 times, once for each of the focals, the columns
7133 are documented only once in the table below. The columns
7134 documented below have
7135 either <wordasword>Mom</wordasword>, <wordasword>Infant</wordasword>,
7136 or <wordasword>Sib</wordasword> in place
7137 of <wordasword>&lt;focal&gt;</wordasword> in their column
7138 names.</para>
7139
7140 <para>The exception is the E_&lt;focal&gt;_ride column. There
7141 is no such column for the mother, although there is for the
7142 infant and the sibling.</para>
7143 </section>
7144
7145 <section xml:id="Datasheet_Events-Unique-Columns">
7146 <title>DATASHEET_EVENTS Columns, not in the FAMILY_EVENTS
7147 View</title>
7148
7149 <informaltable frame="topbot">
7150 <tgroup cols="3" colsep="0" rowsep="0">
7151 <colspec colnum="3" rowsep="1"/>
7152 <thead>
7153 <row rowsep="1">
7154 <entry>Column</entry>
7155 <entry>From</entry>
7156 <entry>Description</entry>
7157 </row>
7158 </thead>
7159 <tbody>
7160 <row xml:id="Datasheet_Events-E_Focal_Foodpart"
7161 xreflabel="E_&lt;focal&gt;_Foodpart">
7162 <entry>E_&lt;focal&gt;_Foodpart</entry>
7163
7164 <entry><xref linkend="EATS"/>.<xref
7165 linkend="Eats-Foodpart"/></entry>
7166
7167 <entry>Code indicating the food part eaten by the
7168 focal during the event, or &null; if the focal was not
7169 involved in a eating event.</entry>
7170 </row>
7171
7172 <row xml:id="Datasheet_Events-E_Focal_Foodkind"
7173 xreflabel="E_&lt;focal&gt;_Foodkind">
7174 <entry>E_&lt;focal&gt;_Foodkind</entry>
7175
7176 <entry><xref linkend="EATS"/>.<xref
7177 linkend="Eats-Foodkind"/></entry>
7178
7179 <entry>Code indicating (one of) the food kind(s) eaten
7180 by the focal during the event, or &null; if the focal
7181 was not involved in a eating event.</entry>
7182 </row>
7183
7184 <row xml:id="Datasheet_Events-E_Focal_Fishpart"
7185 xreflabel="E_&lt;focal&gt;_Fishpart">
7186 <entry>E_&lt;focal&gt;_Fishpart</entry>
7187
7188 <entry><xref linkend="FISHED"/>.<xref
7189 linkend="Fished-Foodpart"/></entry>
7190
7191 <entry>Code indicating (one of) the food part(s)
7192 fished for by the focal during the event, or &null; if
7193 the focal was not involved in a fishing event.</entry>
7194 </row>
7195
7196 <row xml:id="Datasheet_Events-E_Focal_Fishkind"
7197 xreflabel="E_&lt;focal&gt;_Fishkind">
7198 <entry>E_&lt;focal&gt;_Fishkind</entry>
7199
7200 <entry><xref linkend="FISHED"/>.<xref
7201 linkend="Fished-Foodkind"/></entry>
7202
7203 <entry>Code indicating the food kind fished for by the
7204 focal during the event, or &null; if the focal was not
7205 involved in a fishing event.</entry>
7206 </row>
7207
7208 <row xml:id="Datasheet_Events-E_Focal_Fishresult"
7209 xreflabel="E_&lt;focal&gt;_Fishresult">
7210 <entry>E_&lt;focal&gt;_Fishresult</entry>
7211
7212 <entry><xref linkend="FISHED"/>.<xref
7213 linkend="Fished-Result"/></entry>
7214
7215 <entry>Code indicating the result of the focal's
7216 fishing attempt, or &null; if the focal was not
7217 involved in a fishing event.</entry>
7218 </row>
7219
7220 <row xml:id="Datasheet_Events-E_Focal_Voc"
7221 xreflabel="E_&lt;focal&gt;_Voc">
7222 <entry>E_&lt;focal&gt;_Voc</entry>
7223
7224 <entry><xref linkend="VOCS"/>.<xref
7225 linkend="Vocs-Vocalization"/></entry>
7226
7227 <entry>Code indicating (one of) the focal's
7228 vocalizations made during the vocalization event, or
7229 &null; if the focal was not involved in a vocalization
7230 event.</entry>
7231 </row>
7232
7233 <row xml:id="Datasheet_Events-E_Focal_Play"
7234 xreflabel="E_&lt;focal&gt;_Play">
7235 <entry>E_&lt;focal&gt;_Play</entry>
7236
7237 <entry><xref linkend="PLAYS"/>.<xref
7238 linkend="Plays-Play"/></entry>
7239
7240 <entry>Code indicating (one of) the focal's play
7241 activities conducted during the playing event, or
7242 &null; if the focal was not involved in a playing
7243 event.</entry>
7244 </row>
7245
7246 <row xml:id="Datasheet_Events-E_Focal_Ride"
7247 xreflabel="E_&lt;focal&gt;_Ride">
7248 <entry>E_&lt;focal&gt;_Ride</entry>
7249
7250 <entry><xref linkend="RIDES"/>.<xref
7251 linkend="Rides-Ride"/></entry>
7252
7253 <entry>Code indicating the focal's riding posture
7254 during the riding event, or &null; if the focal was
7255 not involved in a riding event.</entry>
7256 </row>
7257
7258 <row xml:id="Datasheet_Events-E_Focal_Rest"
7259 xreflabel="E_&lt;focal&gt;_Rest">
7260 <entry>E_&lt;focal&gt;_Rest</entry>
7261
7262 <entry><xref linkend="RESTS"/>.<xref
7263 linkend="Rests-Rest"/></entry>
7264
7265 <entry>Code indicating the focal's resting posture
7266 during the resting event, or &null; if the focal was
7267 not involved in a resting event.</entry>
7268 </row>
7269 </tbody>
7270 </tgroup>
7271 </informaltable>
7272
7273 </section>
7274
7275
7276 <section xml:id="DATASHEET_EVENTS-Usage-Guidelines">
7277 <title>DATASHEET_EVENTS Usage Guidelines</title>
7278
7279 <para>Altering the DATASHEET_EVENTS view alters the content of the
7280 underlying tables in the fashion described below.</para>
7281
7282 <para>Related views which also may be used to modify the
7283 database are: <xref linkend="DATASHEETS"/>,
7284 <xref linkend="FAMILY_EVENTS"/>, and
7285 <xref linkend="FOLLOW_INTERVALS"/>.</para>
7286
7287 <section xml:id="Datasheet_Events-Insert">
7288 <title>INSERT</title>
7289
7290 <para>Inserting into DATASHEET_EVENTS first tests to see if
7291 the inserted row already exists in
7292 <xref linkend="FAMILY_EVENTS"/>. Unlike usual, a &null;
7293 inserted value, or omitting the column from the insert
7294 statement, matches any existent data value.<footnote>
7295
7296 <para>This allows, e.g., id columns to be omitted or
7297 specified as &null;.</para>
7298
7299 </footnote> It is an error if more than one row in
7300 <xref linkend="FAMILY_EVENTS"/> matches the inserted
7301 row.<footnote>
7302
7303 <para>Of course more than one row can be inserted into
7304 DATASHEET events in a single <code>INSERT</code>
7305 statement. The requirement is that each inserted row be
7306 sufficiently specified.</para>
7307
7308 </footnote></para>
7309
7310 <para>If the inserted row does not already exist in
7311 <xref linkend="FAMILY_EVENTS"/>, inserting a row into the
7312 DATASHEET_EVENTS view inserts one row into either the
7313 <xref linkend="FAMILY_EVENTS"/> view, for insertion into the
7314 underlying <xref linkend="EVENTS"/> and
7315 <xref linkend="PARTS"/> tables. For further information see
7316 the <link linkend="Family_Events-Insert">FAMILY_EVENTS
7317 insert documentation</link>.</para>
7318
7319 <para>Inserting into DATASHEET_EVENTS can also insert a row
7320 into the <xref linkend="EVENTS"/> <quote>sub-tables</quote>:
7321 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7322 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7323 <xref linkend="RIDES"/>, and <xref linkend="VOCS"/>. If the
7324 inserted row already exists on
7325 <xref linkend="FAMILY_EVENTS"/> then inserting into
7326 DATASHEET_EVENTS can add additional rows to
7327 the <quote>sub-tables</quote> related to the existing
7328 <xref linkend="EVENTS"/> row; as might be required, for
7329 example, when a single vocalization event is comprised of
7330 are multiple vocalizations .</para>
7331
7332 <para>It is an error to attempt to insert data into an
7333 <xref linkend="EVENTS"/> <quote>sub-table</quote> using a
7334 column pertaining to a focal when that focal is not involved
7335 in the given behavioral event. For example, it is an error
7336 to attempt to use the E_Mom_Voc column to associate a
7337 vocalization with a behavioral event involving only the
7338 infant.<footnote>
7339
7340 <para>As can be seen from
7341 the <link linkend="Family_Events-Update">documentation on
7342 updating FAMILY_EVENTS</link>, the system does not really
7343 care about whether the column name pertains to a
7344 particular focal or not. It's possible for the system to
7345 ignore the focal associated with an
7346 <xref linkend="EVENTS"/> <quote>sub-table</quote> and
7347 simply insert data into the appropriate table, relating it
7348 to the event at hand. However at this point it seems
7349 preferable to have DATASHEET_EVENTS perform this
7350 check.</para>
7351
7352 </footnote></para>
7353 </section>
7354
7355 <section xml:id="Datasheet_Events-Update">
7356 <title>UPDATE</title>
7357
7358 <para>Updating a row in DATASHEET_EVENTS updates a row in
7359 the <xref linkend="FAMILY_EVENTS"/> view, updating the
7360 underlying <xref linkend="EVENTS"/> and
7361 <xref linkend="PARTS"/> tables. For further information see
7362 the <link linkend="Family_Events-Update">FAMILY_EVENTS
7363 update documentation</link>.</para>
7364
7365 <para>Updating DATASHEET_EVENTS can update or delete rows
7366 from <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7367 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7368 <xref linkend="RIDES"/>, and <xref linkend="VOCS"/>.</para>
7369
7370 <note>
7371 <para>The examples below explicitly specify an
7372 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
7373 value. This is solely for the purpose of brevity. Any valid
7374 <code>WHERE</code> clause could be used instead to
7375 designate the desired row in
7376 <xref linkend="EVENTS"/>.</para>
7377 </note>
7378
7379 <para>If the old values for a mom, infant, or sib
7380 <xref linkend="EVENTS"/> <quote>sub-table</quote> row are
7381 not &null; and the new values are all &null; then the old
7382 row is deleted. The following example removes the
7383 mother's <literal>HOO</literal> vocalization from the event
7384 with an
7385 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
7386 of <literal>1234</literal>:</para>
7387
7388 <example>
7389 <title>Deleting The Mother's VOCS Row</title>
7390
7391 <literallayout>
7392 <code>UPDATE datasheet_events
7393 SET e_mom_voc = NULL
7394 WHERE eid = 1234
7395 AND e_mom_voc = 'HOO';</code></literallayout>
7396 </example>
7397
7398 <caution>
7399 <para>If the old vocalization value is not specified then
7400 all <xref linkend="VOCS"/> rows related to the event will
7401 be deleted.</para>
7402 </caution>
7403
7404 <para>If old values exist, they are replaced by new values.
7405 Assuming the mother is involved in a vocalization the event
7406 with an
7407 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
7408 of <literal>1234</literal>, the following example changes
7409 the <literal>UNK</literal> vocalization
7410 to <literal>HOO</literal>:</para>
7411
7412 <example>
7413 <title>Changing A Vocalization</title>
7414
7415 <literallayout>
7416 <code>UPDATE datasheet_events
7417 SET e_mom_voc = 'HOO'
7418 WHERE eid = 1234
7419 AND e_mom_voc = 'UNK';</code></literallayout>
7420 </example>
7421
7422 <note>
7423 <para>The <xref linkend="ChimpIDs-ChimpID"/> values need
7424 not correspond to the roles the individuals play in the
7425 follow because data is associated with chimp id values,
7426 not focal roles. The presence of focal roles in the
7427 column names of the view is, in some sense, artificial.
7428 For example, the following changes the focal involved with
7429 a vocalization event from mother to sibling, and changes
7430 the vocalization made from <literal>UNK</literal>
7431 to <literal>HOO</literal>:</para>
7432
7433 <example>
7434 <title>Changing a Vocalization Event to Involve the
7435 Sibling Instead of the Mom and Changing the Vocalization
7436 Made</title>
7437 <titleabbrev>Changing a Vocalization: Changing focal and
7438 vocalization</titleabbrev>
7439
7440 <literallayout>
7441 <code>UPDATE datsheet_events
7442 SET e_mom_voc = 'HOO'
7443 , e_mom = 'SB' -- SB is the sibling's ChimpID
7444 WHERE eid = 1234
7445 AND e_mom_voc = 'UNK';</code></literallayout>
7446 </example>
7447
7448 <para>The above is sufficient to re-use the exiting
7449 <xref linkend="PARTS"/> row, changing the mother's
7450 <xref linkend="ChimpIDs-ChimpID"/> value to the siblings,
7451 and reuse the existing <xref linkend="VOCS"/> row,
7452 changing the vocalization. When the result is
7453 queried <literal>SB</literal> will show up as a sibling
7454 with a sibling vocalization
7455 of <literal>HOO</literal>.</para>
7456 </note>
7457
7458 <para>Updating &null; values, when all related values are
7459 &null;, in the columns of the <xref linkend="EATS"/>,
7460 <xref linkend="FISHED"/>, <xref linkend="PLAYS"/>,
7461 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, or
7462 <xref linkend="VOCS"/> tables, inserts a new row into one of
7463 these tables.</para>
7464
7465 <para>To insert a new row in <xref linkend="FISHED"/> for
7466 the mother, when all of the mom's <xref linkend="FISHED"/>
7467 data is &null; (E_Mom_Fishpart, E_Mom_Fishkind,
7468 E_Mom_Fishresult), update the mom's <xref linkend="FISHED"/>
7469 data. The following example shows how to do this, changing
7470 an <quote>other</quote> behavior into a fishing
7471 behavior.</para>
7472
7473 <example>
7474 <title>Changing a Mother's Behavior into a Fishing
7475 Behavior and Inserting a FISHED Row For the Mother</title>
7476 <titleabbrev>Changing a Behavior to a Fishing
7477 Behavior</titleabbrev>
7478
7479 <literallayout>
7480 <code>UPDATE datasheet_events
7481 SET behavior = 'F' -- F is fishing
7482 , e_mom_fishpart = 'A'
7483 , e_mom_fishkind = 'B'
7484 , e_mom_fishresult = 'C'
7485 WHERE eid = 1234;</code></literallayout>
7486 </example>
7487
7488 <caution>
7489 <para>As with <xref linkend="FAMILY_EVENTS"/>,
7490 <xref linkend="FAMILY_DISTS"/>, and
7491 <xref linkend="FOLLOW_INTERVALS"/> the focal associated
7492 with the name of the column is not relevant when inserting
7493 new rows via an <code>UPDATE</code> statement. If the
7494 DATASHEET_EVENTS row represents an observation of the
7495 mother vocalizing, setting the E_Infant_Voc value will
7496 give the mother an additional vocalization row on the
7497 <xref linkend="VOCS"/> table.</para>
7498
7499 <para>It is easy to unintentionally add additional rows to
7500 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7501 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7502 <xref linkend="RIDES"/>, or <xref linkend="VOCS"/>. To
7503 avoid this do not attempt to update an existing &null;
7504 value in <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7505 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7506 <xref linkend="RIDES"/>, or <xref linkend="VOCS"/>.
7507 Instead update the non-&null; value, no matter if the
7508 focal is changing and the name of the column containing
7509 the old value does not pertain to the new focal. There is
7510 an example of this above.</para>
7511 </caution>
7512
7513 <para>To insert a new row in <xref linkend="FISHED"/> for
7514 the mother, regardless of whether the mother has existing
7515 related rows on <xref linkend="FISHED"/> for the given
7516 behavioral event, update the infant or sibling's
7517 <xref linkend="FISHED"/> data.<footnote>
7518
7519 <para>The odd nature of this procedure is due to the lack
7520 of <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7521 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7522 <xref linkend="RIDES"/>, or <xref linkend="VOCS"/> id
7523 columns on DATASHEET_EVENTS. Id values could be used to
7524 signal whether an existing row should be altered or a new
7525 row inserted. However, additional id columns would
7526 clutter the view, which already has over-many
7527 columns.</para>
7528
7529 </footnote> The following example shows
7530 how to do this:<footnote>
7531
7532 <para>This works due to the lack of association on update
7533 between the column names and the focal, and because the
7534 infant's column values will always be &null; so changing
7535 them to a non-&null; value causes a row to be
7536 inserted.</para>
7537
7538 </footnote></para>
7539
7540 <example>
7541 <title>Unconditionally Inserting a FISHED Row For the
7542 Mother</title>
7543
7544 <literallayout>
7545 <code>UPDATE datasheet_events
7546 SET e_infant_fishpart = 'A' -- note change of "infant's" data
7547 , e_infant_fishkind = 'B'
7548 , e_infant_fishresult = 'C'
7549 WHERE eid = 1234;</code></literallayout>
7550 </example>
7551
7552 <para>It is an error to attempt to update the values of any
7553 columns not derived from the <xref linkend="EVENTS"/>,
7554 <xref linkend="PARTS"/>, <xref linkend="EATS"/>,
7555 <xref linkend="FISHED"/>, <xref linkend="PLAYS"/>,
7556 <xref linkend="RESTS"/>, <xref linkend="RIDES"/>, or
7557 <xref linkend="VOCS"/> tables. It is also an error to
7558 attempt to change the
7559 <xref linkend="Family_Events-E_BaboonPart"/> value.</para>
7560
7561 <para>When updated, DATASHEET_EVENTS raises a notice
7562 containing the number of rows altered. A row is counted
7563 only once, when updating the row changes the database
7564 content in any way.</para>
7565 </section>
7566
7567 <section xml:id="Datasheet_Events-Delete">
7568 <title>Delete</title>
7569
7570 <para>Deleting rows from the DATASHEET_EVENTS view deletes
7571 rows from <xref linkend="EVENTS"/>, <xref linkend="PARTS"/>,
7572 <xref linkend="EATS"/>, <xref linkend="FISHED"/>,
7573 <xref linkend="PLAYS"/>, <xref linkend="RESTS"/>,
7574 <xref linkend="RIDES"/>, and <xref linkend="VOCS"/> tables
7575 as expected.</para>
7576 </section>
7577 </section>
7578 </section>
7579
7580 <section xml:id="FOLLOW_DURATIONS" xreflabel="FOLLOW_DURATIONS">
7581 <title>FOLLOW_DURATIONS (Duration of the Follow)</title>
7582
7583 <para>FOLLOW_DURATION contains one row per follow. It's purpose
7584 is to compute the various totals regards observation time per
7585 follow.</para>
7586
7587 <section xml:id="FOLLOW_DURATIONS-Definition">
7588 <title>FOLLOW_DURATIONS Definition</title>
7589
7590 <xi:include
7591 href="views/follow_durations.xml"
7592 xmlns:xi="http://www.w3.org/2001/XInclude"/>
7593 </section>
7594
7595 <section xml:id="Follow_Durations-Columns">
7596 <title>FOLLOW_DURATIONS Columns</title>
7597
7598 <informaltable frame="topbot">
7599 <tgroup cols="3" colsep="0" rowsep="0">
7600 <colspec colnum="3" rowsep="1"/>
7601 <thead>
7602 <row rowsep="1">
7603 <entry>Column</entry>
7604 <entry>From</entry>
7605 <entry>Description</entry>
7606 </row>
7607 </thead>
7608 <tbody>
7609 <row xml:id="Follow_Durations-FollowID" xreflabel="FollowID">
7610 <entry>FollowID</entry>
7611
7612 <entry><xref linkend="FOLLOWS"/>.<xref
7613 linkend="Follows-FollowID"/></entry>
7614
7615 <entry>Unique integer identifying the follow.</entry>
7616 </row>
7617
7618 <row xml:id="Follow_Durations-FollowMins"
7619 xreflabel="FollowMins">
7620 <entry>FollowMins (Attempted Observational Minutes)</entry>
7621
7622 <entry>Computed</entry>
7623
7624 <entry>The number of minutes during which observations
7625 where attempted.</entry>
7626 </row>
7627
7628 <row xml:id="Follow_Durations-EmptyMins" xreflabel="EmptyMins">
7629 <entry>EmptyMins (Bad Observational Minutes)</entry>
7630
7631 <entry>Computed</entry>
7632
7633 <entry>The number of minutes during which observations
7634 where attempted but no data was collected. No data is
7635 collected if there are no <xref linkend="EVENTS"/>
7636 rows related to the interval and no
7637 <xref linkend="DISTANCES"/> rows related to the
7638 interval.</entry>
7639 </row>
7640
7641 <row xml:id="Follow_Durations-SpanMins" xreflabel="SpanMins">
7642 <entry>SpanMins (Span of Minutes in Follow)</entry>
7643
7644 <entry>Computed.</entry>
7645
7646 <entry>The number of minutes, including endpoints,
7647 between the first observation of the
7648 follow and the last observation of the follow.</entry>
7649 </row>
7650 </tbody>
7651 </tgroup>
7652 </informaltable>
7653 </section>
7654
7655 <section>
7656 <title>Operations allowed</title>
7657
7658 <para>Only <literal>SELECT</literal> is allowed on
7659 FOLLOW_DURATION. <literal>INSERT</literal>, <literal>UPDATE</literal>,
7660 and <literal>DELETE</literal> are not allowed.</para>
7661 </section>
7662 </section>
7663
7664
7665 <section xml:id="FOLLOW_INTERVALS" xreflabel="FOLLOW_INTERVALS">
7666 <title>FOLLOW_INTERVALS (Follows and their Intervals)</title>
7667
7668 <para>FOLLOW_INTERVALS contains one row per
7669 <xref linkend="FOLLOWS"/> row per <xref linkend="INTERVALS"/>
7670 row. So, one row per minute of each follow.</para>
7671
7672 <para>The purpose of the FOLLOW_INTERVALS view is to provide a
7673 convenient interface for deleting, creating, and altering
7674 <xref linkend="INTERVALS"/> rows and for creating
7675 <xref linkend="SHEETS"/> and <xref linkend="FIELDFOLLOWS"/>
7676 rows.</para>
7677
7678 <para>See the description of the <xref linkend="FOCAL_FOLLOWS"/>
7679 view for more information regarding the handling of
7680 twins.</para>
7681
7682 <section xml:id="FOLLOW_INTERVALS-Definition">
7683 <title>FOLLOW_INTERVALS Definition</title>
7684
7685 <xi:include
7686 href="views/follow_intervals.xml"
7687 xmlns:xi="http://www.w3.org/2001/XInclude"/>
7688 </section>
7689
7690 <section xml:id="Follow_Intervals-Columns">
7691 <title>FOLLOW_INTERVALS Columns</title>
7692
7693 <informaltable frame="topbot">
7694 <tgroup cols="3" colsep="0" rowsep="0">
7695 <colspec colnum="3" rowsep="1"/>
7696 <thead>
7697 <row rowsep="1">
7698 <entry>Column</entry>
7699 <entry>From</entry>
7700 <entry>Description</entry>
7701 </row>
7702 </thead>
7703 <tbody>
7704 <row xml:id="Follow_Intervals-FollowID" xreflabel="FollowID">
7705 <entry>FollowID</entry>
7706
7707 <entry><xref linkend="FOLLOWS"/>.<xref
7708 linkend="Follows-FollowID"/></entry>
7709
7710 <entry>Unique integer identifying the follow.</entry>
7711 </row>
7712
7713 <row xml:id="Follow_Intervals-IntID" xreflabel="IntID">
7714 <entry>IntID</entry>
7715
7716 <entry><xref linkend="INTERVALS"/>.<xref
7717 linkend="Intervals-IntID"/></entry>
7718
7719 <entry>Unique integer identifying the interval.</entry>
7720 </row>
7721
7722 <row xml:id="Follow_Intervals-SheetID" xreflabel="SheetID">
7723 <entry>SheetID</entry>
7724
7725 <entry><xref linkend="INTERVALS"/>.<xref
7726 linkend="Intervals-SheetID"/></entry>
7727
7728 <entry>The integer identifying the data collection
7729 sheet on which the interval was recorded.</entry>
7730 </row>
7731
7732 <row xml:id="Follow_Intervals-FFID" xreflabel="FFID">
7733 <entry>FFID</entry>
7734
7735 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7736 linkend="Fieldfollows-FFID"/></entry>
7737
7738 <entry>The integer identifying the field follow, the
7739 set of sheets collected by a researcher in the field
7740 comprising a day's mother-infant follow, in which the
7741 sheet belongs.</entry>
7742 </row>
7743
7744 <row xml:id="Follow_Intervals-Date" xreflabel="Date">
7745 <entry>Date</entry>
7746
7747 <entry><xref linkend="FOLLOWS"/>.<xref
7748 linkend="Follows-Date"/></entry>
7749
7750 <entry>The date of the follow.</entry>
7751 </row>
7752
7753 <row xml:id="Follow_Intervals-Mom" xreflabel="Mom">
7754 <entry>Mom</entry>
7755
7756 <entry><xref linkend="FOLLOWPARTS"/>.<xref
7757 linkend="Followparts-ChimpID"/></entry>
7758
7759 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of the
7760 mother in the follow.</entry>
7761 </row>
7762
7763 <row xml:id="Follow_Intervals-Infant" xreflabel="Infant">
7764 <entry>Infant</entry>
7765
7766 <entry><xref linkend="FOLLOWPARTS"/>.<xref
7767 linkend="Followparts-ChimpID"/></entry>
7768
7769 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of an
7770 infant in the follow.</entry>
7771 </row>
7772
7773 <row xml:id="Follow_Intervals-Infant2" xreflabel="Infant2">
7774 <entry>Infant2</entry>
7775
7776 <entry><xref linkend="FOLLOWPARTS"/>.<xref
7777 linkend="Followparts-ChimpID"/></entry>
7778
7779 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
7780 twin infant in the follow, or &null; when the infant
7781 is not a twin.</entry>
7782 </row>
7783
7784 <row xml:id="Follow_Intervals-Sib" xreflabel="Sib">
7785 <entry>Sib</entry>
7786
7787 <entry><xref linkend="FOLLOWPARTS"/>.<xref
7788 linkend="Followparts-ChimpID"/></entry>
7789
7790 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
7791 sibling in the follow, or &null; when there is not
7792 sibling focal in the follow.</entry>
7793 </row>
7794
7795 <row xml:id="Follow_Intervals-Sib2" xreflabel="Sib2">
7796 <entry>Sib2</entry>
7797
7798 <entry><xref linkend="FOLLOWPARTS"/>.<xref
7799 linkend="Followparts-ChimpID"/></entry>
7800
7801 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
7802 twin sibling in the follow, or &null; when there is no
7803 sibling or the sibling is not a twin.</entry>
7804 </row>
7805
7806 <row xml:id="Follow_Intervals-Time" xreflabel="Time">
7807 <entry>Time</entry>
7808
7809 <entry><xref linkend="INTERVALS"/>.<xref
7810 linkend="Intervals-Time"/></entry>
7811
7812 <entry>The time of the interval.</entry>
7813 </row>
7814
7815 <row xml:id="Follow_Intervals-GID" xreflabel="GID">
7816 <entry>GID</entry>
7817
7818 <entry><xref linkend="INTERVALS"/>.<xref
7819 linkend="Intervals-GID"/></entry>
7820
7821 <entry>The identifier of the group composition related
7822 to the interval. The system will automatically
7823 compute this when a &null; value is supplied upon
7824 insert or update.</entry>
7825 </row>
7826
7827 <row xml:id="Follow_Intervals-Comment" xreflabel="Comment">
7828 <entry>Comment</entry>
7829
7830 <entry><xref linkend="INTERVALS"/>.<xref
7831 linkend="Intervals-Comment"/></entry>
7832
7833 <entry>The comment on the interval.</entry>
7834 </row>
7835
7836 <row xml:id="Follow_Intervals-Followtype" xreflabel="Followtype">
7837 <entry>Followtype</entry>
7838
7839 <entry><xref linkend="SHEETS"/>.<xref
7840 linkend="Sheets-Followtype"/></entry>
7841
7842 <entry>Code indicating the data collected on the data
7843 collection sheet.</entry>
7844 </row>
7845
7846 <row xml:id="Follow_Intervals-Page" xreflabel="Page">
7847 <entry>Page</entry>
7848
7849 <entry><xref linkend="SHEETS"/>.<xref
7850 linkend="Sheets-Page"/></entry>
7851
7852 <entry>The page number on the field data collection
7853 sheet.</entry>
7854 </row>
7855
7856 <row xml:id="Follow_Intervals-Location" xreflabel="Location">
7857 <entry>Location</entry>
7858
7859 <entry><xref linkend="SHEETS"/>.<xref
7860 linkend="Sheets-Location"/></entry>
7861
7862 <entry>The valley location information on the field
7863 data collection sheet.</entry>
7864 </row>
7865
7866 <row xml:id="Follow_Intervals-Collector" xreflabel="Collector">
7867 <entry>Collector</entry>
7868
7869 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7870 linkend="Fieldfollows-Collector"/></entry>
7871
7872 <entry>The field researcher who collected the
7873 information on the field data collection
7874 sheet.</entry>
7875 </row>
7876
7877 <row xml:id="Follow_Intervals-Entrydate" xreflabel="Entrydate">
7878 <entry>Entrydate</entry>
7879
7880 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7881 linkend="Fieldfollows-Entrydate"/></entry>
7882
7883 <entry>The date the data entry technician converted
7884 the information on the field data collection sheet
7885 into electronic form.</entry>
7886 </row>
7887
7888 <row xml:id="Follow_Intervals-Enterer" xreflabel="Enterer">
7889 <entry>Enterer</entry>
7890
7891 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7892 linkend="Fieldfollows-Enterer"/></entry>
7893
7894 <entry>The data entry technician who converted the
7895 information on the field data collection sheet into
7896 electronic form.</entry>
7897 </row>
7898
7899 <row xml:id="Follow_Intervals-UploadDate" xreflabel="UploadDate">
7900 <entry>UploadDate</entry>
7901
7902 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7903 linkend="Fieldfollows-UploadDate"/></entry>
7904
7905 <entry>The date and time the information on the field
7906 data collection sheet was uploaded into into the
7907 database.</entry>
7908 </row>
7909
7910 <row xml:id="Follow_Intervals-GCStatus" xreflabel="GCStatus">
7911 <entry>GCStatus</entry>
7912
7913 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
7914 linkend="Fieldfollows-GCStatus"/></entry>
7915
7916 <entry>The code indicating the status of the group
7917 composition information, or &null; if there is no
7918 group composition information.</entry>
7919 </row>
7920
7921 </tbody>
7922 </tgroup>
7923 </informaltable>
7924 </section>
7925
7926 <section xml:id="FOLLOW_INTERVALS-Usage-Guidelines">
7927 <title>FOLLOW_INTERVALS Usage Guidelines</title>
7928
7929 <para>Altering the FOLLOW_INTERVALS view alters the content of
7930 the underlying <xref linkend="INTERVALS"/> table in the
7931 fashion described below. Inserting into FOLLOW_INTERVALS can
7932 also insert into the <xref linkend="SHEETS"/> and
7933 <xref linkend="FIELDFOLLOWS"/> table. The
7934 <xref linkend="FOLLOWS"/> and related
7935 <xref linkend="FOLLOWPARTS"/> rows must exist; the content of
7936 these tables is never altered.</para>
7937
7938 <section xml:id="Follow_Intervals-Insert">
7939 <title>INSERT</title>
7940
7941 <para>Inserting a row into the FOLLOW_INTERVALS view inserts
7942 a row into the <xref linkend="INTERVALS"/> table, as
7943 expected.</para>
7944
7945 <para>When inserting <xref linkend="INTERVALS"/> rows using
7946 FOLLOW_INTERVALS the follow must be specified. The follow
7947 may be specified in either or both of the following 2
7948 ways:</para>
7949
7950 <itemizedlist>
7951 <listitem>
7952 <para>A <xref linkend="Follow_Intervals-FollowID"/> may be
7953 supplied.</para>
7954 </listitem>
7955
7956 <listitem>
7957 <para><xref linkend="Follow_Intervals-Date"/>,
7958 <xref linkend="Follow_Intervals-Mom"/> and,
7959 <xref linkend="Follow_Intervals-Infant"/>
7960 values <emphasis>all</emphasis> may be supplied.</para>
7961
7962 <note xml:id="follow_intervals-twins">
7963 <para>In the case of twins, either twin may be supplied
7964 as the <xref linkend="Follow_Intervals-Infant"/>, or the
7965 <xref linkend="Follow_Intervals-Infant2"/> (or likewise
7966 with the sibling columns). The correct follow will be
7967 identified so long as the indicated twin is a focal in
7968 the follow.</para>
7969
7970 <para>However, if a <code>RETURNING</code> clause is
7971 used the twins will be returned in column names as if
7972 queried, irrespective of how specified in the inserted
7973 values.</para>
7974 </note>
7975 </listitem>
7976 </itemizedlist>
7977
7978 <caution>
7979 <para>FOLLOW_INTERVALS inserts only when there is a
7980 <xref linkend="FOLLOWS"/> row that matches the above
7981 selection criteria. If no row matches the database
7982 content is not altered. Note that no row will match if
7983 conflicting information is supplied.</para>
7984 </caution>
7985
7986 <note>
7987 <para>When inserting into FOLLOW_INTERVALS it is not
7988 recommended to set the
7989 <xref linkend="Follow_Intervals-IntID"/> value. Omitting
7990 this column or supplying a &null; value will allow the
7991 system to automatically generate an id.</para>
7992 </note>
7993
7994 <para>Inserting a row into FOLLOW_INTERVALS will also insert
7995 a row into <xref linkend="SHEETS"/> if the specified related
7996 <xref linkend="SHEETS"/> row does not already exist.</para>
7997
7998 <para>The related <xref linkend="SHEETS"/> row may be
7999 specified in either or both of the following 2 ways:</para>
8000
8001 <itemizedlist>
8002 <listitem>
8003 <para>A <xref linkend="Follow_Intervals-SheetID"/> value
8004 may be supplied.</para>
8005 </listitem>
8006
8007 <listitem>
8008 <para>A <xref linkend="Follow_Intervals-Page"/> value may
8009 be supplied.</para>
8010 </listitem>
8011 </itemizedlist>
8012
8013 <para>Additional <xref linkend="SHEETS"/> column values may
8014 be supplied. (The
8015 <xref linkend="Follow_Intervals-Followtype"/>,
8016 <xref linkend="Follow_Intervals-Location"/>, and
8017 <xref linkend="Follow_Intervals-FFID"/> values.) As usual,
8018 omitting any column is the same as specifying a &null;
8019 value. It is an error for any of the supplied, non-&null;,
8020 values to conflict with the content of an existing
8021 <xref linkend="SHEETS"/> row when the row is related to the
8022 newly inserted <xref linkend="INTERVALS"/> row. If there is
8023 no existing <xref linkend="SHEETS"/> row then the supplied
8024 values are stored in a newly created
8025 <xref linkend="SHEETS"/> row.</para>
8026
8027 <note>
8028 <para>When inserting into FOLLOW_INTERVALS and creating a
8029 new <xref linkend="SHEETS"/> row it is not recommended to
8030 set the <xref linkend="Follow_Intervals-SheetID"/> value.
8031 Omitting this column or supplying a &null; value will
8032 allow the system to automatically generate an id.</para>
8033 </note>
8034
8035 <para>Inserting a row into FOLLOW_INTERVALS will also insert
8036 a row into <xref linkend="FIELDFOLLOWS"/> if the specified
8037 related <xref linkend="FIELDFOLLOWS"/> row does not already
8038 exist.</para>
8039
8040 <para>The related <xref linkend="FIELDFOLLOWS"/> row may be
8041 specified in either or both of the following 2 ways:</para>
8042
8043 <itemizedlist>
8044 <listitem>
8045 <para>A <xref linkend="Follow_Intervals-FFID"/> value
8046 may be supplied.</para>
8047 </listitem>
8048
8049 <listitem>
8050 <para>A <xref linkend="Follow_Intervals-Collector"/> value may
8051 be supplied.</para>
8052
8053 <note>
8054 <para>Supplying a
8055 <xref linkend="Follow_Intervals-Collector"/> value
8056 serves to identify a <xref linkend="FIELDFOLLOWS"/> row
8057 only when there is already a relationship between the
8058 follow and a field follow conducted by the designated
8059 collector. If the field data collector is not already
8060 in the database as having collected data for the follow,
8061 (or has, for some reason, performed more than one bout
8062 of data collection regards the follow) then the system
8063 cannot use the collector to identify a single, existent,
8064 field follow to relate to the new interval.</para>
8065 </note>
8066
8067 </listitem>
8068 </itemizedlist>
8069
8070 <para>Additional <xref linkend="FIELDFOLLOWS"/> column
8071 values may be supplied. (The
8072 <xref linkend="Follow_Intervals-Entrydate"/>,
8073 <xref linkend="Follow_Intervals-Enterer"/>,
8074 <xref linkend="Follow_Intervals-UploadDate"/>,
8075 <xref linkend="Follow_Intervals-GCStatus"/> values.) As
8076 usual, omitting any column is the same as specifying a
8077 &null; value. It is an error for any of the supplied,
8078 non-&null;, values to conflict with the content of an
8079 existing <xref linkend="FIELDFOLLOWS"/> row when the row is
8080 related to the newly inserted <xref linkend="INTERVALS"/>
8081 row. If there is no existing <xref linkend="FIELDFOLLOWS"/>
8082 row then the supplied values are stored in a newly created
8083 <xref linkend="FIELDFOLLOWS"/> row.</para>
8084
8085 <note>
8086 <para>When inserting into FOLLOW_INTERVALS and creating a
8087 new <xref linkend="FIELDFOLLOWS"/> row it is not
8088 recommended to set the
8089 <xref linkend="Follow_Intervals-FFID"/> value. Omitting
8090 this column or supplying a &null; value will allow the
8091 system to automatically generate an id.</para>
8092 </note>
8093
8094 <note>
8095 <para>While the system does not dis-allow multiple
8096 <xref linkend="FIELDFOLLOWS"/> row per
8097 <xref linkend="Fieldfollows-Collector"/> per
8098 <xref linkend="FOLLOWS"/> row, just in case a single
8099 researcher's daily follow sheets of a single mother/infant
8100 pair are somehow separated into two packets that are
8101 subsequently entered into the system at different times,
8102 inserting into FOLLOW_INTERVALS ensures that there is
8103 always a single <xref linkend="FIELDFOLLOWS"/> row per
8104 field data collector per date per mother/infant
8105 pair.</para>
8106 </note>
8107
8108 </section>
8109
8110 <section xml:id="Follow_Intervals-Update">
8111 <title>UPDATE</title>
8112
8113 <para>Updating the columns of the FOLLOW_INTERVALS view
8114 updates the underlying <xref linkend="INTERVALS"/> table as
8115 expected.</para>
8116
8117 <para>It is an error to attempt to update the values of any
8118 columns not derived from the <xref linkend="INTERVALS"/>
8119 table.</para>
8120 </section>
8121
8122 <section xml:id="Follow_Intervals-Delete">
8123 <title>DELETE</title>
8124
8125 <para>Deleting rows from FOLLOW_INTERVALS deletes rows from
8126 the underlying <xref linkend="INTERVALS"/> table as
8127 expected. Because deleting a row from
8128 <xref linkend="INTERVALS"/> automatically deletes all
8129 information related to the interval this is a convenient way
8130 to remove intervals from the database.</para>
8131 </section>
8132
8133 </section>
8134 </section>
8135
8136
8137 <section xml:id="UPLOAD_BEHAVIORS"
8138 xreflabel="UPLOAD_BEHAVIORS">
8139 <title>UPLOAD_BEHAVIORS (Facility for uploading follow data)</title>
8140
8141 <para>This view returns no rows, it is used only to upload follow
8142 data. This view exists instead of a custom upload program.</para>
8143
8144 <para>The columns of the UPLOAD_BEHAVIORS view resemble the
8145 columns on the field data entry collection sheets. Only some of
8146 these columns are required, others may be present or omitted
8147 depending on the template type of the sheet used in the field.
8148 Omitting a column is equivalent to including the column and
8149 specifying a &null; value for all the column's rows. Required
8150 columns are either documented as such below or are required to
8151 have non-&null; values in the database.</para>
8152
8153 <note>
8154 <para>The UPLOAD_BEHAVIORS view does not validate the existence
8155 or absence of specific columns based on the template type. It
8156 is up to the data entry staff to use the correct columns.</para>
8157 </note>
8158
8159 <!-- The following warning belonges somewhere else in the document. -->
8160
8161 <note>
8162 <para>Depending on the program used to upload data into this
8163 view, the case of the column names can be significant. All
8164 column names, in this view and everywhere else in Gombe-MI, are
8165 in lower case. Column names are written here in mixed case as a
8166 lexical convention so that column names can be easily discerned
8167 from regular text. The use of the underscore character in place
8168 of spaces in the column names is always significant.</para>
8169
8170 <para>It is recommended to always use lower case column names
8171 when uploading data.</para>
8172 </note>
8173
8174 <para><xref linkend="ChimpIDs-ChimpID"/> values of the focals
8175 are not required to be consistent throughout the follow. The
8176 first row containing data for any given follow will have it's
8177 ChimpID values used as
8178 <xref linkend="FOLLOWPARTS"/>.<xref linkend="Followparts-ChimpID"/>
8179 values. The ChimpID values supplied in each line uploaded are
8180 used as
8181 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
8182 values for the behavioral interactions the line records and as
8183 <xref linkend="DISTANCEPARTS"/>.<xref
8184 linkend="Distanceparts-Participant"/>
8185 values for the inter-focal distances the line records. The
8186 <xref linkend="Biography_Data-AnimID"/> values of the focals
8187 must remain consistent from line to line of any given focal, but
8188 the <xref linkend="ChimpIDs-ChimpID"/> used may vary from line
8189 to line.</para>
8190
8191 <para>If any of a follow's uploaded lines contains a
8192 <xref linkend="Upload_Behaviors-Sibling"/> value then all the
8193 uploaded lines for the follow must contain a
8194 <xref linkend="Upload_Behaviors-Sibling"/> value. This is true
8195 not only for the lines uploaded in any given file but is also
8196 must be the case if a follow's lines are uploaded in multiple
8197 files.</para>
8198
8199 <para>If <xref linkend="Upload_Behaviors-Sibling"/> is &null;
8200 then it is an error for any of the following columns to contain
8201 data:</para>
8202
8203 <itemizedlist>
8204 <listitem><para><xref
8205 linkend="Upload_Behaviors-Sib_Bad_Observation"/></para></listitem>
8206 <listitem><para><xref
8207 linkend="Upload_Behaviors-Sib_Behavior"/></para></listitem>
8208 <listitem><para><xref
8209 linkend="Upload_Behaviors-Sib_Play"/></para></listitem>
8210 <listitem><para><xref
8211 linkend="Upload_Behaviors-Sib_Foodpart"/></para></listitem>
8212 <listitem><para><xref
8213 linkend="Upload_Behaviors-Sib_Foodkind"/></para></listitem>
8214 <listitem><para><xref
8215 linkend="Upload_Behaviors-Sib_Fishpart"/></para></listitem>
8216 <listitem><para><xref
8217 linkend="Upload_Behaviors-Sib_Fishkind"/></para></listitem>
8218 <listitem><para><xref
8219 linkend="Upload_Behaviors-Sib_Grooming"/></para></listitem>
8220 <listitem><para><xref
8221 linkend="Upload_Behaviors-Sib_Groomed_By"/></para></listitem>
8222 <listitem><para><xref
8223 linkend="Upload_Behaviors-Sib_Ride"/></para></listitem>
8224 <listitem><para><xref
8225 linkend="Upload_Behaviors-Sib_Distance_To_Ma"/></para></listitem>
8226 <listitem><para><xref
8227 linkend="Upload_Behaviors-Sib_Distance_To_Infant"/></para></listitem>
8228 <listitem><para><xref
8229 linkend="Upload_Behaviors-Sib_Voc"/></para></listitem>
8230 </itemizedlist>
8231
8232 <para>The time values,
8233 <xref linkend="Upload_Behaviors-Time_Converted_Mil"/>, in the
8234 uploaded lines cannot decrease when examined in line-number order
8235 on a per-fieldfollow basis (i.e. per
8236 date/mom/field-data-collector). However, subsequent uploads may
8237 add new intervals to an existing follow irrespective of the times
8238 of pre-existent behavioral intervals.</para>
8239
8240 <para>The page number values,
8241 <xref linkend="Upload_Behaviors-Page"/>, in the uploaded lines
8242 cannot decrease when examined in line-number order on a
8243 per-fieldfollow basis. However, a &null; page number can occur on
8244 any line. Further, this restriction is per file uploaded.
8245 Subsequent uploads may add additional behavioral information to
8246 any existing or newly uploaded page regardless of page
8247 number.</para>
8248
8249 <para xml:id="Bad_Obs">The
8250 <xref linkend="Upload_Behaviors-Bad_Observation"/> column
8251 affects the certitude of all data recorded on the line. It may
8252 contain the following values:</para>
8253
8254 <variablelist>
8255 <varlistentry>
8256 <term>No characters or &null;</term>
8257
8258 <listitem>
8259 <para>All the data
8260 recorded on the line is certain, unless another column's
8261 value indicates otherwise.</para>
8262 </listitem>
8263 </varlistentry>
8264
8265 <varlistentry>
8266 <term><literal>&gmi_badobs_y;</literal>
8267 or <literal>&gmi_badobs_w;</literal></term>
8268
8269 <listitem>
8270 <para>All the data recorded on the line is uncertain.</para>
8271 </listitem>
8272 </varlistentry>
8273
8274 <varlistentry>
8275 <term><literal>&gmi_badobs_m;</literal></term>
8276
8277 <listitem>
8278 <para>The data related to the mother is uncertain.</para>
8279 </listitem>
8280 </varlistentry>
8281
8282 <varlistentry>
8283 <term><literal>&gmi_badobs_i;</literal>
8284 or <literal>&gmi_badobs_t;</literal></term>
8285
8286 <listitem>
8287 <para>The data related to the infant is uncertain.</para>
8288 </listitem>
8289 </varlistentry>
8290
8291 <varlistentry>
8292 <term><literal>&gmi_badobs_s;</literal>
8293 or <literal>&gmi_badobs_k;</literal></term>
8294
8295 <listitem>
8296 <para>The data related to the sibling is uncertain.</para>
8297 </listitem>
8298 </varlistentry>
8299
8300 <varlistentry>
8301 <term><literal>&gmi_badobs_mi;</literal>
8302 or <literal>&gmi_badobs_mt;</literal></term>
8303
8304 <listitem>
8305 <para>The data related to the mother and the data related to
8306 the infant is uncertain.</para>
8307 </listitem>
8308 </varlistentry>
8309
8310 <varlistentry>
8311 <term><literal>&gmi_badobs_ms;</literal>
8312 or <literal>&gmi_badobs_mk;</literal></term>
8313
8314 <listitem>
8315 <para>The data related to the mother and the data related to
8316 the sibling is uncertain.</para>
8317 </listitem>
8318 </varlistentry>
8319
8320 <varlistentry>
8321 <term><literal>&gmi_badobs_is;</literal>
8322 or <literal>&gmi_badobs_kt;</literal></term>
8323
8324 <listitem>
8325 <para>The data related to the infant and the data related to
8326 the sibling is uncertain.</para>
8327 </listitem>
8328 </varlistentry>
8329 </variablelist>
8330
8331 <para>The <xref linkend="Upload_Behaviors-Sib_Bad_Observation"/>
8332 column is used to denote uncertainty regarding data contained in
8333 the sibling related columns -- those columns beginning
8334 with <quote>sib_</quote>.
8335 <xref linkend="Upload_Behaviors-Sib_Bad_Observation"/> is used
8336 in conjunction with
8337 <xref linkend="Upload_Behaviors-Bad_Observation"/>.</para>
8338
8339 <para>Any given behavioral or distance observation is denoted
8340 uncertain when uncertainty is indicated either by the
8341 <xref linkend="Upload_Behaviors-Bad_Observation"/> or
8342 <xref linkend="Upload_Behaviors-Sib_Bad_Observation"/> columns
8343 or by the data value of the given observation.</para>
8344
8345 <para>The uploaded behavior
8346 code <literal>&gmi_ignore_mark;</literal> is ignored.</para>
8347
8348 <para>Behavior codes are translated from the code or column
8349 written on paper in the field into the codes used within
8350 Gombe-MI by reference to the <xref linkend="BEHAVIOR_TRANS"/>
8351 table. This provides a degree of flexibility; adding new rows
8352 to <xref linkend="BEHAVIOR_TRANS"/> (and
8353 <xref linkend="BEHAVIORS"/>) may allow new behavioral observations
8354 to be collected and uploaded into Gombe-MI without having to
8355 modify the system's code.</para>
8356
8357 <para>The behavior code to use for the eating behavior
8358 associated with the
8359 <xref linkend="Upload_Behaviors-Ma_Foodpart"/>,
8360 <xref linkend="Upload_Behaviors-Ma_Foodkind"/>,
8361 <xref linkend="Upload_Behaviors-Inf_Foodpart"/>,
8362 <xref linkend="Upload_Behaviors-Inf_Foodkind"/>,
8363 <xref linkend="Upload_Behaviors-Sib_Foodpart"/>, and
8364 <xref linkend="Upload_Behaviors-Sib_Foodkind"/> columns and the fishing
8365 behavior associated with the
8366 <xref linkend="Upload_Behaviors-Ma_Fishpart"/>,
8367 <xref linkend="Upload_Behaviors-Ma_Fishkind"/>,
8368 <xref linkend="Upload_Behaviors-Inf_Fishpart"/>,
8369 <xref linkend="Upload_Behaviors-Inf_Fishkind"/>,
8370 <xref linkend="Upload_Behaviors-Sib_Fishpart"/>, and
8371 <xref linkend="Upload_Behaviors-Sib_Fishkind"/> columns is
8372 determined by looking up <literal>&gmi_ma_foodpart;</literal>,
8373 <literal>&gmi_inf_foodpart;</literal>,
8374 <literal>&gmi_sib_foodpart;</literal>,
8375 <literal>&gmi_ma_fishpart;</literal>,
8376 <literal>&gmi_inf_fishpart;</literal>, and
8377 <literal>&gmi_sib_fishpart;</literal> on the
8378 <xref linkend="BEHAVIOR_TRANS"/> table. (The foodkind and
8379 fishkind columns have no row on
8380 <xref linkend="BEHAVIOR_TRANS"/>.</para>
8381
8382 <para>When there are multiple food part codes in the
8383 <xref linkend="Upload_Behaviors-Ma_Foodpart"/>,
8384 <xref linkend="Upload_Behaviors-Inf_Foodkind"/>,
8385 <xref linkend="Upload_Behaviors-Sib_Foodkind"/>,
8386 <xref linkend="Upload_Behaviors-Ma_Fishpart"/>,
8387 <xref linkend="Upload_Behaviors-Inf_Fishkind"/>, or
8388 <xref linkend="Upload_Behaviors-Sib_Fishkind"/> columns a
8389 separate row on <xref linkend="EATS"/> or
8390 <xref linkend="FISHED"/> is created for each of them. The
8391 <xref linkend="Upload_Behaviors-Ma_Foodkind"/>,
8392 <xref linkend="Upload_Behaviors-Inf_Foodkind"/>,
8393 <xref linkend="Upload_Behaviors-Sib_Foodkind"/>,
8394 <xref linkend="Upload_Behaviors-Ma_Fishkind"/>,
8395 <xref linkend="Upload_Behaviors-Inf_Fishkind"/>, or
8396 <xref linkend="Upload_Behaviors-Sib_Fishkind"/> value is used as
8397 the <xref linkend="Eats-Foodkind"/> or
8398 <xref linkend="Fished-Foodkind"/> value for each such created
8399 row.</para>
8400
8401 <para xml:id="UB_Implied_Behaviors">When the uploaded followtype
8402 value identifies a row on <xref linkend="FOLLOWTYPES"/> with a
8403 <xref linkend="FOLLOWTYPES"/>.<xref
8404 linkend="Followtypes-Implied_Behavior"/>
8405 value of &true; UPLOAD_BEHAVIORS looks up the following column
8406 names in <xref linkend="BEHAVIOR_TRANS"/> to determine the
8407 implied behavior code:</para>
8408
8409 <itemizedlist>
8410 <listitem>
8411 <para><xref linkend="Upload_Behaviors-Ma_Grooming"/></para>
8412 </listitem>
8413 <listitem>
8414 <para><xref linkend="Upload_Behaviors-Ma_Play"/></para>
8415 </listitem>
8416 <listitem>
8417 <para><xref linkend="Upload_Behaviors-Ma_Groomed_By"/></para>
8418 </listitem>
8419 <listitem>
8420 <para><xref linkend="Upload_Behaviors-Sib_Play"/></para>
8421 </listitem>
8422 <listitem>
8423 <para><xref linkend="Upload_Behaviors-Sib_Grooming"/></para>
8424 </listitem>
8425 <listitem>
8426 <para><xref linkend="Upload_Behaviors-Sib_Groomed_By"/></para>
8427 </listitem>
8428 <listitem>
8429 <para><xref linkend="Upload_Behaviors-Ma_Foodpart"/></para>
8430 </listitem>
8431 <listitem>
8432 <para><xref linkend="Upload_Behaviors-Inf_Foodpart"/></para>
8433 </listitem>
8434 <listitem>
8435 <para><xref linkend="Upload_Behaviors-Sib_Foodpart"/></para>
8436 </listitem>
8437 <listitem>
8438 <para><xref linkend="Upload_Behaviors-Ma_Fishpart"/></para>
8439 </listitem>
8440 <listitem>
8441 <para><xref linkend="Upload_Behaviors-Inf_Fishpart"/></para>
8442 </listitem>
8443 <listitem>
8444 <para><xref linkend="Upload_Behaviors-Sib_Fishpart"/></para>
8445 </listitem>
8446 </itemizedlist>
8447
8448 <para>When
8449 <xref linkend="FOLLOWTYPES"/>.<xref
8450 linkend="Followtypes-Implied_Behavior"/>
8451 is &true; the implied behavior code is only used if the data in
8452 the above columns has not been processed due to the presence of
8453 an uploaded behavior code. The implied behavior code is
8454 therefore the default behavior when no behavior code is
8455 listed.</para>
8456
8457 <para>When
8458 <xref linkend="FOLLOWTYPES"/>.<xref
8459 linkend="Followtypes-Implied_Behavior"/>
8460 is &false; the data in these columns is processed only when an
8461 appropriate<footnote>
8462
8463 <para>Based on a behavior code written into the data and
8464 according to the corresponding
8465 <xref linkend="BEHAVIOR_TRANS"/> row.</para>
8466
8467 </footnote> behavior value is encountered. Should there be no
8468 such behavior code UPLOAD_BEHAVIORS will raise an error if the
8469 above columns contain data.</para>
8470
8471 <para>The following columns always imply a behavior<footnote>
8472
8473 <para>That is, they are processed as if
8474 <xref linkend="FOLLOWTYPES"/>.<xref
8475 linkend="Followtypes-Implied_Behavior"/>
8476 is &true; regardless of it's actual value.</para>
8477
8478 </footnote>:</para>
8479
8480 <itemizedlist>
8481 <listitem>
8482 <para><xref linkend="Upload_Behaviors-Inf_Social_Play"/></para>
8483 </listitem>
8484 <listitem>
8485 <para><xref linkend="Upload_Behaviors-Inf_Grooming"/></para>
8486 </listitem>
8487 <listitem>
8488 <para><xref linkend="Upload_Behaviors-Inf_Being_Groomed"/></para>
8489 </listitem>
8490 </itemizedlist>
8491
8492 <para xml:id="UB_Duplicate_Control"><xref linkend="BEHAVIOR_TRANS"/>
8493 Controls other aspects of the upload process. When
8494 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Dups"/>
8495 is &true;, and the behavior is between focals, and the behavior
8496 is uploaded as a behavior code and not a column dedicated to a
8497 specific behavior<footnote>
8498
8499 <para>Duplicate detection is hardcoded into UPLOAD_BEHAVIORS
8500 for those columns that are dedicated to specific
8501 behaviors.</para>
8502
8503 </footnote>, UPLOAD_BEHAVIORS
8504 expects that the behavior to be recorded twice on the uploaded
8505 line, once for each focal. If this is not the case an error is
8506 reported. If either (or both) of the observations is uncertain
8507 then the observation is recorded in the database (once) as
8508 uncertain. If the
8509 <xref linkend="EVENTS"/>.<xref linkend="Events-Position"/>
8510 values do not match an error is reported.</para>
8511
8512 <para xml:id="Play_Role_Determination"><xref
8513 linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Play_Val"/>,
8514 , as well as the name of the column, controls whether the
8515 behavior is considered a social play behavior. When
8516 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Play_Val"/>
8517 is non-&null;, or the
8518 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> column data
8519 is under consideration and the infant is not the individual
8520 listed in the <xref linkend="Upload_Behaviors-Inf_Social_Play"/>
8521 column, and the behavior is between focals, UPLOAD_BEHAVIORS
8522 considers the play to be a directed (actor/actee) behavior. The
8523 program also checks for reciprocal actor/actee play
8524 relationships between focals, having identical
8525 <xref linkend="EVENTS"/>.<xref linkend="Events-Behavior"/>
8526 codes, and, if found, ensures that the 2 observations recorded
8527 in the field are uploaded into the database as a single mutual
8528 behavioral interaction, as a single <xref linkend="EVENTS"/> row
8529 having <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
8530 values of <literal>&gmi_participant;</literal>. So, for
8531 example, when an uploaded line records the mother playing with
8532 the infant (in a directed fashion) and the infant playing with
8533 the mother (in a directed fashion, both events having the same
8534 code for play) a single mutual (undirected) play event is
8535 recorded in the database. If either (or both) of the
8536 observations is uncertain then the observation is recorded in
8537 the database (once) as uncertain. If the
8538 <xref linkend="EVENTS"/>.<xref linkend="Events-Position"/>
8539 values do not match an error is reported.</para>
8540
8541 <para>When
8542 <xref linkend="BEHAVIOR_TRANS"/>.<xref
8543 linkend="Behavior_Trans-Play_Val"/>
8544 is non-&null;, or the
8545 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> column data is
8546 under consideration, and the behavior is not between focals,
8547 UPLOAD_BEHAVIORS considers the play to be mutual -- the
8548 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/> values are
8549 set to <literal>&gmi_participant;</literal>.</para>
8550
8551 <para>When the
8552 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> column data
8553 lists the focal infant the behavior is considered to be
8554 self-play.</para>
8555
8556 <caution>
8557 <para>The <quote>old Excel</quote> data format does not
8558 designate self-play by listing the focal infant in the
8559 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> column.
8560 Instead self-play is designated by use of the
8561 <xref linkend="Upload_Behaviors-Inf_Solitary_Play"/> column.
8562 In order to accommodate the <quote>new Excel</quote> data
8563 format the rules for
8564 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> were
8565 altered to allow the coding for self-play regardless of
8566 whether old or new data is uploaded. Consequently, should the
8567 old data need to be re-uploaded, improper data may be silently
8568 ignored and incorrect self-play behaviors may be inadvertently
8569 uploaded into the system.</para>
8570 </caution>
8571
8572 <para><xref linkend="BEHAVIOR_TRANS"/>.<xref
8573 linkend="Behavior_Trans-Grooms_Other"/>,
8574 as well as the data in the
8575 <xref linkend="Upload_Behaviors-Inf_Grooming"/> column, controls
8576 whether the behavior is considered one where the focal grooms
8577 another individual;
8578 <xref linkend="BEHAVIOR_TRANS"/>.<xref
8579 linkend="Behavior_Trans-Groomed_By"/>,
8580 as well as the data in the
8581 <xref linkend="Upload_Behaviors-Inf_Being_Groomed"/> column,
8582 controls whether the behavior is considered to be one where the
8583 focal is groomed by another individual; and a non-&null;
8584 <xref linkend="BEHAVIOR_TRANS"/>.<xref
8585 linkend="Behavior_Trans-Ride_Val"/>
8586 column indicates that the behavior is considered to be one where
8587 the focal rides on another individual. When the grooming
8588 behavior is identified by a code rather than by ChimpIDs entered
8589 into a column it is an error to upload a behavior code with a
8590 <xref linkend="BEHAVIOR_TRANS"/>.<xref
8591 linkend="Behavior_Trans-Grooms_Other"/>,
8592 or <xref linkend="Behavior_Trans-Groomed_By"/> value of &true;,
8593 or a <xref linkend="Behavior_Trans-Ride_Val"/>
8594 or <xref linkend="Behavior_Trans-Play_Val"/> value which is non-&null;
8595 without at least one ChimpID value in a corresponding column to
8596 provide a social partner for the focal.</para>
8597
8598 <!--
8599 <para><xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Rest_Val"/>
8600 controls whether the behavior is considered a resting behavior
8601 and so requires a row on <xref linkend="RESTS"/>.</para>
8602 -->
8603
8604 <para>Unless UPLOAD_BEHAVIORS is to take the mother's grooming
8605 and play partners from separate columns on any one uploaded line
8606 the individuals with whom the mother groomed and played with
8607 must either both be recorded in a single column or be recorded
8608 in separate columns -- unless
8609 <xref linkend="Upload_Behaviors-Ma_GP_Combined"/> is &false;
8610 there cannot be data in both
8611 <xref linkend="Upload_Behaviors-Ma_Groomingplay"/> and
8612 <xref linkend="Upload_Behaviors-Ma_Grooming"/>, nor may there be
8613 data in both <xref linkend="Upload_Behaviors-Ma_Groomingplay"/>
8614 and <xref linkend="Upload_Behaviors-Ma_Play"/>.<footnote>
8615
8616 <para>Yes, it is allowed to have data in the
8617 <xref linkend="Upload_Behaviors-Ma_Groomingplay"/> column even
8618 though the data is ignored.</para>
8619
8620 </footnote></para>
8621
8622 <para>It is an error to upload a row where the mother's grooming
8623 and play partners are combined into a single column and there is
8624 more than one grooming and play partner; UPLOAD_BEHAVIORS is then
8625 unable to determine which partners were play partners and which
8626 were grooming partners.</para>
8627
8628 <para xml:id="Reserved_AnimIDs">The &gcdbh; reserves some AnimID
8629 values to carry special meaning. These may not be used as
8630 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
8631 values or as
8632 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
8633 values. These special values have the following effect when
8634 uploaded into UPLOAD_BEHAVIORS:</para>
8635
8636 <variablelist>
8637 <title>Reserved AnimID Values</title>
8638
8639 <varlistentry>
8640 <term><literal>&gmi_animid_qmark;</literal></term>
8641
8642 <listitem>
8643 <para>In most cases the focal is recorded as interacting
8644 with the <literal>&gmi_unk_animid;</literal> ChimpID (in
8645 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>)
8646 and the
8647 <xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>
8648 value is set to &true;.</para>
8649
8650 <para>In the case of the
8651 <xref linkend="Upload_Behaviors-Inf_Rejection"/> column
8652 the focal is recorded as interacting with the mother and
8653 the
8654 <xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>
8655 value is set to &true;.</para>
8656
8657 <para>In the case of the
8658 <xref linkend="Upload_Behaviors-Inf_Display"/> column the
8659 focal (the infant) is recorded as interacting with herself
8660 and the
8661 <xref linkend="EVENTS"/>.<xref linkend="Events-Uncertain"/>
8662 value is set to &true;.</para>
8663 </listitem>
8664 </varlistentry>
8665
8666 <varlistentry>
8667 <term><literal>&gmi_animid_y;</literal></term>
8668
8669 <listitem>
8670 <para>In most cases the focal is recorded as interacting with
8671 the <literal>&gmi_unk_animid;</literal> ChimpID (in
8672 <xref linkend="PARTS"/>.<xref
8673 linkend="Parts-Participant"/>).</para>
8674
8675 <para>In the case of the
8676 <xref linkend="Upload_Behaviors-Inf_Ride_On_Belly"/>,
8677 <xref linkend="Upload_Behaviors-Inf_Ride_On_Back"/>,
8678 <xref linkend="Upload_Behaviors-Inf_Ride_On_Unk"/>,
8679 <xref linkend="Upload_Behaviors-Inf_Dangle"/>, and
8680 <xref linkend="Upload_Behaviors-Inf_Rejection"/> columns
8681 the focal is recorded as interacting with the mother.</para>
8682
8683 <para>In the case of the
8684 <xref linkend="Upload_Behaviors-Inf_Display"/> column the
8685 focal (the infant) is recorded as interacting with
8686 herself.</para>
8687 </listitem>
8688 </varlistentry>
8689
8690 <varlistentry>
8691 <term><literal>&gmi_animid_baboon;</literal></term>
8692
8693 <listitem><para>The focal is recorded as interacting with a
8694 baboon --
8695 <xref linkend="EVENTS"/>.<xref linkend="Events-Baboon"/> is
8696 set to &true; and there is not a <xref linkend="PARTS"/> row
8697 recording the focal's behavioral partner.</para></listitem>
8698 </varlistentry>
8699 </variablelist>
8700
8701 <para>UPLOAD_BEHAVIORS does not vary the
8702 <xref linkend="FISHED"/>.<xref linkend="Fished-Result"/> value
8703 when recording a fishing event. The value used is
8704 always <literal>&gmi_fishing_success;</literal> to indicate
8705 successful fishing.</para>
8706
8707 <para>The <xref linkend="Upload_Behaviors-Inf_Cry"/> and
8708 <xref linkend="Upload_Behaviors-Inf_Voc"/> data are added to the
8709 database as a single vocalization event (a single
8710 <xref linkend="EVENTS"/> row) in which, possibly, more than one
8711 sound is made (possibly having more than one related
8712 <xref linkend="VOCS"/> rows).</para>
8713 <!--
8714 <para xml:id="UB_Comment_Processing">The
8715 <xref linkend="Upload_Behaviors-Comments"/> column is examined
8716 on upload and sometimes altered and a new behavioral event
8717 created. When the <xref linkend="Upload_Behaviors-Comments"/>
8718 column contains the character
8719 sequence <literal>&gmi_devbeh;</literal> (case sensitive) and
8720 the columns <xref linkend="Upload_Behaviors-Inf_Nurse"/>,
8721 <xref linkend="Upload_Behaviors-Inf_Eat"/>,
8722 <xref linkend="Upload_Behaviors-Inf_Travel"/>,
8723 <xref linkend="Upload_Behaviors-Inf_Solitary_Play"/>,
8724 <xref linkend="Upload_Behaviors-Inf_Rest"/>,
8725 <xref linkend="Upload_Behaviors-Inf_Ride_On_Belly"/>,
8726 <xref linkend="Upload_Behaviors-Inf_Ride_On_Back"/>,
8727 <xref linkend="Upload_Behaviors-Inf_Ride_On_Unk"/>,
8728 <xref linkend="Upload_Behaviors-Inf_Dangle"/>,
8729 <xref linkend="Upload_Behaviors-Inf_Touching_Another"/>,
8730 <xref linkend="Upload_Behaviors-Inf_Grooming"/>,
8731 <xref linkend="Upload_Behaviors-Inf_Being_Groomed"/> and
8732 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> are all empty
8733 then the comment text is examined to see if
8734 the <literal>&gmi_devbeh;</literal> characters are immediately
8735 followed by at least one character surrounded by square
8736 braces, <literal>[]</literal>. If not an error is raised. If
8737 so then the a behavioral event is recorded in the database, the
8738 behavior code being obtained from the
8739 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Old_Behavior"/>
8740 value where the
8741 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Old_Behavior"/>
8742 is <literal>devbeh</literal>,
8743 the <literal>&gmi_devbeh;</literal> character sequence, the
8744 square braces with follow it and the text enclosed by the square
8745 braces are removed from the uploaded comment, and the text
8746 enclosed in the square braces is recorded in the
8747 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> value
8748 of the newly created behavioral event.</para>
8749 -->
8750
8751 <para xml:id="UB_Comment_Processing">The
8752 <xref linkend="Upload_Behaviors-Comments"/> column is examined
8753 on upload and sometimes altered and a new behavioral event
8754 created. When the <xref linkend="Upload_Behaviors-Comments"/>
8755 column contains the character
8756 sequence <literal>&gmi_devbeh;</literal> (case sensitive) and
8757 the columns <xref linkend="Upload_Behaviors-Inf_Nurse"/>,
8758 <xref linkend="Upload_Behaviors-Inf_Eat"/>,
8759 <xref linkend="Upload_Behaviors-Inf_Travel"/>,
8760 <xref linkend="Upload_Behaviors-Inf_Solitary_Play"/>,
8761 <xref linkend="Upload_Behaviors-Inf_Rest"/>,
8762 <xref linkend="Upload_Behaviors-Inf_Ride_On_Belly"/>,
8763 <xref linkend="Upload_Behaviors-Inf_Ride_On_Back"/>,
8764 <xref linkend="Upload_Behaviors-Inf_Ride_On_Unk"/>,
8765 <xref linkend="Upload_Behaviors-Inf_Dangle"/>,
8766 <xref linkend="Upload_Behaviors-Inf_Touching_Another"/>,
8767 <xref linkend="Upload_Behaviors-Inf_Grooming"/>,
8768 <xref linkend="Upload_Behaviors-Inf_Being_Groomed"/> and
8769 <xref linkend="Upload_Behaviors-Inf_Social_Play"/> are all empty
8770 then the comment text is examined to see if
8771 the <literal>&gmi_devbeh;</literal> characters are immediately
8772 followed by at least one character surrounded by square
8773 braces, <literal>[]</literal>. If not an error is raised. If
8774 so then the a behavioral event is recorded in the database, the
8775 behavior code being obtained from the
8776 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Old_Behavior"/>
8777 value where the
8778 <xref linkend="BEHAVIOR_TRANS"/>.<xref linkend="Behavior_Trans-Old_Behavior"/>
8779 is <literal>devbeh</literal>,
8780 the <literal>&gmi_devbeh;</literal> character sequence, the
8781 square braces with follow it and the text enclosed by the square
8782 braces are recorded in the
8783 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/> value
8784 of the newly created behavioral event.<footnote>
8785
8786 <para>Note that the text of the
8787 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-Comment"/>
8788 is unchanged; it retains the text copied into the
8789 <xref linkend="EVENTS"/>.<xref linkend="Events-Comment"/>
8790 column.</para>
8791
8792 </footnote></para>
8793
8794 <section xml:id="UPLOAD_BEHAVIORS-Definition">
8795 <title>UPLOAD_BEHAVIORS Definition</title>
8796
8797 <xi:include
8798 href="views/upload_behaviors.xml"
8799 xmlns:xi="http://www.w3.org/2001/XInclude"/>
8800 </section>
8801
8802 <section xml:id="Upload_Behaviors-Columns">
8803 <title>UPLOAD_BEHAVIORS Columns</title>
8804
8805 <informaltable frame="topbot">
8806 <tgroup cols="3" colsep="0" rowsep="0">
8807 <colspec colnum="3" rowsep="1"/>
8808 <thead>
8809 <row rowsep="1">
8810 <entry>Column</entry>
8811 <entry>Uploads into </entry>
8812 <entry>Description</entry>
8813 </row>
8814 </thead>
8815 <tbody>
8816 <row xml:id="Upload_Behaviors-Followtype" xreflabel="Followtype">
8817 <entry>Followtype</entry>
8818
8819 <entry><xref linkend="SHEETS"/>.<xref
8820 linkend="Sheets-Followtype"/></entry>
8821
8822 <entry>Code indicating the set of data collected.
8823 &notnull; &remove_spaces;</entry>
8824 </row>
8825
8826 <row xml:id="Upload-Behaviors-Entrydate" xreflabel="Entrydate">
8827 <entry>Entrydate</entry>
8828
8829 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
8830 linkend="Fieldfollows-Entrydate"/></entry>
8831
8832 <entry>
8833 <para>Date the data collection sheet was entered into
8834 an electronic form.</para>
8835
8836 <para>This value may be &null; under certain
8837 conditions, see
8838 <xref linkend="FIELDFOLLOWS"/>.<xref
8839 linkend="Fieldfollows-Entrydate"/>.</para>
8840 </entry>
8841 </row>
8842
8843 <row xml:id="Upload_Behaviors-Entered_By" xreflabel="Entered_By">
8844 <entry>Entered_By</entry>
8845
8846 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
8847 linkend="Fieldfollows-Enterer"/></entry>
8848
8849 <entry>
8850 <para>Code for the person who entered the data into
8851 electronic form. &notnull;</para>
8852
8853 <para>&remove_spaces; &case_sensitive;</para>
8854 </entry>
8855 </row>
8856
8857 <row xml:id="Upload_Behaviors-Researcher" xreflabel="Researcher">
8858 <entry>Researcher</entry>
8859
8860 <entry><xref linkend="FIELDFOLLOWS"/>.<xref
8861 linkend="Fieldfollows-Collector"/></entry>
8862
8863 <entry>
8864 <para>Written out name of the person who collected the
8865 data in the field. &notnull;</para>
8866
8867 <para>&remove_spaces_case;</para>
8868 </entry>
8869 </row>
8870
8871 <row xml:id="Upload_Behaviors-Date" xreflabel="Date">
8872 <entry>Date</entry>
8873
8874 <entry><xref linkend="FOLLOWS"/>.<xref
8875 linkend="Follows-Date"/></entry>
8876
8877 <entry>Date of the follow. &notnull;</entry>
8878 </row>
8879
8880 <row xml:id="Upload_Behaviors-Page" xreflabel="Page">
8881 <entry>Page</entry>
8882
8883 <entry><xref linkend="SHEETS"/>.<xref
8884 linkend="Sheets-Page"/></entry>
8885
8886 <entry>Page number of the data collection sheet on which
8887 the data is written. All of any one follow's data rows
8888 having &null; page numbers are considered to have been
8889 written on a single sheet (a sheet having a &null; page
8890 number).</entry>
8891 </row>
8892
8893 <row xml:id="Upload_Behaviors-Location" xreflabel="Location">
8894 <entry>Location</entry>
8895
8896 <entry><xref linkend="SHEETS"/>.<xref
8897 linkend="Sheets-Location"/></entry>
8898
8899 <entry>Location of follow. &remove_spaces;</entry>
8900 </row>
8901
8902 <row xml:id="Upload_Behaviors-Mother" xreflabel="Mother">
8903 <entry>Mother</entry>
8904
8905 <entry><xref linkend="FOLLOWPARTS"/>.<xref
8906 linkend="Followparts-ChimpID"/>,
8907 <xref linkend="FOLLOWPARTS"/>.<xref
8908 linkend="Followparts-Role"/>,
8909 <xref linkend="PARTS"/>.<xref
8910 linkend="Parts-Participant"/>,
8911 <xref linkend="DISTANCEPARTS"/>.<xref
8912 linkend="Distanceparts-Participant"/></entry>
8913
8914 <entry>
8915 <para>ChimpID of the mother in the follow. The
8916 related
8917 <xref linkend="FOLLOWPARTS"/>.<xref
8918 linkend="Followparts-Role"/>
8919 value is always set
8920 to <literal>&gmi_mom_role;</literal><footnote>
8921
8922 <para>Irrespective of the content of the
8923 <xref linkend="FOLLOWROLES"/> table.</para>
8924
8925 </footnote> when the follow is created.</para>
8926
8927 <para>&remove_spaces;</para>
8928 </entry>
8929 </row>
8930
8931 <row xml:id="Upload_Behaviors-Infant" xreflabel="Infant">
8932 <entry>Infant</entry>
8933
8934 <entry><xref linkend="FOLLOWPARTS"/>.<xref
8935 linkend="Followparts-ChimpID"/>,
8936 <xref linkend="FOLLOWPARTS"/>.<xref
8937 linkend="Followparts-Role"/>,
8938 <xref linkend="PARTS"/>.<xref
8939 linkend="Parts-Participant"/>,
8940 <xref linkend="DISTANCEPARTS"/>.<xref
8941 linkend="Distanceparts-Participant"/></entry>
8942
8943 <entry>
8944 <para>ChimpID of the infant in the follow. The
8945 related
8946 <xref linkend="FOLLOWPARTS"/>.<xref
8947 linkend="Followparts-Role"/>
8948 value is always set
8949 to <literal>&gmi_infant_role;</literal><footnote>
8950
8951 <para>Irrespective of the content of the
8952 <xref linkend="FOLLOWROLES"/> table.</para>
8953
8954 </footnote> when the follow is created.</para>
8955
8956 <para>&remove_spaces;</para>
8957 </entry>
8958 </row>
8959
8960 <row xml:id="Upload_Behaviors-Sibling" xreflabel="Sibling">
8961 <entry>Sibling</entry>
8962
8963 <entry><xref linkend="FOLLOWPARTS"/>.<xref
8964 linkend="Followparts-ChimpID"/>,
8965 <xref linkend="FOLLOWPARTS"/>.<xref
8966 linkend="Followparts-Role"/>,
8967 <xref linkend="PARTS"/>.<xref
8968 linkend="Parts-Participant"/>,
8969 <xref linkend="DISTANCEPARTS"/>.<xref
8970 linkend="Distanceparts-Participant"/></entry>
8971
8972 <entry>
8973 <para>ChimpID of the sibling in the follow. The
8974 related
8975 <xref linkend="FOLLOWPARTS"/>.<xref
8976 linkend="Followparts-Role"/>
8977 value is always set
8978 to <literal>&gmi_sib_role;</literal><footnote>
8979
8980 <para>Irrespective of the content of the
8981 <xref linkend="FOLLOWROLES"/> table.</para>
8982
8983 </footnote> when the follow is created.</para>
8984
8985 <para>&remove_spaces; This column may be &null; to
8986 indicate that there is no sibling.</para>
8987 </entry>
8988 </row>
8989
8990 <row xml:id="Upload_Behaviors-Time_On_Sheet"
8991 xreflabel="Time_On_Sheet">
8992 <entry>Time_On_Sheet</entry>
8993
8994 <entry>&ignored_column;</entry>
8995
8996 <entry>Time value written on data collection sheet.</entry>
8997 </row>
8998
8999 <row xml:id="Upload_Behaviors-Time_Converted_Mil"
9000 xreflabel="Time_Converted_Mil">
9001 <entry>Time_Converted_Mil</entry>
9002
9003 <entry><xref linkend="INTERVALS"/>.<xref
9004 linkend="Intervals-Time"/></entry>
9005
9006 <entry>Time of the 1-minute interval in 24-hour clock
9007 format. Note that the format of the time is not
9008 validated beyond ensuring that it conforms to some legal
9009 &postgresql; time syntax.</entry>
9010 </row>
9011
9012 <row xml:id="Upload_Behaviors-Time_Type" xreflabel="Time_Type">
9013 <entry>Time_Type</entry>
9014
9015 <entry>&ignored_column;</entry>
9016
9017 <entry>Code indicating time system used in time written
9018 on data entry sheet.</entry>
9019 </row>
9020
9021 <row xml:id="Upload_Behaviors-Bad_Observation"
9022 xreflabel="Bad_Observation">
9023 <entry>Bad_Observation</entry>
9024
9025 <entry><xref linkend="DISTANCES"/>.<xref
9026 linkend="Distances-Uncertain"/>,
9027 <xref linkend="EVENTS"/>.<xref
9028 linkend="Events-Uncertain"/></entry>
9029
9030 <entry>This column is used in conjunction with other
9031 columns to indicate observation certainty.
9032 See <link linkend="Bad_Obs">the description</link> of
9033 how certainty is determined above.</entry>
9034 </row>
9035
9036 <row xml:id="Upload_Behaviors-Rain" xreflabel="Rain">
9037 <entry>Rain</entry>
9038
9039 <entry>&ignored_column;</entry>
9040
9041 <entry>Indication of whether or not it was raining.</entry>
9042 </row>
9043
9044 <row xml:id="Upload_Behaviors-Ma_Behavior"
9045 xreflabel="Ma_Behavior">
9046 <entry>Ma_Behavior</entry>
9047
9048 <entry><xref linkend="EVENTS"/>.<xref
9049 linkend="Events-Behavior"/></entry>
9050
9051 <entry><para>Mother's behavior codes. This is translated
9052 into the codes used within Gombe-MI by reference to
9053 the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
9054
9055 <para>Multiple behaviors are separated from each other
9056 by the <literal>&gmi_behavior_delim;</literal> character. Whitespace
9057 is ignored.</para></entry>
9058 </row>
9059
9060 <row xml:id="Upload_Behaviors-Ma_Foodpart"
9061 xreflabel="Ma_Foodpart">
9062 <entry>Ma_Foodpart</entry>
9063
9064 <entry><xref linkend="EATS"/>.<xref
9065 linkend="Eats-Foodpart"/></entry>
9066
9067 <entry><para>Mother's food part codes of food eaten.
9068 This is translated into the codes used within
9069 Gombe-MI by reference to the
9070 <xref linkend="FOODPART_TRANS"/> table.</para>
9071
9072 <para>Multiple food part codes are separated from
9073 each other by the <literal>&gmi_behavior_delim;</literal> character.
9074 Whitespace is ignored.</para></entry>
9075 </row>
9076
9077 <row xml:id="Upload_Behaviors-Ma_Foodkind"
9078 xreflabel="Ma_Foodkind">
9079 <entry>Ma_Foodkind</entry>
9080
9081 <entry><xref linkend="EATS"/>.<xref
9082 linkend="Eats-Foodkind"/></entry>
9083
9084 <entry><para>Mother's food kind code of food
9085 eaten.</para></entry>
9086 </row>
9087
9088 <row xml:id="Upload_Behaviors-Ma_Fishpart"
9089 xreflabel="Ma_Fishpart">
9090 <entry>Ma_Fishpart</entry>
9091
9092 <entry><xref linkend="FISHED"/>.<xref
9093 linkend="Fished-Foodpart"/></entry>
9094
9095 <entry><para>Mother's food part codes of foods fished
9096 for. This is translated into the codes used
9097 within Gombe-MI by reference to the
9098 <xref linkend="FOODPART_TRANS"/> table.</para>
9099
9100 <para>Multiple food part codes are separated from
9101 each other by the <literal>&gmi_behavior_delim;</literal> character.
9102 Whitespace is ignored.</para></entry>
9103 </row>
9104
9105 <row xml:id="Upload_Behaviors-Ma_Fishkind"
9106 xreflabel="Ma_Fishkind">
9107 <entry>Ma_Fishkind</entry>
9108
9109 <entry><xref linkend="FISHED"/>.<xref
9110 linkend="Fished-Foodkind"/></entry>
9111
9112 <entry><para>Mother's food kind code of food fished
9113 for.</para></entry>
9114 </row>
9115
9116 <row xml:id="Upload_Behaviors-Ma_GP_Combined"
9117 xreflabel="Ma_GP_Combined">
9118 <entry>Ma_GP_Combined (Mother's Grooming and Play
9119 Partners are Combined)</entry>
9120
9121 <entry>&control_column;</entry>
9122
9123 <entry>
9124 <para>When this value is &true; or &null; the
9125 individuals the mother groomed or played with are
9126 recorded on the uploaded line in a single column,
9127 the
9128 <xref linkend="Upload_Behaviors-Ma_Groomingplay"/>
9129 column. When the value of this column is &false;
9130 the line records the mothers grooming and play
9131 partners separately, using the
9132 <xref linkend="Upload_Behaviors-Ma_Grooming"/>
9133 column for individuals groomed by the mother and the
9134 <xref linkend="Upload_Behaviors-Ma_Play"/> column
9135 for the individuals the mother plays with.</para>
9136
9137 <para>Note that this column only affects observations
9138 of the mother doing the grooming or play.
9139 Observations of others grooming or playing with the
9140 mother are not influenced.</para>
9141 </entry>
9142 </row>
9143
9144 <row xml:id="Upload_Behaviors-Ma_Groomingplay"
9145 xreflabel="Ma_Groomingplay">
9146 <entry>Ma_Groomingplay</entry>
9147
9148 <entry><xref linkend="PARTS"/>.<xref
9149 linkend="Parts-Participant"/></entry>
9150
9151 <entry>
9152 <para>Chimpids &chimpid-like; identifying the
9153 individuals whom the mother either groomed or played
9154 with. &comma_delim_elim_whitespace;
9155 &special_chimpids;</para>
9156
9157 <para>&play_role_determination;</para>
9158
9159 </entry>
9160 </row>
9161
9162 <row xml:id="Upload_Behaviors-Ma_Grooming"
9163 xreflabel="Ma_Grooming">
9164 <entry>Ma_Grooming</entry>
9165
9166 <entry><xref linkend="PARTS"/>.<xref
9167 linkend="Parts-Participant"/></entry>
9168
9169 <entry>Chimpids &chimpid-like; identifying the
9170 individuals whom the mother groomed.
9171 &comma_delim_elim_whitespace;</entry>
9172 </row>
9173
9174 <row xml:id="Upload_Behaviors-Ma_Play"
9175 xreflabel="Ma_Play">
9176 <entry>Ma_Play</entry>
9177
9178 <entry><xref linkend="PARTS"/>.<xref
9179 linkend="Parts-Participant"/></entry>
9180
9181 <entry>
9182 <para>Chimpids &chimpid-like; identifying the
9183 individuals whom the mother played with.
9184 &comma_delim_elim_whitespace;
9185 &special_chimpids;</para>
9186
9187 <para>&play_role_determination;</para>
9188 </entry>
9189 </row>
9190
9191 <row xml:id="Upload_Behaviors-Ma_Groomed_By"
9192 xreflabel="Ma_Groomed_By">
9193 <entry>Ma_Groomed_By</entry>
9194
9195 <entry><xref linkend="PARTS"/>.<xref
9196 linkend="Parts-Participant"/></entry>
9197
9198 <entry>Chimpids &chimpid-like; identifying the
9199 individuals whom the mother was groomed
9200 by. &comma_delim_elim_whitespace;
9201 &special_chimpids;</entry>
9202 </row>
9203
9204 <row xml:id="Upload_Behaviors-Ma_Voc" xreflabel="Ma_Voc">
9205 <entry>Ma_Voc (Mother's Vocalization Codes</entry>
9206
9207 <entry><xref linkend="VOCS"/>.<xref
9208 linkend="Vocs-Vocalization"/> and others</entry>
9209
9210 <entry><para>Mother's vocalization codes, separated by
9211 the comma (&gmi_chimpid_delim;) character. This is
9212 translated into the codes used within Gombe-MI by
9213 reference to the <xref linkend="VOC_TRANS"/>
9214 table.</para>
9215
9216 <para>Whitespace is ignored.</para></entry>
9217 </row>
9218
9219 <row xml:id="Upload_Behaviors-Inf_Behavior"
9220 xreflabel="Inf_Behavior">
9221 <entry>Inf_Behavior</entry>
9222
9223 <entry><xref linkend="EVENTS"/>.<xref
9224 linkend="Events-Behavior"/></entry>
9225
9226 <entry><para>Infant's behavior codes. This is translated
9227 into the codes used within Gombe-MI by reference to
9228 the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
9229
9230 <para>Multiple behaviors are separated from each other
9231 by the <literal>&gmi_behavior_delim;</literal> character. Whitespace
9232 is ignored.</para></entry>
9233 </row>
9234
9235 <row xml:id="Upload_Behaviors-Inf_Foodpart"
9236 xreflabel="Inf_Foodpart">
9237 <entry>Inf_Foodpart</entry>
9238
9239 <entry><xref linkend="EATS"/>.<xref
9240 linkend="Eats-Foodpart"/></entry>
9241
9242 <entry><para>Infant's food part codes of food eaten.
9243 This is translated into the codes used within
9244 Gombe-MI by reference to the
9245 <xref linkend="FOODPART_TRANS"/> table.</para>
9246
9247 <para>Multiple food part codes are separated from
9248 each other by the <literal>&gmi_behavior_delim;</literal> character.
9249 Whitespace is ignored.</para></entry>
9250 </row>
9251
9252 <row xml:id="Upload_Behaviors-Inf_Foodkind"
9253 xreflabel="Inf_Foodkind">
9254 <entry>Inf_Foodkind</entry>
9255
9256 <entry><xref linkend="EATS"/>.<xref
9257 linkend="Eats-Foodkind"/></entry>
9258
9259 <entry><para>Infant's food kind code of food
9260 eaten.</para></entry>
9261 </row>
9262
9263 <row xml:id="Upload_Behaviors-Inf_Fishpart"
9264 xreflabel="Inf_Fishpart">
9265 <entry>Inf_Fishpart</entry>
9266
9267 <entry><xref linkend="FISHED"/>.<xref
9268 linkend="Fished-Foodpart"/></entry>
9269
9270 <entry><para>Infant's food part codes of foods fished
9271 for. This is translated into the codes used
9272 within Gombe-MI by reference to the
9273 <xref linkend="FOODPART_TRANS"/> table.</para>
9274
9275 <para>Multiple food part codes are separated from
9276 each other by the <literal>&gmi_behavior_delim;</literal> character.
9277 Whitespace is ignored.</para></entry>
9278 </row>
9279
9280 <row xml:id="Upload_Behaviors-Inf_Fishkind"
9281 xreflabel="Inf_Fishkind">
9282 <entry>Inf_Fishkind</entry>
9283
9284 <entry><xref linkend="FISHED"/>.<xref
9285 linkend="Fished-Foodkind"/></entry>
9286
9287 <entry><para>Infant's food kind code of food fished
9288 for.</para></entry>
9289 </row>
9290
9291 <row xml:id="Upload_Behaviors-Inf_Distance_To_Ma"
9292 xreflabel="Inf_Distance_To_Ma">
9293 <entry>Inf_Distance_To_Ma (Code for Infant's Distance
9294 To Mother)</entry>
9295
9296 <entry><xref linkend="DISTANCES"/>.<xref
9297 linkend="Distances-Distance"/> and others</entry>
9298
9299 <entry><para>A
9300 <xref linkend="DISTANCECODES"/>.<xref
9301 linkend="Distancecodes-Distance"/>
9302 value indicating the distance between mother and
9303 infant. &notnull;</para>
9304
9305 <para>The related
9306 <xref linkend="DISTANCEPARTS"/>.<xref
9307 linkend="Distanceparts-Role"/>
9308 values are always set
9309 to <literal>&gmi_mom_role;</literal>
9310 and <literal>&gmi_infant_role;</literal>.<footnote>
9311
9312 <para>Irrespective of the content of the
9313 <xref linkend="FOLLOWROLES"/> table.</para>
9314
9315 </footnote></para>
9316 </entry>
9317 </row>
9318
9319 <row xml:id="Upload_Behaviors-Inf_Nurse" xreflabel="Inf_Nurse">
9320 <entry>Inf_Nurse (Infant Nurses on Mother)</entry>
9321
9322 <entry><xref linkend="EVENTS"/>.<xref
9323 linkend="Events-Behavior"/> and others</entry>
9324
9325 <entry>Whether the infant is nursing on the mother.
9326 &semi_boolean; &bt_driven;</entry>
9327 </row>
9328
9329 <row xml:id="Upload_Behaviors-Inf_Travel" xreflabel="Inf_Travel">
9330 <entry>Inf_Travel</entry>
9331
9332 <entry><xref linkend="EVENTS"/>.<xref
9333 linkend="Events-Behavior"/> and others</entry>
9334
9335 <entry>Whether the infant is traveling.
9336 &semi_boolean; &bt_driven;</entry>
9337 </row>
9338
9339 <row xml:id="Upload_Behaviors-Inf_Eat" xreflabel="Inf_Eat">
9340 <entry>Inf_Eat</entry>
9341
9342 <entry><xref linkend="EVENTS"/>.<xref
9343 linkend="Events-Behavior"/> and others</entry>
9344
9345 <entry>Whether the infant is eating. &semi_boolean;
9346 &bt_driven;</entry>
9347 </row>
9348
9349 <row xml:id="Upload_Behaviors-Inf_Solitary_Play"
9350 xreflabel="Inf_Solitary_Play">
9351 <entry>Inf_Solitary_Play</entry>
9352
9353 <entry><xref linkend="PLAYS"/>.<xref
9354 linkend="Plays-Play"/> and others</entry>
9355
9356 <entry><para>Infant's solitary play code. This is translated
9357 into the codes used within Gombe-MI by reference to
9358 the <xref linkend="PLAY_TRANS"/> table.</para>
9359
9360 <para>Whitespace is ignored.</para></entry>
9361 </row>
9362
9363 <row xml:id="Upload_Behaviors-Inf_Rest"
9364 xreflabel="Inf_Rest">
9365 <entry>Inf_Rest</entry>
9366
9367 <entry><xref linkend="EVENTS"/>.<xref
9368 linkend="Events-Behavior"/> and others</entry>
9369
9370 <entry>Whether the infant is resting. &semi_boolean;
9371 &bt_driven;</entry>
9372 </row>
9373
9374 <row xml:id="Upload_Behaviors-Inf_Distance_1"
9375 xreflabel="Inf_Distance_1">
9376 <entry>Inf_Distance_1</entry>
9377
9378 <entry><xref linkend="DISTANCES"/>.<xref
9379 linkend="Distances-Distance"/> and others</entry>
9380
9381 <entry><para>An indication of distance between mother and
9382 infant. &dt_driven; &semi_boolean;</para>
9383
9384 <para>The related
9385 <xref linkend="DISTANCEPARTS"/>.<xref
9386 linkend="Distanceparts-Role"/>
9387 values are always set
9388 to <literal>&gmi_mom_role;</literal>
9389 and <literal>&gmi_infant_role;</literal>.<footnote>
9390
9391 <para>Irrespective of the content of the
9392 <xref linkend="FOLLOWROLES"/> table.</para>
9393
9394 </footnote></para>
9395 </entry>
9396 </row>
9397
9398 <row xml:id="Upload_Behaviors-Inf_Distance_2"
9399 xreflabel="Inf_Distance_2">
9400 <entry>Inf_Distance_2</entry>
9401
9402 <entry><xref linkend="DISTANCES"/>.<xref
9403 linkend="Distances-Distance"/> and others</entry>
9404
9405
9406 <entry><para>An indication of distance between mother and
9407 infant. &dt_driven; &semi_boolean;</para>
9408
9409 <para>The related
9410 <xref linkend="DISTANCEPARTS"/>.<xref
9411 linkend="Distanceparts-Role"/>
9412 values are always set
9413 to <literal>&gmi_mom_role;</literal>
9414 and <literal>&gmi_infant_role;</literal>.<footnote>
9415
9416 <para>Irrespective of the content of the
9417 <xref linkend="FOLLOWROLES"/> table.</para>
9418
9419 </footnote></para>
9420 </entry>
9421 </row>
9422
9423 <row xml:id="Upload_Behaviors-Inf_Distance_3"
9424 xreflabel="Inf_Distance_3">
9425 <entry>Inf_Distance_3</entry>
9426
9427 <entry><xref linkend="DISTANCES"/>.<xref
9428 linkend="Distances-Distance"/> and others</entry>
9429
9430
9431 <entry><para>An indication of distance between mother and
9432 infant. &dt_driven; &semi_boolean;</para>
9433
9434 <para>The related
9435 <xref linkend="DISTANCEPARTS"/>.<xref
9436 linkend="Distanceparts-Role"/>
9437 values are always set
9438 to <literal>&gmi_mom_role;</literal>
9439 and <literal>&gmi_infant_role;</literal>.<footnote>
9440
9441 <para>Irrespective of the content of the
9442 <xref linkend="FOLLOWROLES"/> table.</para>
9443
9444 </footnote></para>
9445 </entry>
9446 </row>
9447
9448 <row xml:id="Upload_Behaviors-Inf_Distance_4"
9449 xreflabel="Inf_Distance_4">
9450 <entry>Inf_Distance_4</entry>
9451
9452 <entry><xref linkend="DISTANCES"/>.<xref
9453 linkend="Distances-Distance"/> and others</entry>
9454
9455
9456 <entry><para>An indication of distance between mother and
9457 infant. &dt_driven; &semi_boolean;</para>
9458
9459 <para>The related
9460 <xref linkend="DISTANCEPARTS"/>.<xref
9461 linkend="Distanceparts-Role"/>
9462 values are always set
9463 to <literal>&gmi_mom_role;</literal>
9464 and <literal>&gmi_infant_role;</literal>.<footnote>
9465
9466 <para>Irrespective of the content of the
9467 <xref linkend="FOLLOWROLES"/> table.</para>
9468
9469 </footnote></para>
9470 </entry>
9471 </row>
9472
9473 <row xml:id="Upload_Behaviors-Inf_Distance_5"
9474 xreflabel="Inf_Distance_5">
9475 <entry>Inf_Distance_5</entry>
9476
9477 <entry><xref linkend="DISTANCES"/>.<xref
9478 linkend="Distances-Distance"/> and others</entry>
9479
9480
9481 <entry><para>An indication of distance between mother and
9482 infant. &dt_driven; &semi_boolean;</para>
9483
9484 <para>The related
9485 <xref linkend="DISTANCEPARTS"/>.<xref
9486 linkend="Distanceparts-Role"/>
9487 values are always set
9488 to <literal>&gmi_mom_role;</literal>
9489 and <literal>&gmi_infant_role;</literal>.<footnote>
9490
9491 <para>Irrespective of the content of the
9492 <xref linkend="FOLLOWROLES"/> table.</para>
9493
9494 </footnote></para>
9495 </entry>
9496 </row>
9497
9498 <row xml:id="Upload_Behaviors-Inf_Distance_Over_5m"
9499 xreflabel="Inf_Distance_Over_5m">
9500 <entry>Inf_Distance_Over_5m</entry>
9501
9502 <entry><xref linkend="DISTANCES"/>.<xref
9503 linkend="Distances-Distance"/> and others</entry>
9504
9505
9506 <entry><para>An indication of distance between mother and
9507 infant. &dt_driven; &semi_boolean;</para>
9508
9509 <para>The related
9510 <xref linkend="DISTANCEPARTS"/>.<xref
9511 linkend="Distanceparts-Role"/>
9512 values are always set
9513 to <literal>&gmi_mom_role;</literal>
9514 and <literal>&gmi_infant_role;</literal>.<footnote>
9515
9516 <para>Irrespective of the content of the
9517 <xref linkend="FOLLOWROLES"/> table.</para>
9518
9519 </footnote></para>
9520 </entry>
9521 </row>
9522
9523 <row xml:id="Upload_Behaviors-Inf_Ride_On_Belly"
9524 xreflabel="Inf_Ride_On_Belly">
9525 <entry>Inf_Ride_On_Belly</entry>
9526
9527 <entry><xref linkend="RIDES"/>.<xref
9528 linkend="Rides-Ride"/> and others</entry>
9529
9530 <entry>Chimpid &chimpid-like; identifying the
9531 individual on whom the infant is riding dorsally.
9532 Whitespace is ignored. &special_chimpids;
9533 &bt_driven;</entry>
9534 </row>
9535
9536 <row xml:id="Upload_Behaviors-Inf_Ride_On_Back"
9537 xreflabel="Inf_Ride_On_Back">
9538 <entry>Inf_Ride_On_Back</entry>
9539
9540 <entry><xref linkend="RIDES"/>.<xref
9541 linkend="Rides-Ride"/> and others</entry>
9542
9543 <entry>Chimpid &chimpid-like; identifying the
9544 individual on whom the infant is riding ventrally.
9545 Whitespace is ignored. &special_chimpids;
9546 &bt_driven;</entry>
9547 </row>
9548
9549 <row xml:id="Upload_Behaviors-Inf_Ride_On_Unk"
9550 xreflabel="Inf_Ride_On_Unk">
9551 <entry>Inf_Ride_On_Unk</entry>
9552
9553 <entry><xref linkend="RIDES"/>.<xref
9554 linkend="Rides-Ride"/> and others</entry>
9555
9556 <entry>Chimpid &chimpid-like; identifying the
9557 individual on whom the infant is riding when the
9558 riding posture is unknown. Whitespace is ignored.
9559 &special_chimpids; &bt_driven;</entry>
9560 </row>
9561
9562 <row xml:id="Upload_Behaviors-Inf_Dangle"
9563 xreflabel="Inf_Dangle">
9564 <entry>Inf_Dangle</entry>
9565
9566 <entry><xref linkend="EVENTS"/>.<xref
9567 linkend="Events-Behavior"/> and others</entry>
9568
9569 <entry>Chimpid &chimpid-like; identifying the
9570 individual from whom the infant is dangling.
9571 Whitespace is ignored. &special_chimpids;
9572 &bt_driven;</entry>
9573 </row>
9574
9575 <row xml:id="Upload_Behaviors-Inf_Rejection"
9576 xreflabel="Inf_Rejection">
9577 <entry>Inf_Rejection</entry>
9578
9579 <entry><xref linkend="EVENTS"/>.<xref
9580 linkend="Events-Behavior"/> and others</entry>
9581
9582 <entry>Chimpid &chimpid-like; identifying the
9583 individual rejecting the infant. Whitespace is
9584 ignored. &special_chimpids; &bt_driven;</entry>
9585 </row>
9586
9587 <row xml:id="Upload_Behaviors-Inf_Touching_Another"
9588 xreflabel="Inf_Touching_Another">
9589 <entry>Inf_Touching_Another</entry>
9590
9591 <entry><xref linkend="EVENTS"/>.<xref
9592 linkend="Events-Behavior"/> and others</entry>
9593
9594 <entry>Chimpids &chimpid-like; identifying the
9595 individuals involved (in a non-directed fashion) in
9596 touch with the infant. Whitespace is ignored.
9597 &special_chimpids; &bt_driven;</entry>
9598 </row>
9599
9600 <row xml:id="Upload_Behaviors-Inf_Grooming"
9601 xreflabel="Inf_Grooming">
9602 <entry>Inf_Grooming</entry>
9603
9604 <entry><xref linkend="EVENTS"/>.<xref
9605 linkend="Events-Behavior"/> and others</entry>
9606
9607 <entry>Chimpids &chimpid-like; identifying the
9608 individuals whom the infant is grooming. Whitespace
9609 is ignored. &special_chimpids; &bt_driven;</entry>
9610 </row>
9611
9612 <row xml:id="Upload_Behaviors-Inf_Being_Groomed"
9613 xreflabel="Inf_Being_Groomed">
9614 <entry>Inf_Being_Groomed</entry>
9615
9616 <entry><xref linkend="EVENTS"/>.<xref
9617 linkend="Events-Behavior"/> and others</entry>
9618
9619 <entry>Chimpids &chimpid-like; identifying the
9620 individuals who are grooming the infant. Whitespace
9621 is ignored. &special_chimpids; &bt_driven;</entry>
9622 </row>
9623
9624 <row xml:id="Upload_Behaviors-Inf_Social_Play"
9625 xreflabel="Inf_Social_Play">
9626 <entry>Inf_Social_Play</entry>
9627
9628 <entry><xref linkend="EVENTS"/>.<xref
9629 linkend="Events-Behavior"/> and others</entry>
9630
9631 <entry>Chimpids &chimpid-like; identifying the
9632 individuals participating in play with the infant.
9633 Whitespace is ignored. &special_chimpids;
9634 &bt_driven;</entry>
9635 </row>
9636
9637 <row xml:id="Upload_Behaviors-Inf_Display"
9638 xreflabel="Inf_Display">
9639 <entry>Inf_Display</entry>
9640
9641 <entry><xref linkend="EVENTS"/>.<xref
9642 linkend="Events-Behavior"/> and others</entry>
9643
9644 <entry>Chimpids &chimpid-like; indicator of whether
9645 the infant is displaying and to which individuals.
9646 Whitespace is ignored. &special_chimpids;
9647 &bt_driven;</entry>
9648 </row>
9649
9650 <row xml:id="Upload_Behaviors-Inf_Cry"
9651 xreflabel="Inf_Cry">
9652 <entry>Inf_Cry</entry>
9653
9654 <entry><xref linkend="VOCS"/>.<xref
9655 linkend="Vocs-Vocalization"/> and others</entry>
9656
9657 <entry>Whether the infant is crying.
9658 &semi_boolean; &bt_driven;</entry>
9659 </row>
9660
9661 <row xml:id="Upload_Behaviors-Inf_Voc" xreflabel="Inf_Voc">
9662 <entry>Inf_Voc (Infant's Vocalization Codes</entry>
9663
9664 <entry><xref linkend="VOCS"/>.<xref
9665 linkend="Vocs-Vocalization"/> and others</entry>
9666
9667 <entry><para>Infant's vocalization codes, separated by
9668 the comma (&gmi_chimpid_delim;) character. This
9669 is translated into the codes used within Gombe-MI
9670 by reference to the <xref linkend="VOC_TRANS"/>
9671 table.</para>
9672
9673 <para>Whitespace is ignored.</para></entry>
9674 </row>
9675
9676 <row xml:id="Upload_Behaviors-Inf_Beg"
9677 xreflabel="Inf_Beg">
9678 <entry>Inf_Beg</entry>
9679
9680 <entry><xref linkend="EVENTS"/>.<xref
9681 linkend="Events-Behavior"/> and others</entry>
9682
9683 <entry>Chimpids &chimpid-like; identifying the
9684 individuals from which the infant is begging.
9685 Whitespace is ignored. &special_chimpids;
9686 &bt_driven;</entry>
9687 </row>
9688
9689 <row xml:id="Upload_Behaviors-Inf_ASSR"
9690 xreflabel="Inf_ASSR">
9691 <entry>Inf_ASSR</entry>
9692
9693 <entry><xref linkend="EVENTS"/>.<xref
9694 linkend="Events-Behavior"/> and others</entry>
9695
9696 <entry>Chimpids &chimpid-like; identifying the
9697 individuals against whom the infant is ASSR-ing.
9698 Whitespace is ignored. &special_chimpids;
9699 &bt_driven;</entry>
9700 </row>
9701
9702 <row xml:id="Upload_Behaviors-Inf_Sex_Related"
9703 xreflabel="Inf_Sex_Related">
9704 <entry>Inf_Sex_Related</entry>
9705
9706 <entry><xref linkend="EVENTS"/>.<xref
9707 linkend="Events-Behavior"/> and others</entry>
9708
9709 <entry>Chimpids &chimpid-like; identifying the
9710 individuals with whom the infant is engaging in sex
9711 related behavior. The behavior is directed and the
9712 infant is the actor. Whitespace is ignored.
9713 &special_chimpids; &bt_driven;</entry>
9714 </row>
9715
9716 <row xml:id="Upload_Behaviors-Inf_Tooluse"
9717 xreflabel="Inf_Tooluse">
9718 <entry>Inf_Tooluse</entry>
9719
9720 <entry><xref linkend="EVENTS"/>.<xref
9721 linkend="Events-Behavior"/> and others</entry>
9722
9723 <entry>Whether the infant is using a tool. &semi_boolean;
9724 &bt_driven;</entry>
9725 </row>
9726
9727 <row xml:id="Upload_Behaviors-Inf_Directaggression"
9728 xreflabel="Inf_Directaggression">
9729 <entry>Inf_Directaggression</entry>
9730
9731 <entry><xref linkend="EVENTS"/>.<xref
9732 linkend="Events-Behavior"/> and others</entry>
9733
9734 <entry>Chimpids &chimpid-like; identifying the
9735 individuals against whom the infant is engaging in
9736 direct aggression. The behavior is directed and the
9737 infant is the actor. Whitespace is ignored.
9738 &special_chimpids; &bt_driven;</entry>
9739 </row>
9740
9741 <row xml:id="Upload_Behaviors-Sib_Bad_Observation"
9742 xreflabel="Sib_Bad_Observation">
9743 <entry>Sib_Bad_Observation</entry>
9744
9745 <entry><xref linkend="DISTANCES"/>.<xref
9746 linkend="Distances-Uncertain"/>,
9747 <xref linkend="EVENTS"/>.<xref
9748 linkend="Events-Uncertain"/></entry>
9749
9750 <entry>This column is used in conjunction with other
9751 columns to indicate observation certainty of sibling
9752 related data. The legal values for this column
9753 are: <literal>&gmi_badobs_y;</literal>, meaning the sibling
9754 data is
9755 uncertain; <literal>&gmi_ignore_mark;</literal> or
9756 &null; meaning the Sib_Bad_Observation column does not
9757 influence whether sibling related data is uncertain.
9758 See <link linkend="Bad_Obs">the description</link> of
9759 how certainty is determined above.</entry>
9760 </row>
9761
9762 <row xml:id="Upload_Behaviors-Sib_Behavior"
9763 xreflabel="Sib_Behavior">
9764 <entry>Sib_Behavior</entry>
9765
9766 <entry><xref linkend="EVENTS"/>.<xref
9767 linkend="Events-Behavior"/></entry>
9768
9769 <entry><para>Sibling's behavior codes. This is translated
9770 into the codes used within Gombe-MI by reference to
9771 the <xref linkend="BEHAVIOR_TRANS"/> table.</para>
9772
9773 <para>Multiple behaviors are separated from each
9774 other by the <literal>&gmi_behavior_delim;</literal>
9775 character. Whitespace is ignored.</para></entry>
9776 </row>
9777
9778 <row xml:id="Upload_Behaviors-Sib_Foodpart"
9779 xreflabel="Sib_Foodpart">
9780 <entry>Sib_Foodpart</entry>
9781
9782 <entry><xref linkend="EATS"/>.<xref
9783 linkend="Eats-Foodpart"/></entry>
9784
9785 <entry><para>Sibling's food part codes of food eaten.
9786 This is translated into the codes used within
9787 Gombe-MI by reference to the
9788 <xref linkend="FOODPART_TRANS"/> table.</para>
9789
9790 <para>Multiple food part codes are separated from
9791 each other by
9792 the <literal>&gmi_behavior_delim;</literal>
9793 character. Whitespace is ignored.</para></entry>
9794 </row>
9795
9796 <row xml:id="Upload_Behaviors-Sib_Foodkind"
9797 xreflabel="Sib_Foodkind">
9798 <entry>Sib_Foodkind</entry>
9799
9800 <entry><xref linkend="EATS"/>.<xref
9801 linkend="Eats-Foodkind"/></entry>
9802
9803 <entry><para>Sibling's food kind code of food
9804 eaten.</para></entry>
9805 </row>
9806
9807 <row xml:id="Upload_Behaviors-Sib_Fishpart"
9808 xreflabel="Sib_Fishpart">
9809 <entry>Sib_Fishpart</entry>
9810
9811 <entry><xref linkend="FISHED"/>.<xref
9812 linkend="Fished-Foodpart"/></entry>
9813
9814 <entry><para>Sibling's food part codes of foods fished
9815 for. This is translated into the codes used
9816 within Gombe-MI by reference to the
9817 <xref linkend="FOODPART_TRANS"/> table.</para>
9818
9819 <para>Multiple food part codes are separated from
9820 each other by
9821 the <literal>&gmi_behavior_delim;</literal>
9822 character. Whitespace is ignored.</para></entry>
9823 </row>
9824
9825 <row xml:id="Upload_Behaviors-Sib_Fishkind"
9826 xreflabel="Sib_Fishkind">
9827 <entry>Sib_Fishkind</entry>
9828
9829 <entry><xref linkend="FISHED"/>.<xref
9830 linkend="Fished-Foodkind"/></entry>
9831
9832 <entry><para>Sibling's food kind code of food fished
9833 for.</para></entry>
9834 </row>
9835
9836 <row xml:id="Upload_Behaviors-Sib_Play" xreflabel="Sib_Play">
9837 <entry>Sib_Play</entry>
9838
9839 <entry><xref linkend="PARTS"/>.<xref
9840 linkend="Parts-Participant"/></entry>
9841
9842 <entry>
9843 <para>Chimpids &chimpid-like; identifying the
9844 individuals whom the sibling played with.
9845 &comma_delim_elim_whitespace;
9846 &special_chimpids;</para>
9847
9848 <para>&play_role_determination;</para>
9849 </entry>
9850 </row>
9851
9852 <row xml:id="Upload_Behaviors-Sib_Grooming"
9853 xreflabel="Sib_Grooming">
9854
9855 <entry>Sib_Grooming</entry>
9856
9857 <entry><xref linkend="PARTS"/>.<xref
9858 linkend="Parts-Participant"/></entry>
9859
9860 <entry>Chimpids &chimpid-like; identifying the
9861 individuals whom the sibling groomed.
9862 &comma_delim_elim_whitespace;</entry>
9863 </row>
9864
9865 <row xml:id="Upload_Behaviors-Sib_Groomed_By"
9866 xreflabel="Sib_Groomed_By">
9867 <entry>Sib_Groomed_By</entry>
9868
9869 <entry><xref linkend="PARTS"/>.<xref
9870 linkend="Parts-Participant"/></entry>
9871
9872 <entry>Chimpids &chimpid-like; identifying the
9873 individuals whom the sibling was groomed
9874 by. &comma_delim_elim_whitespace;
9875 &special_chimpids;</entry>
9876 </row>
9877
9878 <row xml:id="Upload_Behaviors-Sib_Ride"
9879 xreflabel="Sib_Ride">
9880 <entry>Sib_Ride</entry>
9881
9882 <entry><xref linkend="PARTS"/>.<xref
9883 linkend="Parts-Participant"/></entry>
9884
9885 <entry>Chimpid &chimpid-like; identifying the
9886 individual on whom the sibling
9887 rode. &comma_delim_elim_whitespace;
9888 &special_chimpids;</entry>
9889 </row>
9890
9891 <row xml:id="Upload_Behaviors-Sib_Voc" xreflabel="Sib_Voc">
9892 <entry>Sib_Voc (Sibling's Vocalization Codes</entry>
9893
9894 <entry><xref linkend="VOCS"/>.<xref
9895 linkend="Vocs-Vocalization"/> and others</entry>
9896
9897 <entry><para>Sibling's vocalization codes, separated by
9898 the comma (&gmi_chimpid_delim;) character. This is
9899 translated into the codes used within Gombe-MI by
9900 reference to the <xref linkend="VOC_TRANS"/>
9901 table.</para>
9902
9903 <para>Whitespace is ignored.</para></entry>
9904 </row>
9905
9906 <row xml:id="Upload_Behaviors-Sib_Distance_To_Ma"
9907 xreflabel="Sib_Distance_To_Ma">
9908 <entry>Sib_Distance_To_Ma (Sibling Distance To Mother
9909 Code)</entry>
9910
9911 <entry><xref linkend="DISTANCES"/>.<xref
9912 linkend="Distances-Distance"/> and others</entry>
9913
9914 <entry><para>A code indicating the distance between
9915 mother and sibling. &dt_driven; The uploaded
9916 distance code <literal>&gmi_ignore_mark;</literal> is
9917 ignored.</para>
9918
9919 <para>The related
9920 <xref linkend="DISTANCEPARTS"/>.<xref
9921 linkend="Distanceparts-Role"/>
9922 values are always set
9923 to <literal>&gmi_mom_role;</literal>
9924 and <literal>&gmi_sib_role;</literal>.<footnote>
9925
9926 <para>Irrespective of the content of the
9927 <xref linkend="FOLLOWROLES"/> table.</para>
9928
9929 </footnote></para>
9930 </entry>
9931 </row>
9932
9933 <row xml:id="Upload_Behaviors-Sib_Distance_To_Infant"
9934 xreflabel="Sib_Distance_To_Infant">
9935 <entry>Sib_Distance_To_Infant (Sibling Distance To Infant
9936 Code)</entry>
9937
9938 <entry><xref linkend="DISTANCES"/>.<xref
9939 linkend="Distances-Distance"/> and others</entry>
9940
9941 <entry><para>A code indicating the distance between
9942 infant and sibling. &dt_driven; The uploaded
9943 distance code <literal>&gmi_ignore_mark;</literal> is
9944 ignored.</para>
9945
9946 <para>The related
9947 <xref linkend="DISTANCEPARTS"/>.<xref
9948 linkend="Distanceparts-Role"/>
9949 values are always set
9950 to <literal>&gmi_infant_role;</literal>
9951 and <literal>&gmi_sib_role;</literal>.<footnote>
9952
9953 <para>Irrespective of the content of the
9954 <xref linkend="FOLLOWROLES"/> table.</para>
9955
9956 </footnote></para>
9957 </entry>
9958 </row>
9959
9960 <row xml:id="Upload_Behaviors-Comments" xreflabel="Comments">
9961 <entry>Comments</entry>
9962
9963 <entry><xref linkend="INTERVALS"/>.<xref
9964 linkend="Intervals-Comment"/></entry>
9965
9966 <entry>
9967 <para>Comments on the behaviors occurring during the
9968 minute. Leading and trailing whitespace is removed.
9969 This value may be &null; when there are no
9970 comments.</para>
9971
9972 <caution>
9973 <para>The Comments column is
9974 processed <link linkend="UB_Comment_Processing">as
9975 described</link> and sometimes behaviors are
9976 created as a result.</para>
9977 </caution>
9978 </entry>
9979 </row>
9980
9981 </tbody>
9982 </tgroup>
9983 </informaltable>
9984 </section>
9985
9986
9987 <section xml:id="UPLOAD_BEHAVIORS-Usage-Guidelines">
9988 <title>UPLOAD_BEHAVIORS Usage Guidelines</title>
9989
9990 <para>Only <literal>INSERT</literal> is allowed on
9991 UPLOAD_BEHAVIORS. <literal>SELECT</literal>,
9992 <literal>UPDATE</literal>, and <literal>DELETE</literal> are not
9993 allowed. Inserting a row into UPLOAD_BEHAVIORS inserts rows
9994 into the follow related tables as described above.</para>
9995 </section>
9996 </section>
9997 </section>
9998
9999 <section xml:id="event_views">
10000 <title>&event_section; Views</title>
10001
10002 <para>The most general views are the
10003 <xref linkend="SOCIAL_EVENTS_W_BABOONS"/> and the
10004 <xref linkend="ASOCIAL_EVENTS"/> views. Taken together these 2
10005 views return (1 or more) rows for all behavioral events. They are
10006 suitable for use in arbitrary queries and are probably the best
10007 choice in most cases. For the most part, the
10008 <xref linkend="SOCIAL_EVENTS"/> view should be used in place of
10009 the <xref linkend="SOCIAL_EVENTS_W_BABOONS"/> view since it does
10010 not contain rows for social interactions with baboons.</para>
10011
10012 <para>The <xref linkend="ASOCIAL_EVENTS"/>,
10013 <xref linkend="SOCIAL_EVENTS"/>, and
10014 <xref linkend="SOCIAL_EVENTS_W_BABOONS"/> views, have columns for
10015 each animal involved to encode the following properties: the
10016 animal's chimpid, the animal's role in the follow (mom, infant,
10017 sib, nonfocal), and the animal's role (part) in the behavioral event
10018 (self, actor, actee, participant). When using the
10019 <xref linkend="ASOCIAL_EVENTS"/>, <xref linkend="SOCIAL_EVENTS"/>,
10020 and <xref linkend="SOCIAL_EVENTS_W_BABOONS"/> views these 3 columns
10021 must often be tested in tandem to obtain the desired results. The
10022 other views in this section also often have these columns, or a
10023 subset of them, but are designed to reduce the need to test all 3 of
10024 these values together.</para>
10025
10026 <para>The <xref linkend="ACTOR_ACTEES_W_BABOONS"/> and
10027 <xref linkend="ACTOR_ACTEES"/> views can be simpler to use than the
10028 <xref linkend="SOCIAL_EVENTS_W_BABOONS"/> and
10029 <xref linkend="SOCIAL_EVENTS"/> views when interested in directed
10030 behaviors. The <xref linkend="ACTOR_ACTEES_W_BABOONS"/> and
10031 <xref linkend="ACTOR_ACTEES"/> views contain at most a single row
10032 per behavioral event and classify the individuals involved into
10033 separate columns for actor and actee.</para>
10034
10035 <para>The <xref linkend="FOCAL_SOCIAL_EVENTS"/> and
10036 <xref linkend="FOCAL_EVENTS"/> views classify the involved
10037 individuals based on whether or not they are focals in the follow;
10038 there is a set of <quote>focal</quote> columns to describe (one of)
10039 the focals involved in the interaction and a set of
10040 <quote>other</quote> columns to describe the 2nd individual involved
10041 in the interaction. This may be less useful than it first appears.
10042 Because many interactions are between focals a focal often shows up
10043 in the <quote>other</quote> columns and those interactions that are
10044 between focals have two rows in these views. There are 2 rows per
10045 event so that each focal can show up once in
10046 the <quote>focal</quote> category.</para>
10047
10048 <para>The <xref linkend="FOCAL_EVENTS"/> view is different in that
10049 it contains at least one row for every recorded behavioral
10050 interaction.</para>
10051
10052 <para>The <xref linkend="FAMILY_EVENTS"/> view contains exactly
10053 one row for each recorded behavioral interaction, with columns
10054 structured in a fashion somewhat like the way behavioral data is
10055 recorded. This is helpful when checking data in the system
10056 against the data as it comes from the field. The family_events
10057 view is also useful for changing database content, an operation
10058 usually based on data recorded in the field. But the
10059 correspondence between the columns of the
10060 <xref linkend="FAMILY_EVENTS"/> view and the paper records is
10061 likely to be less useful than it seems when it comes to analysis
10062 because queries must be written with foreknowledge of who plays
10063 what function (mom, infant, sib) in the follow rather than relying
10064 on the system to inform. The <xref linkend="FAMILY_EVENTS"/> view
10065 cannot distinguish between twins and singleton offspring whereas
10066 the other views can. <footnote>
10067
10068 <para>Assuming that the <xref linkend="FOLLOWROLES"/> table
10069 contains rows to distinguish twins.</para>
10070
10071 </footnote> Further, the <xref linkend="FAMILY_EVENTS"/> view is by
10072 far the least efficient in its execution. Data analysis will
10073 probably be better served by spending the time to learn to use the
10074 other views.</para>
10075
10076 <para>All these views have slightly different implementations and
10077 some may perform better than others depending on the circumstances
10078 of use.</para>
10079
10080 <note>
10081 <para>While it is certainly possible to create more specialized
10082 behavioral views than those described here to encompass all the
10083 relevant combinatorial parings of mom, infant, sib, and nonfocal,
10084 as well as the orthogonal categories of directed and non-directed
10085 social interactions and asocial interactions it is hoped that
10086 enough skill writing queries in SQL will be developed that the
10087 existing views will suffice. One useful SQL technique can be
10088 found in the <xref linkend="Queries"/> section above.</para>
10089 </note>
10090
10091 <section xml:id="ACTOR_ACTEES"
10092 xreflabel="ACTOR_ACTEES">
10093 <title>ACTOR_ACTEES (Dyadic Directed Behavioral Events)</title>
10094
10095 <para>ACTOR_ACTEES contains one row per
10096 <xref linkend="EVENTS"/> row where there are 2 chimpanzees involved in
10097 an actor/actee behavioral even. Events involving
10098 baboons are excluded. ACTOR_ACTEES provides a straightforward way to
10099 analyze social behaviors from the perspective of who is initiating
10100 and who receiving the behavior.</para>
10101
10102 <section xml:id="ACTOR_ACTEES-Definition">
10103 <title>ACTOR_ACTEES Definition</title>
10104
10105 <xi:include
10106 href="views/actor_actees.xml"
10107 xmlns:xi="http://www.w3.org/2001/XInclude"/>
10108 </section>
10109
10110 <section xml:id="Actor_Actees-Columns">
10111 <title>ACTOR_ACTEES Columns</title>
10112
10113 <informaltable frame="topbot">
10114 <tgroup cols="3" colsep="0" rowsep="0">
10115 <colspec colnum="3" rowsep="1"/>
10116 <thead>
10117 <row rowsep="1">
10118 <entry>Column</entry>
10119 <entry>From</entry>
10120 <entry>Description</entry>
10121 </row>
10122 </thead>
10123
10124 <tbody>
10125 <row xml:id="Actor_Actees-EID" xreflabel="EID">
10126 <entry>EID</entry>
10127
10128 <entry><xref linkend="EVENTS"/>.<xref
10129 linkend="Events-EID"/></entry>
10130
10131 <entry>Identifier of the
10132 behavioral event row.</entry>
10133 </row>
10134
10135 <row xml:id="Actor_Actees-IntID" xreflabel="IntID">
10136 <entry>IntID</entry>
10137
10138 <entry><xref linkend="EVENTS"/>.<xref
10139 linkend="Events-IntID"/></entry>
10140
10141 <entry>Identifier of the observation interval during
10142 which the event was recorded.</entry>
10143 </row>
10144
10145 <row xml:id="Actor_Actees-ActorPID"
10146 xreflabel="ActorPID">
10147 <entry>ActorPID</entry>
10148
10149 <entry><xref linkend="PARTS"/>.<xref
10150 linkend="Parts-PID"/></entry>
10151
10152 <entry>Identifier of the behavioral participant row which
10153 records behavioral data regarding the chimpanzee who is the
10154 actor in the behavior.</entry>
10155 </row>
10156
10157 <row xml:id="Actor_Actees-ActeePID"
10158 xreflabel="ActeePID">
10159 <entry>ActeePID</entry>
10160
10161 <entry><xref linkend="PARTS"/>.<xref
10162 linkend="Parts-PID"/></entry>
10163
10164 <entry>Identifier of the behavioral participant row which
10165 records behavioral data regarding the chimpanzee who is
10166 the actee in the behavior.</entry>
10167 </row>
10168
10169 <row xml:id="Actor_Actees-Behavior"
10170 xreflabel="Behavior">
10171 <entry>Behavior</entry>
10172
10173 <entry><xref linkend="EVENTS"/>.<xref
10174 linkend="Events-Behavior"/></entry>
10175
10176 <entry>Code indicating the behavior observed.</entry>
10177 </row>
10178
10179 <row xml:id="Actor_Actees-Position"
10180 xreflabel="Position">
10181 <entry>Position</entry>
10182
10183 <entry><xref linkend="EVENTS"/>.<xref
10184 linkend="Events-Position"/></entry>
10185
10186 <entry>Position within the canopy where the event
10187 occurred.</entry>
10188 </row>
10189
10190 <row xml:id="Actor_Actees-Uncertain"
10191 xreflabel="Uncertain">
10192 <entry>Uncertain</entry>
10193
10194 <entry><xref linkend="EVENTS"/>.<xref
10195 linkend="Events-Uncertain"/></entry>
10196
10197 <entry>Whether or not the behavior was observed with
10198 certainty.</entry>
10199 </row>
10200
10201 <row xml:id="Actor_Actees-ActorRole"
10202 xreflabel="ActorRole">
10203 <entry>ActorRole (Role in Follow of Actor)</entry>
10204
10205 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10206 linkend="Followparts-Role"/></entry>
10207
10208 <entry>Code for the role, i.e. mom, sib,
10209 infant, played by the animal who is the actor in the
10210 behavior.</entry>
10211 </row>
10212
10213 <row xml:id="Actor_Actees-Actor"
10214 xreflabel="Actor">
10215 <entry>Actor</entry>
10216
10217 <entry><xref linkend="PARTS"/>.<xref
10218 linkend="Parts-Participant"/></entry>
10219
10220 <entry>The identifier or alternate identifier of the
10221 actor.</entry>
10222 </row>
10223
10224 <row xml:id="Actor_Actees-ActeeRole"
10225 xreflabel="ActeeRole">
10226 <entry>ActeeRole (Role in Follow of Actee)</entry>
10227
10228 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10229 linkend="Followparts-Role"/></entry>
10230
10231 <entry>Code for the role, i.e. mom, sib,
10232 infant, played by the chimpanzee who is the actee in
10233 the behavior.</entry>
10234 </row>
10235
10236 <row xml:id="Actor_Actees-Actee"
10237 xreflabel="Actee">
10238 <entry>Actee</entry>
10239
10240 <entry><xref linkend="PARTS"/>.<xref
10241 linkend="Parts-Participant"/></entry>
10242
10243 <entry>The identifier or alternate identifier of the
10244 actee.</entry>
10245 </row>
10246
10247 <row xml:id="Actor_Actees-Comment"
10248 xreflabel="Comment">
10249 <entry>Comment</entry>
10250
10251 <entry><xref linkend="EVENTS"/>.<xref
10252 linkend="Events-Comment"/></entry>
10253
10254 <entry>Textual remarks regarding the behavioral
10255 event.</entry>
10256 </row>
10257
10258 </tbody>
10259 </tgroup>
10260 </informaltable>
10261
10262 </section>
10263
10264
10265 <section xml:id="ACTOR_ACTEES-Usage-Guidelines">
10266 <title>ACTOR_ACTEES Usage Guidelines</title>
10267
10268 <para>Only <literal>SELECT</literal> is allowed on
10269 ACTOR_ACTEES. <literal>INSERT</literal>, <literal>UPDATE</literal>,
10270 and <literal>DELETE</literal> are not allowed.</para>
10271 </section>
10272 </section>
10273
10274 <section xml:id="ACTOR_ACTEES_W_BABOONS"
10275 xreflabel="ACTOR_ACTEES_W_BABOONS">
10276 <title>ACTOR_ACTEES_W_BABOONS (Dyadic Directed Behavioral Events
10277 Including Baboons)</title>
10278 <titleabbrev>ACTOR_ACTEES_W_BABOONS (Dyadic Directed Behavioral Events
10279 w. Baboons)</titleabbrev>
10280
10281 <para>ACTOR_ACTEES_W_BABOONS contains one row per
10282 <xref linkend="EVENTS"/> row where there are 2 animals involved in
10283 an actor/actee behavioral event, including events involving
10284 baboons. ACTOR_ACTEES_W_BABOONS provides a straightforward way to
10285 analyze social behaviors from the perspective of who is initiating
10286 and who receiving the behavior.</para>
10287
10288 <section xml:id="ACTOR_ACTEES_W_BABOONS-Definition">
10289 <title>ACTOR_ACTEES_W_BABOONS Definition</title>
10290
10291 <xi:include
10292 href="views/actor_actees_w_baboons.xml"
10293 xmlns:xi="http://www.w3.org/2001/XInclude"/>
10294 </section>
10295
10296 <section xml:id="Actor_Actees_W_Baboons-Columns">
10297 <title>ACTOR_ACTEES_W_BABOONS Columns</title>
10298
10299 <informaltable frame="topbot">
10300 <tgroup cols="3" colsep="0" rowsep="0">
10301 <colspec colnum="3" rowsep="1"/>
10302 <thead>
10303 <row rowsep="1">
10304 <entry>Column</entry>
10305 <entry>From</entry>
10306 <entry>Description</entry>
10307 </row>
10308 </thead>
10309
10310 <tbody>
10311 <row xml:id="Actor_Actees_W_Baboons-EID" xreflabel="EID">
10312 <entry>EID</entry>
10313
10314 <entry><xref linkend="EVENTS"/>.<xref
10315 linkend="Events-EID"/></entry>
10316
10317 <entry>Identifier of the
10318 behavioral event row.</entry>
10319 </row>
10320
10321 <row xml:id="Actor_Actees_W_Baboons-IntID" xreflabel="IntID">
10322 <entry>IntID</entry>
10323
10324 <entry><xref linkend="EVENTS"/>.<xref
10325 linkend="Events-IntID"/></entry>
10326
10327 <entry>Identifier of the observation interval during
10328 which the event was recorded.</entry>
10329 </row>
10330
10331 <row xml:id="Actor_Actees_W_Baboons-ActorPID"
10332 xreflabel="ActorPID">
10333 <entry>ActorPID</entry>
10334
10335 <entry><xref linkend="PARTS"/>.<xref
10336 linkend="Parts-PID"/></entry>
10337
10338 <entry>Identifier of the behavioral participant row which
10339 records behavioral data regarding the animal who is the
10340 actor in the behavior.</entry>
10341 </row>
10342
10343 <row xml:id="Actor_Actees_W_Baboons-ActeePID"
10344 xreflabel="ActeePID">
10345 <entry>ActeePID</entry>
10346
10347 <entry><xref linkend="PARTS"/>.<xref
10348 linkend="Parts-PID"/></entry>
10349
10350 <entry>Identifier of the behavioral participant row which
10351 records behavioral data regarding the animal who is the
10352 actee in the behavior.</entry>
10353 </row>
10354
10355 <row xml:id="Actor_Actees_W_Baboons-Behavior"
10356 xreflabel="Behavior">
10357 <entry>Behavior</entry>
10358
10359 <entry><xref linkend="EVENTS"/>.<xref
10360 linkend="Events-Behavior"/></entry>
10361
10362 <entry>Code indicating the behavior observed.</entry>
10363 </row>
10364
10365 <row xml:id="Actor_Actees_W_Baboons-Position"
10366 xreflabel="Position">
10367 <entry>Position</entry>
10368
10369 <entry><xref linkend="EVENTS"/>.<xref
10370 linkend="Events-Position"/></entry>
10371
10372 <entry>Position within the canopy where the event
10373 occurred.</entry>
10374 </row>
10375
10376 <row xml:id="Actor_Actees_W_Baboons-Uncertain"
10377 xreflabel="Uncertain">
10378 <entry>Uncertain</entry>
10379
10380 <entry><xref linkend="EVENTS"/>.<xref
10381 linkend="Events-Uncertain"/></entry>
10382
10383 <entry>Whether or not the behavior was observed with
10384 certainty.</entry>
10385 </row>
10386
10387 <row xml:id="Actor_Actees_W_Baboons-ActorRole"
10388 xreflabel="ActorRole">
10389 <entry>ActorRole (Role in Follow of Actor)</entry>
10390
10391 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10392 linkend="Followparts-Role"/> or <literal>NF</literal>
10393 in the case of baboons or nonfocal chimpanzees</entry>
10394
10395 <entry>Code for the role, i.e. mom, sib,
10396 infant, played by the animal who is the actor in the
10397 behavior.</entry>
10398 </row>
10399
10400 <row xml:id="Actor_Actees_W_Baboons-BaboonActor"
10401 xreflabel="BaboonActor">
10402 <entry>BaboonActor</entry>
10403
10404 <entry>Computed</entry>
10405
10406 <entry>A Boolean value, true when the actor is a
10407 baboon.</entry>
10408 </row>
10409
10410 <row xml:id="Actor_Actees_W_Baboons-Actor"
10411 xreflabel="Actor">
10412 <entry>Actor</entry>
10413
10414 <entry><xref linkend="PARTS"/>.<xref
10415 linkend="Parts-Participant"/></entry>
10416
10417 <entry>The identifier or alternate identifier of the
10418 actor, or &null; if the actor is a baboon.</entry>
10419 </row>
10420
10421 <row xml:id="Actor_Actees_W_Baboons-ActeeRole"
10422 xreflabel="ActeeRole">
10423 <entry>ActeeRole (Role in Follow of Actee)</entry>
10424
10425 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10426 linkend="Followparts-Role"/> or <literal>NF</literal>
10427 in the case of baboons or nonfocal chimpanzees</entry>
10428
10429 <entry>Code for the role, i.e. mom, sib,
10430 infant, played by the animal who is the actee in the
10431 behavior.</entry>
10432 </row>
10433
10434 <row xml:id="Actor_Actees_W_Baboons-BaboonActee"
10435 xreflabel="BaboonActee">
10436 <entry>BaboonActee</entry>
10437
10438 <entry>Computed</entry>
10439
10440 <entry>A Boolean value, true when the actee is a
10441 baboon.</entry>
10442 </row>
10443
10444 <row xml:id="Actor_Actees_W_Baboons-Actee"
10445 xreflabel="Actee">
10446 <entry>Actee</entry>
10447
10448 <entry><xref linkend="PARTS"/>.<xref
10449 linkend="Parts-Participant"/></entry>
10450
10451 <entry>The identifier or alternate identifier of the
10452 actee, or &null; if the actee is a baboon.</entry>
10453 </row>
10454
10455 <row xml:id="Actor_Actees_W_Baboons-Comment"
10456 xreflabel="Comment">
10457 <entry>Comment</entry>
10458
10459 <entry><xref linkend="EVENTS"/>.<xref
10460 linkend="Events-Comment"/></entry>
10461
10462 <entry>Textual remarks regarding the behavioral
10463 event.</entry>
10464 </row>
10465
10466 </tbody>
10467 </tgroup>
10468 </informaltable>
10469
10470 </section>
10471
10472
10473 <section xml:id="ACTOR_ACTEES_W_BABOONS-Usage-Guidelines">
10474 <title>ACTOR_ACTEES_W_BABOONS Usage Guidelines</title>
10475
10476 <para>Only <literal>SELECT</literal> is allowed on
10477 ACTOR_ACTEES_W_BABOONS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
10478 and <literal>DELETE</literal> are not allowed.</para>
10479 </section>
10480 </section>
10481
10482 <section xml:id="ASOCIAL_EVENTS" xreflabel="ASOCIAL_EVENTS">
10483 <title>ASOCIAL_EVENTS (Non-Social Behavioral Events)</title>
10484
10485 <para>ASOCIAL_EVENTS contains one row per <xref linkend="EVENTS"/>
10486 row per when there is a related <xref linkend="PARTS"/> row having
10487 a <xref linkend="Parts-Part"/> value
10488 of <literal>&gmi_self;</literal>. ASOCIAL_EVENTS provides a
10489 direct way to analyze non-social behaviors, those behaviors
10490 involving a single chimp and no other animal.</para>
10491
10492 <section xml:id="ASOCIAL_EVENTS-Definition">
10493 <title>ASOCIAL_EVENTS Definition</title>
10494
10495 <xi:include
10496 href="views/asocial_events.xml"
10497 xmlns:xi="http://www.w3.org/2001/XInclude"/>
10498 </section>
10499
10500 <section xml:id="Asocial_Events-Columns">
10501 <title>ASOCIAL_EVENTS Columns</title>
10502
10503 <informaltable frame="topbot">
10504 <tgroup cols="3" colsep="0" rowsep="0">
10505 <colspec colnum="3" rowsep="1"/>
10506 <thead>
10507 <row rowsep="1">
10508 <entry>Column</entry>
10509 <entry>From</entry>
10510 <entry>Description</entry>
10511 </row>
10512 </thead>
10513
10514 <tbody>
10515 <row xml:id="Asocial_Events-EID" xreflabel="EID">
10516 <entry>EID</entry>
10517
10518 <entry><xref linkend="EVENTS"/>.<xref
10519 linkend="Events-EID"/></entry>
10520
10521 <entry>Identifier of the
10522 behavioral event row.</entry>
10523 </row>
10524
10525 <row xml:id="Asocial_Events-IntID" xreflabel="IntID">
10526 <entry>IntID</entry>
10527
10528 <entry><xref linkend="EVENTS"/>.<xref
10529 linkend="Events-IntID"/></entry>
10530
10531 <entry>Identifier of the observation interval during
10532 which the event was recorded.</entry>
10533 </row>
10534
10535 <row xml:id="Asocial_Events-PID" xreflabel="PID">
10536 <entry>PID</entry>
10537
10538 <entry><xref linkend="PARTS"/>.<xref
10539 linkend="Parts-PID"/></entry>
10540
10541 <entry>Identifier of the behavioral participant row
10542 which records behavioral data regarding the individual
10543 exhibiting the behavior.</entry>
10544 </row>
10545
10546 <row xml:id="Asocial_Events-Behavior" xreflabel="Behavior">
10547 <entry>Behavior</entry>
10548
10549 <entry><xref linkend="EVENTS"/>.<xref
10550 linkend="Events-Behavior"/></entry>
10551
10552 <entry>Code indicating the behavior observed.</entry>
10553 </row>
10554
10555 <row xml:id="Asocial_Events-Position" xreflabel="Position">
10556 <entry>Position</entry>
10557
10558 <entry><xref linkend="EVENTS"/>.<xref
10559 linkend="Events-Position"/></entry>
10560
10561 <entry>Position within the canopy where the event
10562 occurred.</entry>
10563 </row>
10564
10565 <row xml:id="Asocial_Events-Uncertain" xreflabel="Uncertain">
10566 <entry>Uncertain</entry>
10567
10568 <entry><xref linkend="EVENTS"/>.<xref
10569 linkend="Events-Uncertain"/></entry>
10570
10571 <entry>Whether or not the behavior was observed with
10572 certainty.</entry>
10573 </row>
10574
10575 <row xml:id="Asocial_Events-Role" xreflabel="Role">
10576 <entry>Role (Role in Follow of Chimp)</entry>
10577
10578 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10579 linkend="Followparts-Role"/></entry>
10580
10581 <entry>Code for the role, i.e. mom, sib, infant, played
10582 by the individual involved in the behavioral
10583 event.</entry>
10584 </row>
10585
10586 <row xml:id="Asocial_Events-Participant" xreflabel="Participant">
10587 <entry>Participant</entry>
10588
10589 <entry><xref linkend="PARTS"/>.<xref
10590 linkend="Parts-Participant"/></entry>
10591
10592 <entry>The identifier or alternate identifier of the
10593 individual exhibiting the behavior.</entry>
10594 </row>
10595
10596 <row xml:id="Asocial_Events-Comment" xreflabel="Comment">
10597 <entry>Comment</entry>
10598
10599 <entry><xref linkend="EVENTS"/>.<xref
10600 linkend="Events-Comment"/></entry>
10601
10602 <entry>Textual remarks regarding the behavioral
10603 event.</entry>
10604 </row>
10605
10606 </tbody>
10607 </tgroup>
10608 </informaltable>
10609
10610 </section>
10611
10612
10613 <section xml:id="ASOCIAL_EVENTS-Usage-Guidelines">
10614 <title>ASOCIAL_EVENTS Usage Guidelines</title>
10615
10616 <para>Only <literal>SELECT</literal> is allowed on
10617 ASOCIAL_EVENTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
10618 and <literal>DELETE</literal> are not allowed.</para>
10619 </section>
10620 </section>
10621
10622 <section xml:id="EVENT_BOUTS" xreflabel="EVENT_BOUTS">
10623 <title>EVENT_BOUTS (Analysis of the focals' Behavioral Bouts,
10624 per Minute)</title>
10625
10626 <para>An event bout is defined as a contiguous series of minutes
10627 during which a focal is involved in a behavior. However,
10628 behavioral events involving baboons are excluded when
10629 considering contiguity. Behaviors are distinguished by the codes
10630 used to represent them. An individual can be involved in more
10631 than one event bout at a time, if involved in more than one
10632 behavior at a time.</para>
10633
10634 <para>EVENT_BOUTS contains one row per
10635 <xref linkend="FOLLOWPARTS"/> row per
10636 <xref linkend="INTERVALS"/> row, per
10637 <xref linkend="EVENTS"/>.<xref linkend="Events-Behavior"/> value
10638 having a related <xref linkend="PARTS"/> row that shows the
10639 given focal involved in the given behavior -- one row per
10640 follow, per focal, per interval in which the focal is involved
10641 in a behavior (excluding behavioral events which involve a
10642 baboon), per code for the behavior involved in. The number of
10643 rows returned is not affected by the number of times the focal
10644 is involved in the behavior during any given interval, nor is it
10645 affected by the behavioral role the focal plays regards the
10646 behavior. There is a row per focal per behavior the focal is
10647 involved in per interval, excluding cases where a baboon is
10648 involved.</para>
10649
10650 <para>Event bouts are numbered sequentially, in a time-wise order,
10651 per follow, per focal, per behavior, starting with 1.</para>
10652
10653 <para>Bouts are said to be <wordasword>censored</wordasword>,
10654 either on the left (earlier) or on the right (later) if
10655 the <quote>edge</quote> of the bout exists because there is a
10656 lack of behavioral data on the given focal. Censoring can occur
10657 because of <quote>badobs</quote>, because observation has not
10658 started or because observation finishes, or any other time there
10659 is no behavioral data what so ever on the focal. Note that
10660 censoring or lack thereof of any one focal is not affected by
10661 data or lack thereof on any other focal. Note also that
10662 observations involving baboons are not excluded when it comes to
10663 considering whether a bout is censored. Baboon related
10664 observations are like any other behavioral events involving the
10665 focal when it comes to considering whether behavioral data
10666 exists.</para>
10667
10668 <para>Likewise, the columns that indicate censoring due to the
10669 start of observation at the beginning of the day and end of
10670 observation at the end of the day are per-focal and not affected
10671 by observations that may or may not be made on the other
10672 focals.</para>
10673
10674 <para>Note that uncertain behavioral events are not distinguished
10675 from certain behavioral events in event bout analysis, although
10676 the EVENT_BOUTS view does provide some information regarding
10677 uncertainty.</para>
10678
10679 <tip>
10680 <para>Since the EVENT_BOUTS view can take a number of minutes
10681 to return results it may be desirable to put the results of
10682 interest into a table for repeated analysis. If this is done
10683 it is very likely a good idea to add indexes to most of the
10684 new table's columns. This will greatly improve
10685 performance.</para>
10686 </tip>
10687
10688
10689 <tip>
10690 <para>The sum of <xref linkend="Event_Bouts-Mins_In"/> and
10691 <xref linkend="Event_Bouts-Mins_Out"/> is the total number of
10692 minutes in the event bout.</para>
10693 </tip>
10694
10695 <section xml:id="EVENT_BOUTS-Definition">
10696 <title>EVENT_BOUTS Definition</title>
10697
10698 <xi:include
10699 href="views/event_bouts.xml"
10700 xmlns:xi="http://www.w3.org/2001/XInclude"/>
10701 </section>
10702
10703 <section xml:id="Event_Bouts-Columns">
10704 <title>EVENT_BOUTS Columns</title>
10705
10706 <informaltable frame="topbot">
10707 <tgroup cols="3" colsep="0" rowsep="0">
10708 <colspec colnum="3" rowsep="1"/>
10709 <thead>
10710 <row rowsep="1">
10711 <entry>Column</entry>
10712 <entry>From</entry>
10713 <entry>Description</entry>
10714 </row>
10715 </thead>
10716
10717 <tbody>
10718 <row xml:id="Event_Bouts-FollowID" xreflabel="FollowID">
10719 <entry>FollowID</entry>
10720
10721 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10722 linkend="Followparts-FollowID"/></entry>
10723
10724 <entry>Identifier of the
10725 follow.</entry>
10726 </row>
10727
10728 <row xml:id="Event_Bouts-IntID" xreflabel="IntID">
10729 <entry>IntID</entry>
10730
10731 <entry><xref linkend="INTERVALS"/>.<xref
10732 linkend="Intervals-IntID"/></entry>
10733
10734 <entry>Identifier of the observation interval
10735 comprising one of the bout's minutes.</entry>
10736 </row>
10737
10738 <row xml:id="Event_Bouts-Function" xreflabel="Function">
10739 <entry>Function (Function in Follow of Focal)</entry>
10740
10741 <entry><xref linkend="FOLLOWROLES"/>.<xref
10742 linkend="Followroles-Function"/></entry>
10743
10744 <entry>Code indicating the biological role the focal
10745 plays in the follow: Mother, Infant, or
10746 Sibling.</entry>
10747 </row>
10748
10749 <row xml:id="Event_Bouts-AnimID" xreflabel="AnimID">
10750 <entry>AnimID</entry>
10751
10752 <entry><xref linkend="CHIMPIDS"/>.<xref
10753 linkend="ChimpIDs-AnimID"/></entry>
10754
10755 <entry>Canonical identifier of the focal, the
10756 <xref linkend="BIOGRAPHY_DATA"/>.<xref
10757 linkend="Biography_Data-AnimID"/>
10758 value. This can differ from the
10759 <xref linkend="ChimpIDs-ChimpID"/> in the case of
10760 twins or other circumstances where individuals have multiple
10761 identifiers.</entry>
10762 </row>
10763
10764 <row xml:id="Event_Bouts-Role" xreflabel="Role">
10765 <entry>Role (Role in Follow of Focal)</entry>
10766
10767 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10768 linkend="Followparts-Role"/></entry>
10769
10770 <entry>Code indicating the family role the focal plays
10771 in the follow. This can differ from the
10772 <xref linkend="Event_Bouts-Function"/> in the case of
10773 twins.</entry>
10774 </row>
10775
10776 <row xml:id="Event_Bouts-ChimpID" xreflabel="ChimpID">
10777 <entry>ChimpID</entry>
10778
10779 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10780 linkend="Followparts-ChimpID"/></entry>
10781
10782 <entry>Identifier of the focal as recorded in the
10783 <xref linkend="FOLLOWROLES"/> row for the follow. This
10784 can differ from the focal's
10785 <xref linkend="Biography_Data-AnimID"/> in the case of
10786 twins or other circumstances where individuals have
10787 multiple identifiers. In such cases this may also
10788 differ from the <xref linkend="ChimpIDs-ChimpID"/>
10789 stored in the
10790 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
10791 rows which designate the focal as being involved in a
10792 behavioral event.</entry>
10793 </row>
10794
10795 <row xml:id="Event_Bouts-Bout" xreflabel="Bout">
10796 <entry>Bout</entry>
10797
10798 <entry>Computed</entry>
10799
10800 <entry>Integer indicating the bout number. Bout
10801 numbers start with 1 and are per follow, per focal, per
10802 behavior code.</entry>
10803 </row>
10804
10805 <row xml:id="Event_Bouts-Behavior" xreflabel="Behavior">
10806 <entry>Behavior</entry>
10807
10808 <entry><xref linkend="EVENTS"/>.<xref
10809 linkend="Events-Behavior"/></entry>
10810
10811 <entry>Code indicating the behavior in which the focal
10812 is involved.</entry>
10813 </row>
10814
10815 <row xml:id="Event_Bouts-Uncertain" xreflabel="Uncertain">
10816 <entry>Uncertain</entry>
10817
10818 <entry><xref linkend="EVENTS"/>.<xref
10819 linkend="Events-Uncertain"/></entry>
10820
10821 <entry>&true; if all of the (non-baboon related)
10822 behavioral events in which the focal is involved during
10823 the given minute for the given behavior are uncertain,
10824 &false; otherwise.</entry>
10825 </row>
10826
10827 <row xml:id="Event_Bouts-Time" xreflabel="Time">
10828 <entry>Time</entry>
10829
10830 <entry><xref linkend="INTERVALS"/>.<xref
10831 linkend="Intervals-Time"/></entry>
10832
10833 <entry>The time of the observation.</entry>
10834 </row>
10835
10836 <row xml:id="Event_Bouts-Mins_In" xreflabel="Mins_In">
10837 <entry>Mins_In (Minutes Into the bout)</entry>
10838
10839 <entry>Computed</entry>
10840
10841 <entry>Number of minutes into the current bout,
10842 including the current minute.<footnote>
10843
10844 <para>Therefore, the first minute of the bout has a
10845 <xref linkend="Event_Bouts-Mins_In"/> value of 1,
10846 the next minute in the bout has a value of 2,
10847 etc.</para>
10848
10849 </footnote>
10850 </entry>
10851 </row>
10852
10853 <row xml:id="Event_Bouts-Mins_Out" xreflabel="Mins_Out">
10854 <entry>Mins_Out (Minutes remaining in the bout)</entry>
10855
10856 <entry>Computed</entry>
10857
10858 <entry>Number of minutes remaining in the current bout,
10859 excluding the current minute.<footnote>
10860
10861 <para>Therefore, the last minute of the bout has a
10862 <xref linkend="Event_Bouts-Mins_Out"/> value of 0,
10863 the prior minute in the bout has a value of 1,
10864 etc.</para>
10865
10866 </footnote>
10867 </entry>
10868 </row>
10869
10870 <row xml:id="Event_Bouts-Prior_Gap" xreflabel="Prior_Gap">
10871 <entry>Prior_Gap (Minutes between the current and Prior
10872 bout)</entry>
10873
10874 <entry>Computed</entry>
10875
10876 <entry>The number of minutes between the current bout
10877 and the previous bout (of the same follow, focal,
10878 behavior). &null; if there is no prior bout.</entry>
10879 </row>
10880
10881 <row xml:id="Event_Bouts-Gap_NoObs" xreflabel="Gap_NoObs">
10882 <entry>Gap_NoObs (Minutes without Observation of the
10883 focal between the current and prior bout)</entry>
10884
10885 <entry>Computed</entry>
10886
10887 <entry>The number of minutes between the current bout
10888 and the previous bout (of the same follow, focal,
10889 behavior) during which there is no behavioral data what
10890 so ever on the focal. &null; if there is no prior
10891 bout.</entry>
10892 </row>
10893
10894 <row xml:id="Event_Bouts-Left_Censored"
10895 xreflabel="Left_Censored">
10896 <entry>Left_Censored</entry>
10897
10898 <entry>Computed.</entry>
10899
10900 <entry>&true; when the bout is left censored, &false;
10901 otherwise. See above for more information regards
10902 censoring.</entry>
10903 </row>
10904
10905 <row xml:id="Event_Bouts-Right_Censored"
10906 xreflabel="Right_Censored">
10907 <entry>Right_Censored</entry>
10908
10909 <entry>Computed.</entry>
10910
10911 <entry>&true; when the bout is right censored, &false;
10912 otherwise. See above for more information regards
10913 censoring.</entry>
10914 </row>
10915
10916 <row xml:id="Event_Bouts-Day_Start" xreflabel="Day_Start">
10917 <entry>Day_Start (Bout is censored due to Start of
10918 Day)</entry>
10919
10920 <entry>Computed</entry>
10921
10922 <entry>&true; when the bout is censored because it
10923 occurs at the beginning of the day's observation of the
10924 follow, &false; otherwise.</entry>
10925 </row>
10926
10927 <row xml:id="Event_Bouts-Day_End" xreflabel="Day_End">
10928 <entry>Day_End (Bout is censored due to End of
10929 Day)</entry>
10930
10931 <entry>Computed</entry>
10932
10933 <entry>&true; when the bout is censored because it
10934 occurs at the end of the day's observation of the
10935 follow, &false; otherwise.</entry>
10936 </row>
10937
10938 </tbody>
10939 </tgroup>
10940 </informaltable>
10941
10942 </section>
10943
10944
10945 <section xml:id="EVENT_BOUTS-Usage-Guidelines">
10946 <title>EVENT_BOUTS Usage Guidelines</title>
10947
10948 <para>Only <literal>SELECT</literal> is allowed on
10949 EVENT_BOUTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
10950 and <literal>DELETE</literal> are not allowed.</para>
10951 </section>
10952 </section>
10953
10954 <section xml:id="EVENT_BOUT_AGGS" xreflabel="EVENT_BOUT_AGGS">
10955 <title>EVENT_BOUT_AGGS (Analysis of the focals' Behavioral
10956 Bouts, per Bout)</title>
10957
10958 <para>EVENT_BOUT_AGGS contains one row per
10959 <xref linkend="FOLLOWPARTS"/> row per
10960 <xref linkend="EVENTS"/>.<xref linkend="Events-Behavior"/> value
10961 having a related <xref linkend="PARTS"/> row that shows the
10962 given focal involved in the given behavior -- one row per
10963 follow, per focal in which the focal is involved in a behavior
10964 (excluding behavioral events which involve a baboon), per code
10965 for the behavior involved in. Each row represents an entire
10966 event bout.</para>
10967
10968 <para>See <xref linkend="EVENT_BOUTS"/> for more information on
10969 event bout analysis.</para>
10970
10971 <section xml:id="EVENT_BOUT_AGGS-Definition">
10972 <title>EVENT_BOUT_AGGS Definition</title>
10973
10974 <xi:include
10975 href="views/event_bout_aggs.xml"
10976 xmlns:xi="http://www.w3.org/2001/XInclude"/>
10977 </section>
10978
10979 <section xml:id="Event_Bout_Aggs-Columns">
10980 <title>EVENT_BOUT_AGGS Columns</title>
10981
10982 <informaltable frame="topbot">
10983 <tgroup cols="3" colsep="0" rowsep="0">
10984 <colspec colnum="3" rowsep="1"/>
10985 <thead>
10986 <row rowsep="1">
10987 <entry>Column</entry>
10988 <entry>From</entry>
10989 <entry>Description</entry>
10990 </row>
10991 </thead>
10992
10993 <tbody>
10994 <row xml:id="Event_Bout_Aggs-FollowID" xreflabel="FollowID">
10995 <entry>FollowID</entry>
10996
10997 <entry><xref linkend="FOLLOWPARTS"/>.<xref
10998 linkend="Followparts-FollowID"/></entry>
10999
11000 <entry>Identifier of the
11001 follow.</entry>
11002 </row>
11003
11004 <row xml:id="Event_Bout_Aggs-Function" xreflabel="Function">
11005 <entry>Function (Function in Follow of Focal)</entry>
11006
11007 <entry><xref linkend="FOLLOWROLES"/>.<xref
11008 linkend="Followroles-Function"/></entry>
11009
11010 <entry>Code indicating the biological role the focal
11011 plays in the follow: Mother, Infant, or
11012 Sibling.</entry>
11013 </row>
11014
11015 <row xml:id="Event_Bout_Aggs-AnimID" xreflabel="AnimID">
11016 <entry>AnimID</entry>
11017
11018 <entry><xref linkend="CHIMPIDS"/>.<xref
11019 linkend="ChimpIDs-AnimID"/></entry>
11020
11021 <entry>Canonical identifier of the focal, the
11022 <xref linkend="BIOGRAPHY_DATA"/>.<xref
11023 linkend="Biography_Data-AnimID"/>
11024 value. This can differ from the
11025 <xref linkend="ChimpIDs-ChimpID"/> in the case of
11026 twins or other circumstances where individuals have multiple
11027 identifiers.</entry>
11028 </row>
11029
11030 <row xml:id="Event_Bout_Aggs-Role" xreflabel="Role">
11031 <entry>Role (Role in Follow of Focal)</entry>
11032
11033 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11034 linkend="Followparts-Role"/></entry>
11035
11036 <entry>Code indicating the family role the focal plays
11037 in the follow. This can differ from the
11038 <xref linkend="Event_Bout_Aggs-Function"/> in the case of
11039 twins.</entry>
11040 </row>
11041
11042 <row xml:id="Event_Bout_Aggs-ChimpID" xreflabel="ChimpID">
11043 <entry>ChimpID</entry>
11044
11045 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11046 linkend="Followparts-ChimpID"/></entry>
11047
11048 <entry>Identifier of the focal as recorded in the
11049 <xref linkend="FOLLOWROLES"/> row for the follow. This
11050 can differ from the focal's
11051 <xref linkend="Biography_Data-AnimID"/> in the case of
11052 twins or other circumstances where individuals have
11053 multiple identifiers. In such cases this may also
11054 differ from the <xref linkend="ChimpIDs-ChimpID"/>
11055 stored in the
11056 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
11057 rows which designate the focal as being involved in a
11058 behavioral event.</entry>
11059 </row>
11060
11061 <row xml:id="Event_Bout_Aggs-Bout" xreflabel="Bout">
11062 <entry>Bout</entry>
11063
11064 <entry>Computed</entry>
11065
11066 <entry>Integer indicating the bout number. Bout
11067 numbers start with 1 and are per follow, per focal, per
11068 behavior code.</entry>
11069 </row>
11070
11071 <row xml:id="Event_Bout_Aggs-Behavior" xreflabel="Behavior">
11072 <entry>Behavior</entry>
11073
11074 <entry><xref linkend="EVENTS"/>.<xref
11075 linkend="Events-Behavior"/></entry>
11076
11077 <entry>Code indicating the behavior in which the focal
11078 is involved.</entry>
11079 </row>
11080
11081 <row xml:id="Event_Bout_Aggs-Uncertain" xreflabel="Uncertain">
11082 <entry>Uncertain</entry>
11083
11084 <entry><xref linkend="EVENTS"/>.<xref
11085 linkend="Events-Uncertain"/></entry>
11086
11087 <entry>&true; if any of the underlying
11088 <xref linkend="EVENT_BOUTS"/> rows which comprise the
11089 bout are uncertain, &false; otherwise.</entry>
11090 </row>
11091
11092 <row xml:id="Event_Bout_Aggs-Start_Time" xreflabel="Start_Time">
11093 <entry>Start_Time</entry>
11094
11095 <entry><xref linkend="INTERVALS"/>.<xref
11096 linkend="Intervals-Time"/></entry>
11097
11098 <entry>The time the event bout started. The time of
11099 the first observation of the bout.</entry>
11100 </row>
11101
11102 <row xml:id="Event_Bout_Aggs-Stop_Time" xreflabel="Stop_time">
11103 <entry>Stop_Time</entry>
11104
11105 <entry><xref linkend="INTERVALS"/>.<xref
11106 linkend="Intervals-Time"/></entry>
11107
11108 <entry>The time the event bout stopped. The time of
11109 the last observation of the bout.</entry>
11110 </row>
11111
11112 <row xml:id="Event_Bout_Aggs-Prior_Gap" xreflabel="Prior_Gap">
11113 <entry>Prior_Gap (Minutes between the current and Prior
11114 bout)</entry>
11115
11116 <entry>Computed</entry>
11117
11118 <entry>The number of minutes between the current bout
11119 and the previous bout (of the same follow, focal,
11120 behavior). &null; if there is no prior bout.</entry>
11121 </row>
11122
11123 <row xml:id="Event_Bout_Aggs-Gap_NoObs" xreflabel="Gap_NoObs">
11124 <entry>Gap_NoObs (Minutes without Observation of the
11125 focal between the current and prior bout)</entry>
11126
11127 <entry>Computed</entry>
11128
11129 <entry>The number of minutes between the current bout
11130 and the previous bout (of the same follow, focal,
11131 behavior) during which there is no behavioral data what
11132 so ever on the focal. &null; if there is no prior
11133 bout.</entry>
11134 </row>
11135
11136 <row xml:id="Event_Bout_Aggs-Left_Censored"
11137 xreflabel="Left_Censored">
11138 <entry>Left_Censored</entry>
11139
11140 <entry>Computed.</entry>
11141
11142 <entry>&true; when the bout is left censored, &false;
11143 otherwise. See above for more information regards
11144 censoring.</entry>
11145 </row>
11146
11147 <row xml:id="Event_Bout_Aggs-Right_Censored"
11148 xreflabel="Right_Censored">
11149 <entry>Right_Censored</entry>
11150
11151 <entry>Computed.</entry>
11152
11153 <entry>&true; when the bout is right censored, &false;
11154 otherwise. See above for more information regards
11155 censoring.</entry>
11156 </row>
11157
11158 <row xml:id="Event_Bout_Aggs-Day_Start" xreflabel="Day_Start">
11159 <entry>Day_Start (Bout is censored due to Start of
11160 Day)</entry>
11161
11162 <entry>Computed</entry>
11163
11164 <entry>&true; when the bout is censored because it
11165 occurs at the beginning of the day's observation of the
11166 follow, &false; otherwise.</entry>
11167 </row>
11168
11169 <row xml:id="Event_Bout_Aggs-Day_End" xreflabel="Day_End">
11170 <entry>Day_End (Bout is censored due to End of
11171 Day)</entry>
11172
11173 <entry>Computed</entry>
11174
11175 <entry>&true; when the bout is censored because it
11176 occurs at the end of the day's observation of the
11177 follow, &false; otherwise.</entry>
11178 </row>
11179
11180 </tbody>
11181 </tgroup>
11182 </informaltable>
11183
11184 </section>
11185
11186
11187 <section xml:id="EVENT_BOUT_AGGS-Usage-Guidelines">
11188 <title>EVENT_BOUT_AGGS Usage Guidelines</title>
11189
11190 <para>Only <literal>SELECT</literal> is allowed on
11191 EVENT_BOUT_AGGS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
11192 and <literal>DELETE</literal> are not allowed.</para>
11193 </section>
11194 </section>
11195
11196 <section xml:id="FAMILY_EVENTS" xreflabel="FAMILY_EVENTS">
11197 <title>FAMILY_EVENTS (Behavioral Events With the Focals
11198 Identified by Column)</title>
11199
11200 <para>FAMILY_EVENTS contains one row per
11201 <xref linkend="EVENTS"/> row. FAMILY_EVENTS provides a way to
11202 review recorded behaviors in a way similar to the way data is
11203 recorded in the field. It is also useful for changing database
11204 content, since this is often done based on data recorded in the
11205 field.</para>
11206
11207 <note>
11208 <para>The FAMILY_EVENTS view is neither particularly efficient
11209 nor particularly well suited to data analysis. Other views will
11210 very likely be much faster and more appropriate when analyzing
11211 data.</para>
11212 </note>
11213
11214 <note>
11215 <para>The FAMILY_EVENTS view is limited in that it will not
11216 change database content in the tables which extend the
11217 <xref linkend="EVENTS"/> table, tables such as
11218 <xref linkend="VOCS"/>, <xref linkend="EATS"/>, and the like.
11219 For this the <xref linkend="DATASHEETS"/> view must be
11220 used.</para>
11221 </note>
11222
11223 <section xml:id="FAMILY_EVENTS-Definition">
11224 <title>FAMILY_EVENTS Definition</title>
11225
11226 <xi:include
11227 href="views/family_events.xml"
11228 xmlns:xi="http://www.w3.org/2001/XInclude"/>
11229 </section>
11230
11231 <section xml:id="Family_Events-Columns">
11232 <title>FAMILY_EVENTS Columns</title>
11233
11234 <informaltable frame="topbot">
11235 <tgroup cols="3" colsep="0" rowsep="0">
11236 <colspec colnum="3" rowsep="1"/>
11237 <thead>
11238 <row rowsep="1">
11239 <entry>Column</entry>
11240 <entry>From</entry>
11241 <entry>Description</entry>
11242 </row>
11243 </thead>
11244
11245 <tbody>
11246 <row xml:id="Family_Events-FollowID" xreflabel="FollowID">
11247 <entry>FollowID</entry>
11248
11249 <entry><xref linkend="FOLLOWS"/>.<xref
11250 linkend="Follows-FollowID"/></entry>
11251
11252 <entry>Identifier of the follow.</entry>
11253 </row>
11254
11255 <row xml:id="Family_Events-IntID" xreflabel="IntID">
11256 <entry>IntID</entry>
11257
11258 <entry><xref linkend="EVENTS"/>.<xref
11259 linkend="Events-IntID"/></entry>
11260
11261 <entry>Identifier of the observation interval during
11262 which the event was recorded.</entry>
11263 </row>
11264
11265 <row xml:id="Family_Events-EID" xreflabel="EID">
11266 <entry>EID</entry>
11267
11268 <entry><xref linkend="EVENTS"/>.<xref
11269 linkend="Events-EID"/></entry>
11270
11271 <entry>Identifier of the
11272 behavioral event row.</entry>
11273 </row>
11274
11275 <row xml:id="Family_Events-E_MomPID" xreflabel="E_MomPID">
11276 <entry>MomPID (Event Mom PID)</entry>
11277
11278 <entry><xref linkend="PARTS"/>.<xref
11279 linkend="Parts-PID"/></entry>
11280
11281 <entry>Identifier of the behavioral participant row
11282 which records behavioral data regarding the mother in
11283 the follow, or &null; when the mother is not a
11284 participant in the behavior.</entry>
11285 </row>
11286
11287 <row xml:id="Family_Events-E_InfantPID" xreflabel="E_InfantPID">
11288 <entry>E_InfantPID (Event Infant PID)</entry>
11289
11290 <entry><xref linkend="PARTS"/>.<xref
11291 linkend="Parts-PID"/></entry>
11292
11293 <entry>Identifier of the behavioral participant row
11294 which records behavioral data regarding the infant in
11295 the follow, or &null; when the infant is not a
11296 participant in the behavior.</entry>
11297 </row>
11298
11299 <row xml:id="Family_Events-E_SibPID" xreflabel="E_SibPID">
11300 <entry>E_SibPID (Event Sib PID)</entry>
11301
11302 <entry><xref linkend="PARTS"/>.<xref
11303 linkend="Parts-PID"/></entry>
11304
11305 <entry>Identifier of the behavioral participant row
11306 which records behavioral data regarding the sibling in
11307 the follow, or &null; when the sibling is not a
11308 participant in the behavior.</entry>
11309 </row>
11310
11311 <row xml:id="Family_Events-E_NonfocalPID"
11312 xreflabel="E_NonfocalPID">
11313 <entry>E_NonfocalPID (Event Non-Focal PID)</entry>
11314
11315 <entry><xref linkend="PARTS"/>.<xref
11316 linkend="Parts-PID"/></entry>
11317
11318 <entry>
11319 <para>Identifier of the behavioral participant row
11320 which records behavioral data regarding any nonfocal
11321 individual involved in the behavior, or &null; when
11322 only focals are participants in the behavior.</para>
11323 </entry>
11324 </row>
11325
11326 <row xml:id="Family_Events-Date" xreflabel="Date">
11327 <entry>Date</entry>
11328
11329 <entry><xref linkend="FOLLOWS"/>.<xref
11330 linkend="Follows-Date"/></entry>
11331
11332 <entry>The date of the follow.</entry>
11333 </row>
11334
11335 <row xml:id="Family_Events-Time" xreflabel="Time">
11336 <entry>Time</entry>
11337
11338 <entry><xref linkend="INTERVALS"/>.<xref
11339 linkend="Intervals-Time"/></entry>
11340
11341 <entry>The time of the interval.</entry>
11342 </row>
11343
11344 <row xml:id="Family_Events-Mom" xreflabel="Mom">
11345 <entry>Mom</entry>
11346
11347 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11348 linkend="Followparts-ChimpID"/></entry>
11349
11350 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of the
11351 mother in the follow.</entry>
11352 </row>
11353
11354 <row xml:id="Family_Events-Infant" xreflabel="Infant">
11355 <entry>Infant</entry>
11356
11357 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11358 linkend="Followparts-ChimpID"/></entry>
11359
11360 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of an
11361 infant in the follow.</entry>
11362 </row>
11363
11364 <row xml:id="Family_Events-Infant2" xreflabel="Infant2">
11365 <entry>Infant2</entry>
11366
11367 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11368 linkend="Followparts-ChimpID"/></entry>
11369
11370 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
11371 second infant in the follow, or &null; if the infant
11372 is not a twin.</entry>
11373 </row>
11374
11375 <row xml:id="Family_Events-Sib" xreflabel="Sib">
11376 <entry>Sib</entry>
11377
11378 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11379 linkend="Followparts-ChimpID"/></entry>
11380
11381 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
11382 sibling in the follow, or &null; if there is no
11383 sibling focal.</entry>
11384 </row>
11385
11386 <row xml:id="Family_Events-Sib2" xreflabel="Sib2">
11387 <entry>Sib2</entry>
11388
11389 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11390 linkend="Followparts-ChimpID"/></entry>
11391
11392 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
11393 second sibling in the follow, or &null; if the sibling
11394 is not a twin.</entry>
11395 </row>
11396
11397 <row xml:id="Family_Events-Behavior" xreflabel="Behavior">
11398 <entry>Behavior</entry>
11399
11400 <entry><xref linkend="EVENTS"/>.<xref
11401 linkend="Events-Behavior"/></entry>
11402
11403 <entry>Code indicating the behavior observed.</entry>
11404 </row>
11405
11406 <row xml:id="Family_Events-Position" xreflabel="Position">
11407 <entry>Position</entry>
11408
11409 <entry><xref linkend="EVENTS"/>.<xref
11410 linkend="Events-Position"/></entry>
11411
11412 <entry>Position within the canopy where the event
11413 occurred.</entry>
11414 </row>
11415
11416 <row xml:id="Family_Events-Uncertain" xreflabel="Uncertain">
11417 <entry>Uncertain</entry>
11418
11419 <entry><xref linkend="EVENTS"/>.<xref
11420 linkend="Events-Uncertain"/></entry>
11421
11422 <entry>Whether or not the behavior was observed with
11423 certainty.</entry>
11424 </row>
11425
11426 <row xml:id="Family_Events-E_Mom" xreflabel="E_Mom">
11427 <entry>E_Mom (Event Mom)</entry>
11428
11429 <entry><xref linkend="PARTS"/>.<xref
11430 linkend="Parts-Participant"/></entry>
11431
11432 <entry>The identifier or alternate identifier of the mom,
11433 or &null; if the mother is not a participant in the
11434 behavior.</entry>
11435 </row>
11436
11437 <row xml:id="Family_Events-E_MomPart" xreflabel="E_MomPart">
11438 <entry>E_MomPart (Event Mom Participant code)</entry>
11439
11440 <entry><xref linkend="PARTS"/>.<xref
11441 linkend="Parts-Part"/></entry>
11442
11443 <entry>The role the mom plays in the behavior, or
11444 &null; if the mother is not a participant in the
11445 behavior.</entry>
11446 </row>
11447
11448 <row xml:id="Family_Events-E_Infant" xreflabel="E_Infant">
11449 <entry>E_Infant (Event Infant)</entry>
11450
11451 <entry><xref linkend="PARTS"/>.<xref
11452 linkend="Parts-Participant"/></entry>
11453
11454 <entry>The identifier or alternate identifier of the
11455 infant, or &null; when the infant is not a participant
11456 in the behavior.</entry>
11457 </row>
11458
11459 <row xml:id="Family_Events-E_InfantPart" xreflabel="E_InfantPart">
11460 <entry>E_InfantPart (Event Infant Participant code)</entry>
11461
11462 <entry><xref linkend="PARTS"/>.<xref
11463 linkend="Parts-Part"/></entry>
11464
11465 <entry>The role the infant plays in the behavior, or
11466 &null; when the infant is not a participant in the
11467 behavior.</entry>
11468 </row>
11469
11470 <row xml:id="Family_Events-E_Sib" xreflabel="E_Sib">
11471 <entry>E_Sib (Events Sibling)</entry>
11472
11473 <entry><xref linkend="PARTS"/>.<xref
11474 linkend="Parts-Participant"/></entry>
11475
11476 <entry>The identifier or alternate identifier of the
11477 sibling, or &null; when the sibling is not a
11478 participant in the behavior.</entry>
11479 </row>
11480
11481 <row xml:id="Family_Events-E_SibPart" xreflabel="E_SibPart">
11482 <entry>E_SibPart (Event Sibling Participant code)</entry>
11483
11484 <entry><xref linkend="PARTS"/>.<xref
11485 linkend="Parts-Part"/></entry>
11486
11487 <entry>The role the sibling plays in the behavior, or
11488 &null; when the sibling is not a participant in the
11489 behavior.</entry>
11490 </row>
11491
11492 <row xml:id="Family_Events-E_Nonfocal" xreflabel="E_Nonfocal">
11493 <entry>E_Nonfocal</entry>
11494
11495 <entry><xref linkend="PARTS"/>.<xref
11496 linkend="Parts-Participant"/></entry>
11497
11498 <entry>
11499 <para>The identifier or alternate identifier of any
11500 nonfocal individual involved in the behavior, or
11501 &null; when only focals participate in the behavior.</para>
11502 </entry>
11503 </row>
11504
11505 <row xml:id="Family_Events-E_NonfocalPart"
11506 xreflabel="E_NonfocalPart">
11507 <entry>E_NonfocalPart (Event Non-Focal Participant code)</entry>
11508
11509 <entry><xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
11510 </entry>
11511
11512 <entry>
11513 <para>The role a nonfocal individual plays in the
11514 behavior, or &null; when only focals participate in
11515 the behavior.</para>
11516 </entry>
11517 </row>
11518
11519 <row xml:id="Family_Events-E_Baboon" xreflabel="E_Baboon">
11520 <entry>E_Baboon (Event Baboon)</entry>
11521
11522 <entry><xref linkend="EVENTS"/>.<xref
11523 linkend="Events-Baboon"/></entry>
11524
11525 <entry>Whether or not a baboon is the second participant
11526 in the behavioral interaction.</entry>
11527 </row>
11528
11529 <row xml:id="Family_Events-E_BaboonPart"
11530 xreflabel="E_BaboonPart">
11531 <entry>E_BaboonPart (Event Baboon Participant code)</entry>
11532
11533 <entry>A simulated
11534 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
11535 value</entry>
11536
11537 <entry>
11538 <para>The role the baboon plays in the behavior, or
11539 &null; when a baboon is not a participant in the
11540 behavior. This value is computed from the
11541 <xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
11542 value of the chimpanzee participant.</para>
11543 </entry>
11544 </row>
11545
11546 <row xml:id="Family_Events-E_Comment" xreflabel="E_Comment">
11547 <entry>E_Comment (Event Comment)</entry>
11548
11549 <entry><xref linkend="EVENTS"/>.<xref
11550 linkend="Events-Comment"/></entry>
11551
11552 <entry>Textual remarks regarding the behavioral
11553 event.</entry>
11554 </row>
11555
11556 <row xml:id="Family_Events-I_Comment" xreflabel="I_Comment">
11557 <entry>I_Comment (Interval Comment)</entry>
11558
11559 <entry><xref linkend="INTERVALS"/>.<xref
11560 linkend="Intervals-Comment"/></entry>
11561
11562 <entry>Textual remarks regarding the interval.</entry>
11563 </row>
11564
11565 </tbody>
11566 </tgroup>
11567 </informaltable>
11568
11569 </section>
11570
11571
11572 <section xml:id="FAMILY_EVENTS-Usage-Guidelines">
11573 <title>FAMILY_EVENTS Usage Guidelines</title>
11574
11575 <para>Altering the FAMILY_EVENTS view alters the content of
11576 the underlying <xref linkend="EVENTS"/> and
11577 <xref linkend="PARTS"/> tables in the fashion described below.
11578 The <xref linkend="INTERVALS"/> and related
11579 <xref linkend="FOLLOWS"/> and <xref linkend="FOLLOWPARTS"/>
11580 rows must exist; the content of these tables is never
11581 altered.</para>
11582
11583 <section xml:id="Family_Events-Insert">
11584 <title>INSERT</title>
11585
11586 <para>Inserting a row into the FAMILY_EVENTS view inserts
11587 a row into the <xref linkend="EVENTS"/> table, as
11588 expected.</para>
11589
11590 <para>When inserting into FAMILY_EVENTS the interval of the
11591 follow must be specified. The interval may be specified in
11592 either or both of the following 2 ways:</para>
11593
11594 <itemizedlist>
11595 <listitem>
11596 <para>A <xref linkend="Family_Events-IntID"/> may be
11597 supplied.</para>
11598 </listitem>
11599
11600 <listitem>
11601 <para>A <xref linkend="Family_Events-Time"/> may be
11602 supplied and the follow specified. The follow may be
11603 specified in either or both of the following 2
11604 ways:</para>
11605
11606 <itemizedlist>
11607 <listitem>
11608 <para>A <xref linkend="Family_Events-FollowID"/> may be
11609 supplied.</para>
11610 </listitem>
11611
11612 <listitem>
11613 <para><xref linkend="Family_Events-Date"/>,
11614 <xref linkend="Family_Events-Mom"/> and,
11615 <xref linkend="Family_Events-Infant"/>
11616 values <emphasis>all</emphasis> may be supplied.</para>
11617
11618 <note>
11619 <para>See <link linkend="follow_intervals-twins">the
11620 note regards twins</link>
11621 when <link linkend="Follow_Intervals-Insert">inserting
11622 into FOLLOW_INTERVALS</link>.</para>
11623 </note>
11624 </listitem>
11625 </itemizedlist>
11626 </listitem>
11627 </itemizedlist>
11628
11629 <caution>
11630 <para>FAMILY_EVENTS inserts rows into the database only
11631 when there is a <xref linkend="INTERVALS"/> row that
11632 matches the above selection criteria. If no row matches
11633 the database content is not altered. Note that no row
11634 will match if conflicting information is supplied.</para>
11635 </caution>
11636
11637 <note>
11638 <para>When inserting into FAMILY_EVENTS it is not
11639 recommended to set any of the
11640 <xref linkend="Family_Events-EID"/>,
11641 <xref linkend="Family_Events-E_MomPID"/>,
11642 <xref linkend="Family_Events-E_InfantPID"/>,
11643 <xref linkend="Family_Events-E_SibPID"/>, or
11644 <xref linkend="Family_Events-E_NonfocalPID"/> values.
11645 Omitting these columns or supplying &null; values will
11646 allow the system to automatically generate ids.</para>
11647 </note>
11648
11649 <note>
11650 <para>When inserting into FAMILY_EVENTS the user-supplied
11651 value for <xref linkend="Family_Events-E_BaboonPart"/> is
11652 ignored.</para>
11653 </note>
11654 </section>
11655
11656 <section xml:id="Family_Events-Update">
11657 <title>Update</title>
11658
11659 <para>Updating the FAMILY_EVENTS view updates
11660 <xref linkend="EVENTS"/>, as expected.</para>
11661
11662 <para>Updating FAMILY_EVENTS can update, insert into, or
11663 delete rows from <xref linkend="PARTS"/>.</para>
11664
11665 <note>
11666 <para>The examples below explicitly specify an
11667 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
11668 value. This is solely for the purpose of brevity. Any valid
11669 <code>WHERE</code> clause could be used instead to
11670 designate the desired row in
11671 <xref linkend="EVENTS"/>.</para>
11672 </note>
11673
11674 <para>If the old values for a mom, infant, sib or nonfocal
11675 <xref linkend="PARTS"/> row are not &null; and the new
11676 values are all &null; then the old row is deleted. The
11677 following example removes the mother as a participant in the
11678 event with an
11679 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
11680 of <literal>1234</literal>:</para>
11681
11682 <example>
11683 <title>Deleting The Mother's PARTS Row</title>
11684
11685 <literallayout>
11686 <code>UPDATE family_events
11687 SET e_mom = NULL
11688 , e_mompid = NULL
11689 , e_mompart = NULL
11690 WHERE eid = 1234;</code></literallayout>
11691 </example>
11692
11693 <para>If the old values for a mom, infant, sib, or nonfocal
11694 are &null;, i.e. if the mom, infant, sib, or nonfocal has no
11695 <xref linkend="PARTS"/> row then a new
11696 <xref linkend="PARTS"/> row can be inserted by supplying
11697 values. The following example adds, to the event with an
11698 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
11699 of <literal>1234</literal>, assuming she is not already one
11700 of the individuals involved in the event, the mother as an
11701 actor (<xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
11702 = '<literal>&gmi_actor;</literal>'):</para>
11703
11704 <example>
11705 <title>Inserting A PARTS Row For The Mother</title>
11706
11707 <literallayout>
11708 <code>UPDATE family_events
11709 SET e_mom = 'GA'
11710 , e_mompart = '&gmi_actor;'
11711 WHERE eid = 1234;</code></literallayout>
11712 </example>
11713
11714 <para>If old values exist, they are replaced by new values.
11715 Assuming the non-focal <literal>JOE</literal> is involved in
11716 the event with an
11717 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
11718 of <literal>1234</literal>, the following example changes
11719 the non-focal to <literal>JAK</literal>:</para>
11720
11721 <example>
11722 <title>Changing Non-Focal Participant In A PARTS Row</title>
11723
11724 <literallayout>
11725 <code>UPDATE family_events
11726 SET e_nonfocal = 'JAK'
11727 WHERE eid = 1234;</code></literallayout>
11728 </example>
11729
11730 <note>
11731 <para>The <xref linkend="ChimpIDs-ChimpID"/> values need
11732 not correspond to the roles the individuals play in the
11733 follow because data is associated with chimp id values,
11734 not focal roles. The presence of focal roles in the
11735 column names is, in some sense, artificial. For example,
11736 there are two ways to change the infant
11737 (<literal>INF</literal>) to a sibling
11738 (<literal>SB</literal>) in the event with an
11739 <xref linkend="EVENTS"/>.<xref linkend="Events-EID"/>
11740 of <literal>1234</literal>. The first is to delete the
11741 <xref linkend="PARTS"/> row for the infant and insert a
11742 new <xref linkend="PARTS"/> row for the sibling:</para>
11743
11744 <example>
11745 <title>Deleting the Infant's PARTS row and Inserting a New
11746 PARTS Row for the Sibling </title>
11747
11748 <literallayout>
11749 <code>UPDATE family_events
11750 SET e_infant = NULL
11751 , e_infantpid = NULL
11752 , e_infantpart = NULL
11753 , e_sib = 'SB'
11754 , e_sibpart = '&gmi_actor;'
11755 WHERE eid = 1234;</code></literallayout>
11756 </example>
11757
11758 <para>Deleting and re-adding rows is somewhat inefficient
11759 and error prone. It is probably better to simply replace
11760 the infant's <xref linkend="ChimpIDs-ChimpID"/> value with
11761 the siblings. Simply changing the
11762 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
11763 value is enough; being the sibling is a property of a
11764 ChimpID with respect to a follow and, again, when updating
11765 the database there is no correspondence between the column
11766 names and the roles played by the individual chimps. The
11767 following is sufficient to re-use the exiting
11768 <xref linkend="PARTS"/> row and change the infant's
11769 <xref linkend="ChimpIDs-ChimpID"/> value to the
11770 siblings:</para>
11771
11772 <example>
11773 <title>Changing an Infant's PARTS row Into A PARTS Row
11774 for the Sibling </title>
11775
11776 <literallayout>
11777 <code>UPDATE family_events
11778 SET e_infant = 'SB' -- SB is the sibling
11779 WHERE eid = 1234;</code></literallayout>
11780 </example>
11781
11782 <para>When the result is queried <literal>SB</literal>
11783 will show up as a sibling, not an infant.</para>
11784 </note>
11785
11786 <para>It is an error to attempt to update the values of any
11787 columns not derived from the <xref linkend="EVENTS"/> or
11788 <xref linkend="PARTS"/> tables. It is also an error to
11789 attempt to change the
11790 <xref linkend="Family_Events-E_BaboonPart"/> value.</para>
11791
11792 <para>When updated, FAMILY_EVENTS raises a notice containing
11793 the number of rows altered. A row is counted only once,
11794 when updating the row changes the database content in any
11795 way.</para>
11796 </section>
11797
11798 <section xml:id="Family_Events-Delete">
11799 <title>Delete</title>
11800
11801 <para>Deleting rows from the FAMILY_EVENTS view deletes rows
11802 from <xref linkend="EVENTS"/> and <xref linkend="PARTS"/>,
11803 as expected. Because deleting a row from
11804 <xref linkend="EVENTS"/> also deletes related rows from the
11805 tables which extend the <xref linkend="EVENTS"/> table,
11806 tables such as <xref linkend="VOCS"/>,
11807 <xref linkend="EATS"/>, and the like, this is a convenient
11808 way to delete behavioral events.</para>
11809 </section>
11810 </section>
11811 </section>
11812
11813 <section xml:id="FOCAL_EVENTS" xreflabel="FOCAL_EVENTS">
11814 <title>FOCAL_EVENTS (All Behavioral Events With the Focals
11815 Distinguished)</title>
11816
11817 <para>FOCAL_EVENTS contains one row per <xref linkend="EVENTS"/>
11818 row per focal individual involved in the behavioral event.
11819 FOCAL_EVENTS provides a direct way to analyze behaviors when
11820 interested in the role (mom, infant, sib, non-focal) of the
11821 individuals involved in the behavior.</para>
11822
11823 <caution>
11824 <para>FOCAL_EVENTS has 1 or 2 rows per behavioral event -- per
11825 <xref linkend="EVENTS"/> row -- depending on whether the the
11826 behavioral interaction is social and how many of the individuals
11827 involved are focals in the follow.</para>
11828 </caution>
11829
11830 <caution>
11831 <para>FOCAL_EVENTS includes rows for behavioral interactions
11832 with baboons.</para>
11833 </caution>
11834
11835 <section xml:id="FOCAL_EVENTS-Definition">
11836 <title>FOCAL_EVENTS Definition</title>
11837
11838 <xi:include
11839 href="views/focal_events.xml"
11840 xmlns:xi="http://www.w3.org/2001/XInclude"/>
11841 </section>
11842
11843 <section xml:id="Focal_Events-Columns">
11844 <title>FOCAL_EVENTS Columns</title>
11845
11846 <informaltable frame="topbot">
11847 <tgroup cols="3" colsep="0" rowsep="0">
11848 <colspec colnum="3" rowsep="1"/>
11849 <thead>
11850 <row rowsep="1">
11851 <entry>Column</entry>
11852 <entry>From</entry>
11853 <entry>Description</entry>
11854 </row>
11855 </thead>
11856
11857 <tbody>
11858 <row xml:id="Focal_Events-EID" xreflabel="EID">
11859 <entry>EID</entry>
11860
11861 <entry><xref linkend="EVENTS"/>.<xref
11862 linkend="Events-EID"/></entry>
11863
11864 <entry>Identifier of the
11865 behavioral event row.</entry>
11866 </row>
11867
11868 <row xml:id="Focal_Events-IntID" xreflabel="IntID">
11869 <entry>IntID</entry>
11870
11871 <entry><xref linkend="EVENTS"/>.<xref
11872 linkend="Events-IntID"/></entry>
11873
11874 <entry>Identifier of the observation interval during
11875 which the event was recorded.</entry>
11876 </row>
11877
11878 <row xml:id="Focal_Events-FocalPID" xreflabel="FocalPID">
11879 <entry>FocalPID</entry>
11880
11881 <entry><xref linkend="PARTS"/>.<xref
11882 linkend="Parts-PID"/></entry>
11883
11884 <entry>Identifier of the behavioral participant row
11885 which records behavioral data regarding one of the focals
11886 in the follow.</entry>
11887 </row>
11888
11889 <row xml:id="Focal_Events-OtherPID" xreflabel="OtherPID">
11890 <entry>OtherPID</entry>
11891
11892 <entry><xref linkend="PARTS"/>.<xref
11893 linkend="Parts-PID"/></entry>
11894
11895 <entry>
11896 <para>Identifier of the behavioral participant row
11897 which records behavioral data regarding the other
11898 individual (the individual involved in the behavior who
11899 is not designated as the focal in the row).</para>
11900
11901 <para>This value is &null; when a single chimpanzee is
11902 involved in the behavior.</para>
11903 </entry>
11904 </row>
11905
11906 <row xml:id="Focal_Events-Behavior" xreflabel="Behavior">
11907 <entry>Behavior</entry>
11908
11909 <entry><xref linkend="EVENTS"/>.<xref
11910 linkend="Events-Behavior"/></entry>
11911
11912 <entry>Code indicating the behavior observed.</entry>
11913 </row>
11914
11915 <row xml:id="Focal_Events-Position" xreflabel="Position">
11916 <entry>Position</entry>
11917
11918 <entry><xref linkend="EVENTS"/>.<xref
11919 linkend="Events-Position"/></entry>
11920
11921 <entry>Position within the canopy where the event
11922 occurred.</entry>
11923 </row>
11924
11925 <row xml:id="Focal_Events-Uncertain" xreflabel="Uncertain">
11926 <entry>Uncertain</entry>
11927
11928 <entry><xref linkend="EVENTS"/>.<xref
11929 linkend="Events-Uncertain"/></entry>
11930
11931 <entry>Whether or not the behavior was observed with
11932 certainty.</entry>
11933 </row>
11934
11935 <row xml:id="Focal_Events-FocalRole" xreflabel="FocalRole">
11936 <entry>FocalRole (Role in Follow of Focal Chimp)</entry>
11937
11938 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11939 linkend="Followparts-Role"/></entry>
11940
11941 <entry>Code for the role, i.e. mom, sib,
11942 infant, played by the individual designated as focal in
11943 the behavioral event.</entry>
11944 </row>
11945
11946 <row xml:id="Focal_Events-Focal" xreflabel="Focal">
11947 <entry>Focal</entry>
11948
11949 <entry><xref linkend="PARTS"/>.<xref
11950 linkend="Parts-Participant"/></entry>
11951
11952 <entry>The identifier or alternate identifier of the
11953 focal.</entry>
11954 </row>
11955
11956 <row xml:id="Focal_Events-FocalPart" xreflabel="FocalPart">
11957 <entry>FocalPart</entry>
11958
11959 <entry><xref linkend="PARTS"/>.<xref
11960 linkend="Parts-Part"/></entry>
11961
11962 <entry>The role the focal plays in the behavior.</entry>
11963 </row>
11964
11965 <row xml:id="Focal_Events-OtherRole" xreflabel="OtherRole">
11966 <entry>OtherRole (Role in Follow of Other Chimp)</entry>
11967
11968 <entry><xref linkend="FOLLOWPARTS"/>.<xref
11969 linkend="Followparts-Role"/> or computed in the case
11970 of interaction with a baboon</entry>
11971
11972 <entry>
11973 <para>Code for the role played by the other
11974 individual in the behavioral event,
11975 or <literal>&gmi_nonfocal;</literal> if the other individual
11976 is not a focal in the follow.</para>
11977
11978 <para>This value is &null; when the behavior is
11979 non-social and <literal>&gmi_nonfocal;</literal> when
11980 the interaction is with a baboon.</para>
11981 </entry>
11982 </row>
11983
11984 <row xml:id="Focal_Events-Other" xreflabel="Other">
11985 <entry>Other</entry>
11986
11987 <entry><xref linkend="PARTS"/>.<xref
11988 linkend="Parts-Participant"/></entry>
11989
11990 <entry>
11991 <para>The identifier or alternate identifier of the
11992 other individual (the the individual not designated as
11993 the focal in the row).</para>
11994
11995 <para>This value is &null; when a single chimpanzee is
11996 involved in the behavior.</para>
11997 </entry>
11998 </row>
11999
12000 <row xml:id="Focal_Events-OtherPart" xreflabel="OtherPart">
12001 <entry>OtherPart</entry>
12002
12003 <entry><xref linkend="PARTS"/>.<xref linkend="Parts-Part"/>
12004 or computed in the case of interaction with a
12005 baboon</entry>
12006
12007 <entry>
12008 <para>The role the other individual (the individual
12009 involved in the behavior who is not designated as the
12010 focal in the row) plays in the behavior.</para>
12011
12012 <para>This value is &null; when the behavior is
12013 non-social. The value is appropriate when the
12014 interaction is with a baboon.</para>
12015 </entry>
12016 </row>
12017
12018 <row xml:id="Focal_Events-Baboon" xreflabel="Baboon">
12019 <entry>Baboon</entry>
12020
12021 <entry><xref linkend="EVENTS"/>.<xref
12022 linkend="Events-Baboon"/></entry>
12023
12024 <entry>Whether or not a baboon is the second participant
12025 in the behavioral interaction.</entry>
12026 </row>
12027
12028 <row xml:id="Focal_Events-Comment" xreflabel="Comment">
12029 <entry>Comment</entry>
12030
12031 <entry><xref linkend="EVENTS"/>.<xref
12032 linkend="Events-Comment"/></entry>
12033
12034 <entry>Textual remarks regarding the behavioral
12035 event.</entry>
12036 </row>
12037
12038 </tbody>
12039 </tgroup>
12040 </informaltable>
12041
12042 </section>
12043
12044
12045 <section xml:id="FOCAL_EVENTS-Usage-Guidelines">
12046 <title>FOCAL_EVENTS Usage Guidelines</title>
12047
12048 <para>Only <literal>SELECT</literal> is allowed on
12049 FOCAL_EVENTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
12050 and <literal>DELETE</literal> are not allowed.</para>
12051 </section>
12052 </section>
12053
12054 <section xml:id="FOCAL_SOCIAL_EVENTS" xreflabel="FOCAL_SOCIAL_EVENTS">
12055 <title>FOCAL_SOCIAL_EVENTS (Dyadic Behavioral Events Involving a
12056 Focal and Some Other Chimp)</title>
12057 <titleabbrev>FOCAL_SOCIAL_EVENTS (Dyadic Behavioral Events Involving a
12058 Focal)</titleabbrev>
12059
12060 <para>FOCAL_SOCIAL_EVENTS contains one row per
12061 <xref linkend="EVENTS"/> row per individual involved in the
12062 behavioral event when the individual is a focal in the follow
12063 where a focal in the follow is one of 2 chimpanzees involved in
12064 the exhibited behavior. FOCAL_SOCIAL_EVENTS provides a direct way
12065 to analyze social behaviors when interested in the role (mom,
12066 infant, sib, non-focal) of the chimpanzees involved in the
12067 behavior.</para>
12068
12069 <caution>
12070 <para>FOCAL_SOCIAL_EVENTS has 0, 1 or 2 rows per behavioral
12071 event -- per <xref linkend="EVENTS"/> row -- depending on
12072 whether there are 2 chimpanzees involved in the event and how
12073 many of the chimpanzees are focals in the follow.</para>
12074 </caution>
12075
12076 <section xml:id="FOCAL_SOCIAL_EVENTS-Definition">
12077 <title>FOCAL_SOCIAL_EVENTS Definition</title>
12078
12079 <xi:include
12080 href="views/focal_social_events.xml"
12081 xmlns:xi="http://www.w3.org/2001/XInclude"/>
12082 </section>
12083
12084 <section xml:id="Focal_Social_Events-Columns">
12085 <title>FOCAL_SOCIAL_EVENTS Columns</title>
12086
12087 <informaltable frame="topbot">
12088 <tgroup cols="3" colsep="0" rowsep="0">
12089 <colspec colnum="3" rowsep="1"/>
12090 <thead>
12091 <row rowsep="1">
12092 <entry>Column</entry>
12093 <entry>From</entry>
12094 <entry>Description</entry>
12095 </row>
12096 </thead>
12097
12098 <tbody>
12099 <row xml:id="Focal_Social_Events-EID" xreflabel="EID">
12100 <entry>EID</entry>
12101
12102 <entry><xref linkend="EVENTS"/>.<xref
12103 linkend="Events-EID"/></entry>
12104
12105 <entry>Identifier of the
12106 behavioral event row.</entry>
12107 </row>
12108
12109 <row xml:id="Focal_Social_Events-IntID" xreflabel="IntID">
12110 <entry>IntID</entry>
12111
12112 <entry><xref linkend="EVENTS"/>.<xref
12113 linkend="Events-IntID"/></entry>
12114
12115 <entry>Identifier of the observation interval during
12116 which the event was recorded.</entry>
12117 </row>
12118
12119 <row xml:id="Focal_Social_Events-FocalPID" xreflabel="FocalPID">
12120 <entry>FocalPID</entry>
12121
12122 <entry><xref linkend="PARTS"/>.<xref
12123 linkend="Parts-PID"/></entry>
12124
12125 <entry>Identifier of the behavioral participant row
12126 which records behavioral data regarding one of the focals
12127 in the follow.</entry>
12128 </row>
12129
12130 <row xml:id="Focal_Social_Events-OtherPID" xreflabel="OtherPID">
12131 <entry>OtherPID</entry>
12132
12133 <entry><xref linkend="PARTS"/>.<xref
12134 linkend="Parts-PID"/></entry>
12135
12136 <entry>Identifier of the behavioral participant row
12137 which records behavioral data regarding the other
12138 individual (the individual involved in the behavior who is
12139 not designated as the focal in the row).</entry>
12140 </row>
12141
12142 <row xml:id="Focal_Social_Events-Behavior" xreflabel="Behavior">
12143 <entry>Behavior</entry>
12144
12145 <entry><xref linkend="EVENTS"/>.<xref
12146 linkend="Events-Behavior"/></entry>
12147
12148 <entry>Code indicating the behavior observed.</entry>
12149 </row>
12150
12151 <row xml:id="Focal_Social_Events-Position" xreflabel="Position">
12152 <entry>Position</entry>
12153
12154 <entry><xref linkend="EVENTS"/>.<xref
12155 linkend="Events-Position"/></entry>
12156
12157 <entry>Position within the canopy where the event
12158 occurred.</entry>
12159 </row>
12160
12161 <row xml:id="Focal_Social_Events-Uncertain" xreflabel="Uncertain">
12162 <entry>Uncertain</entry>
12163
12164 <entry><xref linkend="EVENTS"/>.<xref
12165 linkend="Events-Uncertain"/></entry>
12166
12167 <entry>Whether or not the behavior was observed with
12168 certainty.</entry>
12169 </row>
12170
12171 <row xml:id="Focal_Social_Events-FocalRole" xreflabel="FocalRole">
12172 <entry>FocalRole (Role in Follow of Focal Chimp)</entry>
12173
12174 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12175 linkend="Followparts-Role"/></entry>
12176
12177 <entry>Code for the role, i.e. mom, sib,
12178 infant, played by the individual designated as focal in
12179 the behavioral event.</entry>
12180 </row>
12181
12182 <row xml:id="Focal_Social_Events-Focal" xreflabel="Focal">
12183 <entry>Focal</entry>
12184
12185 <entry><xref linkend="PARTS"/>.<xref
12186 linkend="Parts-Participant"/></entry>
12187
12188 <entry>The identifier or alternate identifier of the
12189 focal.</entry>
12190 </row>
12191
12192 <row xml:id="Focal_Social_Events-FocalPart" xreflabel="FocalPart">
12193 <entry>FocalPart</entry>
12194
12195 <entry><xref linkend="PARTS"/>.<xref
12196 linkend="Parts-Part"/></entry>
12197
12198 <entry>The role the focal plays in the behavior.</entry>
12199 </row>
12200
12201 <row xml:id="Focal_Social_Events-OtherRole" xreflabel="OtherRole">
12202 <entry>OtherRole (Role in Follow of Other Chimp)</entry>
12203
12204 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12205 linkend="Followparts-Role"/></entry>
12206
12207 <entry>Code for the role played by the other individual
12208 in the behavioral event,
12209 or <literal>&gmi_nonfocal;</literal> if the other
12210 individual is not a focal in the follow.</entry>
12211 </row>
12212
12213 <row xml:id="Focal_Social_Events-Other" xreflabel="Other">
12214 <entry>Other</entry>
12215
12216 <entry><xref linkend="PARTS"/>.<xref
12217 linkend="Parts-Participant"/></entry>
12218
12219 <entry>The identifier or alternate identifier of the
12220 other individual (the the individual not designated as
12221 the focal in the row).</entry>
12222 </row>
12223
12224 <row xml:id="Focal_Social_Events-OtherPart" xreflabel="OtherPart">
12225 <entry>OtherPart</entry>
12226
12227 <entry><xref linkend="PARTS"/>.<xref
12228 linkend="Parts-Part"/></entry>
12229
12230 <entry>The role the other individual (the individual
12231 involved in the behavior who is not designated as the
12232 focal in the row) plays in the behavior.</entry>
12233 </row>
12234
12235 <row xml:id="Focal_Social_Events-Comment" xreflabel="Comment">
12236 <entry>Comment</entry>
12237
12238 <entry><xref linkend="EVENTS"/>.<xref
12239 linkend="Events-Comment"/></entry>
12240
12241 <entry>Textual remarks regarding the behavioral
12242 event.</entry>
12243 </row>
12244
12245 </tbody>
12246 </tgroup>
12247 </informaltable>
12248
12249 </section>
12250
12251
12252 <section xml:id="FOCAL_SOCIAL_EVENTS-Usage-Guidelines">
12253 <title>FOCAL_SOCIAL_EVENTS Usage Guidelines</title>
12254
12255 <para>Only <literal>SELECT</literal> is allowed on
12256 FOCAL_SOCIAL_EVENTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
12257 and <literal>DELETE</literal> are not allowed.</para>
12258 </section>
12259 </section>
12260
12261 <section xml:id="NOOBS" xreflabel="NOOBS">
12262 <title>NOOBS (Times During Which a Focal has no Behavioral
12263 Observations)</title>
12264
12265 <para>NOOBS contains one row per <xref linkend="FOLLOWS"/> row,
12266 per <xref linkend="FOLLOWPARTS"/> row, per minute from
12267 &gmi_day_start; through &gmi_day_end;, inclusive, but only when
12268 there is no behavioral data on the focal. NOOBS provides a
12269 direct way to tell when there is no behavioral data on a focal,
12270 regardless of reason and, so long as the individual is a focal
12271 in a follow on given day, irrespective of whether an observer is
12272 present.</para>
12273
12274 <para>Note that the <xref linkend="Noobs-ChimpID"/> should be
12275 the same as the <xref linkend="Noobs-AnimID"/>, unless twins are
12276 involved.</para>
12277
12278 <section xml:id="NOOBS-Definition">
12279 <title>NOOBS Definition</title>
12280
12281 <xi:include
12282 href="views/noobs.xml"
12283 xmlns:xi="http://www.w3.org/2001/XInclude"/>
12284 </section>
12285
12286 <section xml:id="Noobs-Columns">
12287 <title>NOOBS Columns</title>
12288
12289 <informaltable frame="topbot">
12290 <tgroup cols="3" colsep="0" rowsep="0">
12291 <colspec colnum="3" rowsep="1"/>
12292 <thead>
12293 <row rowsep="1">
12294 <entry>Column</entry>
12295 <entry>From</entry>
12296 <entry>Description</entry>
12297 </row>
12298 </thead>
12299
12300 <tbody>
12301 <row xml:id="Noobs-FollowID" xreflabel="FollowID">
12302 <entry>FollowID</entry>
12303
12304 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12305 linkend="Followparts-FollowID"/></entry>
12306
12307 <entry>Identifier of the follow.</entry>
12308 </row>
12309
12310 <row xml:id="Noobs-ChimpID" xreflabel="ChimpID">
12311 <entry>ChimpID</entry>
12312
12313 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12314 linkend="Followparts-ChimpID"/></entry>
12315
12316 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of the
12317 focal. Useful when twins are involved.</entry>
12318 </row>
12319
12320 <row xml:id="Noobs-Role" xreflabel="Role">
12321 <entry>Role</entry>
12322
12323 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12324 linkend="Followparts-Role"/></entry>
12325
12326 <entry>The role the focal plays in the follow.</entry>
12327 </row>
12328
12329 <row xml:id="Noobs-AnimID" xreflabel="AnimID">
12330 <entry>AnimID</entry>
12331
12332 <entry><xref linkend="CHIMPIDS"/>.<xref
12333 linkend="ChimpIDs-AnimID"/></entry>
12334
12335 <entry>The canonical id, the
12336 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
12337 of the focal.</entry>
12338 </row>
12339
12340 <row xml:id="Noobs-Time" xreflabel="Time">
12341 <entry>Time</entry>
12342
12343 <entry>Computed</entry>
12344
12345 <entry>The time.</entry>
12346 </row>
12347
12348 </tbody>
12349 </tgroup>
12350 </informaltable>
12351
12352 </section>
12353
12354
12355 <section xml:id="NOOBS-Usage-Guidelines">
12356 <title>NOOBS Usage Guidelines</title>
12357
12358 <para>Only <literal>SELECT</literal> is allowed on
12359 NOOBS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
12360 and <literal>DELETE</literal> are not allowed.</para>
12361 </section>
12362 </section>
12363
12364 <section xml:id="SOCIAL_BOUTS" xreflabel="SOCIAL_BOUTS">
12365 <title>SOCIAL_BOUTS (Analysis of the focals' Behavioral Bouts,
12366 per Social Partner, per Minute)</title>
12367 <titleabbrev>SOCIAL_BOUTS (Analysis of the focals' Behavioral Bouts,
12368 per Partner, per Minute)</titleabbrev>
12369
12370 <para>A social bout is defined as a contiguous series of minutes
12371 during which a focal is involved in a behavior with a given
12372 social partner. However, behavioral events involving baboons
12373 are excluded when considering contiguity. Behaviors are
12374 distinguished by the codes used to represent them. An
12375 individual can be involved in more than one social bout at a
12376 time, if involved in more than one social behavior at a
12377 time.</para>
12378
12379 <para>SOCIAL_BOUTS contains one row per
12380 <xref linkend="FOLLOWPARTS"/> row per
12381 <xref linkend="INTERVALS"/> row, per
12382 <xref linkend="EVENTS"/>.<xref linkend="Events-Behavior"/> value
12383 having a related <xref linkend="PARTS"/> row that shows the
12384 given focal involved in the given behavior with a social
12385 partner, per <xref linkend="Biography_Data-AnimID"/> of the
12386 social partner -- one row per follow, per focal, per social
12387 partner, per interval in which the focal is involved in a social
12388 behavior (excluding behavioral events which involve a baboon),
12389 per code for the behavior involved in. The number of rows
12390 returned is not affected by the behavioral role the focal plays
12391 regards the social behavior or whether the focal is involved
12392 with the same behavior with the same social partner in a number
12393 of ways. There is a row per focal per social partner per social
12394 behavior the focal is involved in per interval, excluding cases
12395 where a baboon is involved.</para>
12396
12397 <para>Social bouts are numbered sequentially, in a time-wise
12398 order, per follow, per focal, per social partner, per social
12399 behavior, starting with 1.</para>
12400
12401 <para>Note that uncertain behavioral events are not distinguished
12402 from certain behavioral events in event bout analysis, although
12403 the SOCIAL_BOUTS view does provide some information regarding
12404 uncertainty.</para>
12405
12406 <para>See <xref linkend="EVENT_BOUTS"/> for more information on
12407 bout analysis.</para>
12408
12409 <section xml:id="SOCIAL_BOUTS-Definition">
12410 <title>SOCIAL_BOUTS Definition</title>
12411
12412 <xi:include
12413 href="views/social_bouts.xml"
12414 xmlns:xi="http://www.w3.org/2001/XInclude"/>
12415 </section>
12416
12417 <section xml:id="Social_Bouts-Columns">
12418 <title>SOCIAL_BOUTS Columns</title>
12419
12420 <informaltable frame="topbot">
12421 <tgroup cols="3" colsep="0" rowsep="0">
12422 <colspec colnum="3" rowsep="1"/>
12423 <thead>
12424 <row rowsep="1">
12425 <entry>Column</entry>
12426 <entry>From</entry>
12427 <entry>Description</entry>
12428 </row>
12429 </thead>
12430
12431 <tbody>
12432 <row xml:id="Social_Bouts-FollowID" xreflabel="FollowID">
12433 <entry>FollowID</entry>
12434
12435 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12436 linkend="Followparts-FollowID"/></entry>
12437
12438 <entry>Identifier of the
12439 follow.</entry>
12440 </row>
12441
12442 <row xml:id="Social_Bouts-IntID" xreflabel="IntID">
12443 <entry>IntID</entry>
12444
12445 <entry><xref linkend="INTERVALS"/>.<xref
12446 linkend="Intervals-IntID"/></entry>
12447
12448 <entry>Identifier of the observation interval
12449 comprising one of the bout's minutes.</entry>
12450 </row>
12451
12452 <row xml:id="Social_Bouts-Function" xreflabel="Function">
12453 <entry>Function (Function in Follow of Focal)</entry>
12454
12455 <entry><xref linkend="FOLLOWROLES"/>.<xref
12456 linkend="Followroles-Function"/></entry>
12457
12458 <entry>Code indicating the biological role the focal
12459 plays in the follow: Mother, Infant, or
12460 Sibling.</entry>
12461 </row>
12462
12463 <row xml:id="Social_Bouts-AnimID" xreflabel="AnimID">
12464 <entry>AnimID</entry>
12465
12466 <entry><xref linkend="CHIMPIDS"/>.<xref
12467 linkend="ChimpIDs-AnimID"/></entry>
12468
12469 <entry>Canonical identifier of the focal, the
12470 <xref linkend="BIOGRAPHY_DATA"/>.<xref
12471 linkend="Biography_Data-AnimID"/>
12472 value. This can differ from the
12473 <xref linkend="ChimpIDs-ChimpID"/> in the case of
12474 twins or other circumstances where individuals have multiple
12475 identifiers.</entry>
12476 </row>
12477
12478 <row xml:id="Social_Bouts-Role" xreflabel="Role">
12479 <entry>Role (Role in Follow of Focal)</entry>
12480
12481 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12482 linkend="Followparts-Role"/></entry>
12483
12484 <entry>Code indicating the family role the focal plays
12485 in the follow. This can differ from the
12486 <xref linkend="Social_Bouts-Function"/> in the case of
12487 twins.</entry>
12488 </row>
12489
12490 <row xml:id="Social_Bouts-ChimpID" xreflabel="ChimpID">
12491 <entry>ChimpID</entry>
12492
12493 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12494 linkend="Followparts-ChimpID"/></entry>
12495
12496 <entry>Identifier of the focal as recorded in the
12497 <xref linkend="FOLLOWROLES"/> row for the follow. This
12498 can differ from the focal's
12499 <xref linkend="Biography_Data-AnimID"/> in the case of
12500 twins or other circumstances where individuals have
12501 multiple identifiers. In such cases this may also
12502 differ from the <xref linkend="ChimpIDs-ChimpID"/>
12503 stored in the
12504 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
12505 rows which designate the focal as being involved in a
12506 behavioral event.</entry>
12507 </row>
12508
12509 <row xml:id="Social_Bouts-Other_Function"
12510 xreflabel="Other_Function">
12511 <entry>Other_Function (Function in Follow of
12512 focal's social partner)</entry>
12513
12514 <entry><xref linkend="FOLLOWROLES"/>.<xref
12515 linkend="Followroles-Function"/></entry>
12516
12517 <entry>Code indicating the biological role the focal's
12518 social partner plays in the follow: Mother, Infant,
12519 Sibling, or &null; when the social partner is not also
12520 a focal.</entry>
12521 </row>
12522
12523 <row xml:id="Social_Bouts-Other_AnimID" xreflabel="Other_AnimID">
12524 <entry>Other_AnimID (AnimID of the focal's social
12525 partner)</entry>
12526
12527 <entry><xref linkend="CHIMPIDS"/>.<xref
12528 linkend="ChimpIDs-AnimID"/></entry>
12529
12530 <entry>Canonical identifier of the focal's social
12531 partner, the <xref linkend="BIOGRAPHY_DATA"/>.<xref
12532 linkend="Biography_Data-AnimID"/>
12533 value. This can differ from the
12534 <xref linkend="ChimpIDs-ChimpID"/> in the case of
12535 twins or other circumstances where individuals have
12536 multiple identifiers.</entry>
12537 </row>
12538
12539 <row xml:id="Social_Bouts-Other_Role" xreflabel="Other_Role">
12540 <entry>Other_Role (Role in Follow of focal's social
12541 partner)</entry>
12542
12543 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12544 linkend="Followparts-Role"/></entry>
12545
12546 <entry>Code indicating the family role the focal's
12547 social partner plays in the follow. As with
12548 <xref linkend="Social_Bouts-Other_Function"/> the value
12549 is &null; when the focal's social partner is not a
12550 focal. The value in this column can differ from the
12551 <xref linkend="Social_Bouts-Other_Function"/> in the
12552 case of twins.</entry>
12553 </row>
12554
12555 <row xml:id="Social_Bouts-Other_ChimpID"
12556 xreflabel="Other_ChimpID">
12557 <entry>Other_ChimpID (ChimpID of the focal's social
12558 partner when the partner is a focal)</entry>
12559
12560 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12561 linkend="Followparts-ChimpID"/></entry>
12562
12563 <entry>
12564 <para>Identifier of the focal's social partner as
12565 recorded in the <xref linkend="FOLLOWROLES"/> row for
12566 the follow. This can differ from the focal's
12567 <xref linkend="Biography_Data-AnimID"/> in the case
12568 of twins or other circumstances where individuals
12569 have multiple identifiers. In such cases this may
12570 also differ from the
12571 <xref linkend="ChimpIDs-ChimpID"/> stored in the
12572 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
12573 rows which designate the social partner as being
12574 involved in a behavioral event.</para>
12575
12576 <para>&null; when the focal's social partner is not
12577 themselves a focal.</para>
12578 </entry>
12579 </row>
12580
12581 <row xml:id="Social_Bouts-Bout" xreflabel="Bout">
12582 <entry>Bout</entry>
12583
12584 <entry>Computed</entry>
12585
12586 <entry>Integer indicating the bout number. Bout
12587 numbers start with 1 and are per follow, per focal, per
12588 social partner, per behavior code.</entry>
12589 </row>
12590
12591 <row xml:id="Social_Bouts-Behavior" xreflabel="Behavior">
12592 <entry>Behavior</entry>
12593
12594 <entry><xref linkend="EVENTS"/>.<xref
12595 linkend="Events-Behavior"/></entry>
12596
12597 <entry>Code indicating the behavior in which the focal
12598 is involved.</entry>
12599 </row>
12600
12601 <row xml:id="Social_Bouts-Uncertain" xreflabel="Uncertain">
12602 <entry>Uncertain</entry>
12603
12604 <entry><xref linkend="EVENTS"/>.<xref
12605 linkend="Events-Uncertain"/></entry>
12606
12607 <entry>&true; if all of the (non-baboon related)
12608 behavioral events in which the focal is involved with
12609 the social partner during the given minute for the
12610 given behavior are uncertain, &false;
12611 otherwise.</entry>
12612 </row>
12613
12614 <row xml:id="Social_Bouts-Time" xreflabel="Time">
12615 <entry>Time</entry>
12616
12617 <entry><xref linkend="INTERVALS"/>.<xref
12618 linkend="Intervals-Time"/></entry>
12619
12620 <entry>The time of the observation.</entry>
12621 </row>
12622
12623 <row xml:id="Social_Bouts-Mins_In" xreflabel="Mins_In">
12624 <entry>Mins_In (Minutes Into the bout)</entry>
12625
12626 <entry>Computed</entry>
12627
12628 <entry>Number of minutes into the current bout,
12629 including the current minute.<footnote>
12630
12631 <para>Therefore, the first minute of the bout has a
12632 <xref linkend="Social_Bouts-Mins_In"/> value of 1,
12633 the next minute in the bout has a value of 2,
12634 etc.</para>
12635
12636 </footnote>
12637 </entry>
12638 </row>
12639
12640 <row xml:id="Social_Bouts-Mins_Out" xreflabel="Mins_Out">
12641 <entry>Mins_Out (Minutes remaining in the bout)</entry>
12642
12643 <entry>Computed</entry>
12644
12645 <entry>Number of minutes remaining in the current bout,
12646 excluding the current minute.<footnote>
12647
12648 <para>Therefore, the last minute of the bout has a
12649 <xref linkend="Social_Bouts-Mins_Out"/> value of 0,
12650 the prior minute in the bout has a value of 1,
12651 etc.</para>
12652
12653 </footnote>
12654 </entry>
12655 </row>
12656
12657 <row xml:id="Social_Bouts-Prior_Gap" xreflabel="Prior_Gap">
12658 <entry>Prior_Gap (Minutes between the current and Prior
12659 bout)</entry>
12660
12661 <entry>Computed</entry>
12662
12663 <entry>The number of minutes between the current bout
12664 and the previous bout (of the same follow, focal,
12665 social partner, and behavior). &null; if there is no
12666 prior bout.</entry>
12667 </row>
12668
12669 <row xml:id="Social_Bouts-Gap_NoObs" xreflabel="Gap_NoObs">
12670 <entry>Gap_NoObs (Minutes without Observation of the
12671 focal between the current and prior bout)</entry>
12672
12673 <entry>Computed</entry>
12674
12675 <entry>The number of minutes between the current bout
12676 and the previous bout (of the same follow, focal,
12677 social partner, and behavior) during which there is no
12678 behavioral data what so ever on the focal. &null; if
12679 there is no prior bout.</entry>
12680 </row>
12681
12682 <row xml:id="Social_Bouts-Left_Censored"
12683 xreflabel="Left_Censored">
12684 <entry>Left_Censored</entry>
12685
12686 <entry>Computed.</entry>
12687
12688 <entry>&true; when the bout is left censored, &false;
12689 otherwise. See <xref linkend="EVENT_BOUTS"/> above for
12690 more information regards censoring.</entry>
12691 </row>
12692
12693 <row xml:id="Social_Bouts-Right_Censored"
12694 xreflabel="Right_Censored">
12695 <entry>Right_Censored</entry>
12696
12697 <entry>Computed.</entry>
12698
12699 <entry>&true; when the bout is right censored, &false;
12700 otherwise. See <xref linkend="EVENT_BOUTS"/> above for
12701 more information regards censoring.</entry>
12702 </row>
12703
12704 <row xml:id="Social_Bouts-Day_Start" xreflabel="Day_Start">
12705 <entry>Day_Start (Bout is censored due to Start of
12706 Day)</entry>
12707
12708 <entry>Computed</entry>
12709
12710 <entry>&true; when the bout is censored because it
12711 occurs at the beginning of the day's observation of the
12712 follow, &false; otherwise.</entry>
12713 </row>
12714
12715 <row xml:id="Social_Bouts-Day_End" xreflabel="Day_End">
12716 <entry>Day_End (Bout is censored due to End of
12717 Day)</entry>
12718
12719 <entry>Computed</entry>
12720
12721 <entry>&true; when the bout is censored because it
12722 occurs at the end of the day's observation of the
12723 follow, &false; otherwise.</entry>
12724 </row>
12725
12726 </tbody>
12727 </tgroup>
12728 </informaltable>
12729
12730 </section>
12731
12732
12733 <section xml:id="SOCIAL_BOUTS-Usage-Guidelines">
12734 <title>SOCIAL_BOUTS Usage Guidelines</title>
12735
12736 <para>Only <literal>SELECT</literal> is allowed on
12737 SOCIAL_BOUTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
12738 and <literal>DELETE</literal> are not allowed.</para>
12739 </section>
12740 </section>
12741
12742 <section xml:id="SOCIAL_BOUT_AGGS" xreflabel="SOCIAL_BOUT_AGGS">
12743 <title>SOCIAL_BOUT_AGGS (Analysis of the focals' Social
12744 behavioral Bouts, per Social Partner per Bout)</title>
12745 <titleabbrev>SOCIAL_BOUT_AGGS (Analysis of
12746 Social Bouts, per Social Partner per Bout)</titleabbrev>
12747
12748 <para>SOCIAL_BOUT_AGGS contains one row per
12749 <xref linkend="FOLLOWPARTS"/> row per
12750 <xref linkend="EVENTS"/>.<xref linkend="Events-Behavior"/> value
12751 having a related <xref linkend="PARTS"/> row that shows the
12752 given focal involved in the given behavior with a social
12753 partner, per <xref linkend="Biography_Data-AnimID"/> of the
12754 social partner -- one row per follow, per focal, per social
12755 partner (excluding behavioral events which involve a baboon),
12756 per code for the behavior involved in. Each row represents an
12757 entire event bout.</para>
12758
12759 <para>See <xref linkend="SOCIAL_BOUTS"/> for more information on
12760 event bout analysis.</para>
12761
12762 <section xml:id="SOCIAL_BOUT_AGGS-Definition">
12763 <title>SOCIAL_BOUT_AGGS Definition</title>
12764
12765 <xi:include
12766 href="views/social_bout_aggs.xml"
12767 xmlns:xi="http://www.w3.org/2001/XInclude"/>
12768 </section>
12769
12770 <section xml:id="Social_Bout_Aggs-Columns">
12771 <title>SOCIAL_BOUT_AGGS Columns</title>
12772
12773 <informaltable frame="topbot">
12774 <tgroup cols="3" colsep="0" rowsep="0">
12775 <colspec colnum="3" rowsep="1"/>
12776 <thead>
12777 <row rowsep="1">
12778 <entry>Column</entry>
12779 <entry>From</entry>
12780 <entry>Description</entry>
12781 </row>
12782 </thead>
12783
12784 <tbody>
12785 <row xml:id="Social_Bout_Aggs-FollowID" xreflabel="FollowID">
12786 <entry>FollowID</entry>
12787
12788 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12789 linkend="Followparts-FollowID"/></entry>
12790
12791 <entry>Identifier of the
12792 follow.</entry>
12793 </row>
12794
12795 <row xml:id="Social_Bout_Aggs-Function" xreflabel="Function">
12796 <entry>Function (Function in Follow of Focal)</entry>
12797
12798 <entry><xref linkend="FOLLOWROLES"/>.<xref
12799 linkend="Followroles-Function"/></entry>
12800
12801 <entry>Code indicating the biological role the focal
12802 plays in the follow: Mother, Infant, or
12803 Sibling.</entry>
12804 </row>
12805
12806 <row xml:id="Social_Bout_Aggs-AnimID" xreflabel="AnimID">
12807 <entry>AnimID</entry>
12808
12809 <entry><xref linkend="CHIMPIDS"/>.<xref
12810 linkend="ChimpIDs-AnimID"/></entry>
12811
12812 <entry>Canonical identifier of the focal, the
12813 <xref linkend="BIOGRAPHY_DATA"/>.<xref
12814 linkend="Biography_Data-AnimID"/>
12815 value. This can differ from the
12816 <xref linkend="ChimpIDs-ChimpID"/> in the case of
12817 twins or other circumstances where individuals have multiple
12818 identifiers.</entry>
12819 </row>
12820
12821 <row xml:id="Social_Bout_Aggs-Role" xreflabel="Role">
12822 <entry>Role (Role in Follow of Focal)</entry>
12823
12824 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12825 linkend="Followparts-Role"/></entry>
12826
12827 <entry>Code indicating the family role the focal plays
12828 in the follow. This can differ from the
12829 <xref linkend="Social_Bout_Aggs-Function"/> in the case of
12830 twins.</entry>
12831 </row>
12832
12833 <row xml:id="Social_Bout_Aggs-ChimpID" xreflabel="ChimpID">
12834 <entry>ChimpID</entry>
12835
12836 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12837 linkend="Followparts-ChimpID"/></entry>
12838
12839 <entry>Identifier of the focal as recorded in the
12840 <xref linkend="FOLLOWROLES"/> row for the follow. This
12841 can differ from the focal's
12842 <xref linkend="Biography_Data-AnimID"/> in the case of
12843 twins or other circumstances where individuals have
12844 multiple identifiers. In such cases this may also
12845 differ from the <xref linkend="ChimpIDs-ChimpID"/>
12846 stored in the
12847 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
12848 rows which designate the focal as being involved in a
12849 behavioral event.</entry>
12850 </row>
12851
12852 <row xml:id="Social_Bout_Aggs-Other_Function"
12853 xreflabel="Other_Function">
12854 <entry>Other_Function (Function in Follow of
12855 focal's social partner)</entry>
12856
12857 <entry><xref linkend="FOLLOWROLES"/>.<xref
12858 linkend="Followroles-Function"/></entry>
12859
12860 <entry>Code indicating the biological role the focal's
12861 social partner plays in the follow: Mother, Infant,
12862 Sibling, or &null; when the social partner is not also
12863 a focal.</entry>
12864 </row>
12865
12866 <row xml:id="Social_Bout_Aggs-Other_AnimID"
12867 xreflabel="Other_AnimID">
12868 <entry>Other_AnimID (AnimID of the focal's social
12869 partner)</entry>
12870
12871 <entry><xref linkend="CHIMPIDS"/>.<xref
12872 linkend="ChimpIDs-AnimID"/></entry>
12873
12874 <entry>Canonical identifier of the focal's social
12875 partner, the <xref linkend="BIOGRAPHY_DATA"/>.<xref
12876 linkend="Biography_Data-AnimID"/>
12877 value. This can differ from the
12878 <xref linkend="ChimpIDs-ChimpID"/> in the case of
12879 twins or other circumstances where individuals have
12880 multiple identifiers.</entry>
12881 </row>
12882
12883 <row xml:id="Social_Bout_Aggs-Other_Role" xreflabel="Other_Role">
12884 <entry>Other_Role (Role in Follow of focal's social
12885 partner)</entry>
12886
12887 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12888 linkend="Followparts-Role"/></entry>
12889
12890 <entry>Code indicating the family role the focal's
12891 social partner plays in the follow. As with
12892 <xref linkend="Social_Bout_Aggs-Other_Function"/> the value
12893 is &null; when the focal's social partner is not a
12894 focal. The value in this column can differ from the
12895 <xref linkend="Social_Bout_Aggs-Other_Function"/> in the
12896 case of twins.</entry>
12897 </row>
12898
12899 <row xml:id="Social_Bout_Aggs-Other_ChimpID"
12900 xreflabel="Other_ChimpID">
12901 <entry>Other_ChimpID (ChimpID of the focal's social
12902 partner when the partner is a focal)</entry>
12903
12904 <entry><xref linkend="FOLLOWPARTS"/>.<xref
12905 linkend="Followparts-ChimpID"/></entry>
12906
12907 <entry>
12908 <para>Identifier of the focal's social partner as
12909 recorded in the <xref linkend="FOLLOWROLES"/> row for
12910 the follow. This can differ from the focal's
12911 <xref linkend="Biography_Data-AnimID"/> in the case
12912 of twins or other circumstances where individuals
12913 have multiple identifiers. In such cases this may
12914 also differ from the
12915 <xref linkend="ChimpIDs-ChimpID"/> stored in the
12916 <xref linkend="PARTS"/>.<xref linkend="Parts-Participant"/>
12917 rows which designate the social partner as being
12918 involved in a behavioral event.</para>
12919
12920 <para>&null; when the focal's social partner is not
12921 themselves a focal.</para>
12922 </entry>
12923 </row>
12924
12925 <row xml:id="Social_Bout_Aggs-Bout" xreflabel="Bout">
12926 <entry>Bout</entry>
12927
12928 <entry>Computed</entry>
12929
12930 <entry>Integer indicating the bout number. Bout
12931 numbers start with 1 and are per follow, per focal, per
12932 behavior code.</entry>
12933 </row>
12934
12935 <row xml:id="Social_Bout_Aggs-Behavior" xreflabel="Behavior">
12936 <entry>Behavior</entry>
12937
12938 <entry><xref linkend="EVENTS"/>.<xref
12939 linkend="Events-Behavior"/></entry>
12940
12941 <entry>Code indicating the behavior in which the focal
12942 is involved.</entry>
12943 </row>
12944
12945 <row xml:id="Social_Bout_Aggs-Uncertain" xreflabel="Uncertain">
12946 <entry>Uncertain</entry>
12947
12948 <entry><xref linkend="EVENTS"/>.<xref
12949 linkend="Events-Uncertain"/></entry>
12950
12951 <entry>&true; if any of the underlying
12952 <xref linkend="SOCIAL_BOUTS"/> rows which comprise the
12953 bout are uncertain, &false; otherwise.</entry>
12954 </row>
12955
12956 <row xml:id="Social_Bout_Aggs-Start_Time" xreflabel="Start_Time">
12957 <entry>Start_Time</entry>
12958
12959 <entry><xref linkend="INTERVALS"/>.<xref
12960 linkend="Intervals-Time"/></entry>
12961
12962 <entry>The time the event bout started. The time of
12963 the first observation of the bout.</entry>
12964 </row>
12965
12966 <row xml:id="Social_Bout_Aggs-Stop_Time" xreflabel="Stop_time">
12967 <entry>Stop_Time</entry>
12968
12969 <entry><xref linkend="INTERVALS"/>.<xref
12970 linkend="Intervals-Time"/></entry>
12971
12972 <entry>The time the event bout stopped. The time of
12973 the last observation of the bout.</entry>
12974 </row>
12975
12976 <row xml:id="Social_Bout_Aggs-Prior_Gap" xreflabel="Prior_Gap">
12977 <entry>Prior_Gap (Minutes between the current and Prior
12978 bout)</entry>
12979
12980 <entry>Computed</entry>
12981
12982 <entry>The number of minutes between the current bout
12983 and the previous bout (of the same follow, focal,
12984 behavior). &null; if there is no prior bout.</entry>
12985 </row>
12986
12987 <row xml:id="Social_Bout_Aggs-Gap_NoObs" xreflabel="Gap_NoObs">
12988 <entry>Gap_NoObs (Minutes without Observation of the
12989 focal between the current and prior bout)</entry>
12990
12991 <entry>Computed</entry>
12992
12993 <entry>The number of minutes between the current bout
12994 and the previous bout (of the same follow, focal,
12995 behavior) during which there is no behavioral data what
12996 so ever on the focal. &null; if there is no prior
12997 bout.</entry>
12998 </row>
12999
13000 <row xml:id="Social_Bout_Aggs-Left_Censored"
13001 xreflabel="Left_Censored">
13002 <entry>Left_Censored</entry>
13003
13004 <entry>Computed.</entry>
13005
13006 <entry>&true; when the bout is left censored, &false;
13007 otherwise. See above for more information regards
13008 censoring.</entry>
13009 </row>
13010
13011 <row xml:id="Social_Bout_Aggs-Right_Censored"
13012 xreflabel="Right_Censored">
13013 <entry>Right_Censored</entry>
13014
13015 <entry>Computed.</entry>
13016
13017 <entry>&true; when the bout is right censored, &false;
13018 otherwise. See above for more information regards
13019 censoring.</entry>
13020 </row>
13021
13022 <row xml:id="Social_Bout_Aggs-Day_Start" xreflabel="Day_Start">
13023 <entry>Day_Start (Bout is censored due to Start of
13024 Day)</entry>
13025
13026 <entry>Computed</entry>
13027
13028 <entry>&true; when the bout is censored because it
13029 occurs at the beginning of the day's observation of the
13030 follow, &false; otherwise.</entry>
13031 </row>
13032
13033 <row xml:id="Social_Bout_Aggs-Day_End" xreflabel="Day_End">
13034 <entry>Day_End (Bout is censored due to End of
13035 Day)</entry>
13036
13037 <entry>Computed</entry>
13038
13039 <entry>&true; when the bout is censored because it
13040 occurs at the end of the day's observation of the
13041 follow, &false; otherwise.</entry>
13042 </row>
13043
13044 </tbody>
13045 </tgroup>
13046 </informaltable>
13047
13048 </section>
13049
13050
13051 <section xml:id="SOCIAL_BOUT_AGGS-Usage-Guidelines">
13052 <title>SOCIAL_BOUT_AGGS Usage Guidelines</title>
13053
13054 <para>Only <literal>SELECT</literal> is allowed on
13055 SOCIAL_BOUT_AGGS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
13056 and <literal>DELETE</literal> are not allowed.</para>
13057 </section>
13058 </section>
13059
13060 <section xml:id="SOCIAL_EVENTS" xreflabel="SOCIAL_EVENTS">
13061 <title>SOCIAL_EVENTS (Dyadic Behavioral Events Involving
13062 Chimpanzees)</title>
13063
13064 <para>SOCIAL_EVENTS contains one row per <xref linkend="EVENTS"/>
13065 row per individual involved in the behavioral event per chimpanzee
13066 when there are 2 chimpanzees (no baboons) involved in the exhibited
13067 behavior. SOCIAL_EVENTS provides a direct way to analyze chimp
13068 social behaviors regardless of whether a chimpanzee is a focal in
13069 the follow.</para>
13070
13071 <caution>
13072 <para>SOCIAL_EVENTS has 0 or 2 rows per behavioral event -- per
13073 <xref linkend="EVENTS"/> row -- depending on whether there are
13074 2 chimpanzees involved in the event.</para>
13075 </caution>
13076
13077 <tip>
13078 <para>The two SOCIAL_EVENTS rows for each
13079 <xref linkend="EVENTS"/> row are reciprocal, the individuals
13080 arbitrarily designated <quote>first</quote>
13081 and <quote>second</quote> are reversed. So, either querying for
13082 the first individual as the mother and the 2nd as the infant or
13083 querying for the second individual as the mother and the 1st as
13084 the infant will eliminate double counting of events; each query
13085 returning <quote>one side</quote> of the <quote>duplicated
13086 pair</quote>.</para>
13087 </tip>
13088
13089 <para>The mutual placement of each interaction participant in both
13090 the <quote>first</quote> and <quote>second</quote> columns can be
13091 convenient when querying; all individuals involved in a behavior
13092 can be tested against, joined with, etc., regardless of whether
13093 the <quote>first</quote> or <quote>second</quote> column content
13094 is examined.</para>
13095
13096 <tip>
13097 <para>The <xref linkend="Social_Events-Part1Role"/> and
13098 <xref linkend="Social_Events-Part2Role"/> columns significantly
13099 slow the query. Performance is much improved if, when
13100 possible, these columns are not displayed or queried
13101 against.</para>
13102 </tip>
13103
13104 <section xml:id="SOCIAL_EVENTS-Definition">
13105 <title>SOCIAL_EVENTS Definition</title>
13106
13107 <xi:include
13108 href="views/social_events.xml"
13109 xmlns:xi="http://www.w3.org/2001/XInclude"/>
13110 </section>
13111
13112 <section xml:id="Social_Events-Columns">
13113 <title>SOCIAL_EVENTS Columns</title>
13114
13115 <informaltable frame="topbot">
13116 <tgroup cols="3" colsep="0" rowsep="0">
13117 <colspec colnum="3" rowsep="1"/>
13118 <thead>
13119 <row rowsep="1">
13120 <entry>Column</entry>
13121 <entry>From</entry>
13122 <entry>Description</entry>
13123 </row>
13124 </thead>
13125
13126 <tbody>
13127 <row xml:id="Social_Events-EID" xreflabel="EID">
13128 <entry>EID</entry>
13129
13130 <entry><xref linkend="EVENTS"/>.<xref
13131 linkend="Events-EID"/></entry>
13132
13133 <entry>Identifier of the
13134 behavioral event row.</entry>
13135 </row>
13136
13137 <row xml:id="Social_Events-IntID" xreflabel="IntID">
13138 <entry>IntID</entry>
13139
13140 <entry><xref linkend="EVENTS"/>.<xref
13141 linkend="Events-IntID"/></entry>
13142
13143 <entry>Identifier of the observation interval during
13144 which the event was recorded.</entry>
13145 </row>
13146
13147 <row xml:id="Social_Events-Part1PID" xreflabel="Part1PID">
13148 <entry>Part1PID</entry>
13149
13150 <entry><xref linkend="PARTS"/>.<xref
13151 linkend="Parts-PID"/></entry>
13152
13153 <entry>Identifier of the behavioral participant row
13154 which records behavioral data regarding <quote>the
13155 first</quote> of the individuals in the behavioral
13156 event.</entry>
13157 </row>
13158
13159 <row xml:id="Social_Events-Part2PID" xreflabel="Part2PID">
13160 <entry>Part2PID</entry>
13161
13162 <entry><xref linkend="PARTS"/>.<xref
13163 linkend="Parts-PID"/></entry>
13164
13165 <entry>Identifier of the behavioral participant row
13166 which records behavioral data regarding <quote>the
13167 second</quote> of the individuals in the behavioral
13168 event.</entry>
13169 </row>
13170
13171 <row xml:id="Social_Events-Behavior" xreflabel="Behavior">
13172 <entry>Behavior</entry>
13173
13174 <entry><xref linkend="EVENTS"/>.<xref
13175 linkend="Events-Behavior"/></entry>
13176
13177 <entry>Code indicating the behavior observed.</entry>
13178 </row>
13179
13180 <row xml:id="Social_Events-Position" xreflabel="Position">
13181 <entry>Position</entry>
13182
13183 <entry><xref linkend="EVENTS"/>.<xref
13184 linkend="Events-Position"/></entry>
13185
13186 <entry>Position within the canopy where the event
13187 occurred.</entry>
13188 </row>
13189
13190 <row xml:id="Social_Events-Uncertain" xreflabel="Uncertain">
13191 <entry>Uncertain</entry>
13192
13193 <entry><xref linkend="EVENTS"/>.<xref
13194 linkend="Events-Uncertain"/></entry>
13195
13196 <entry>Whether or not the behavior was observed with
13197 certainty.</entry>
13198 </row>
13199
13200 <row xml:id="Social_Events-Part1Role" xreflabel="Part1Role">
13201 <entry>Part1Role (Role in Follow of First Chimp)</entry>
13202
13203 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13204 linkend="Followparts-Role"/></entry>
13205
13206 <entry>Code for the role, i.e. mom, sib, infant, played
13207 by the individual designated as <quote>the
13208 first</quote> in the behavioral event.</entry>
13209 </row>
13210
13211 <row xml:id="Social_Events-Participant1" xreflabel="Partcipant1">
13212 <entry>Participant1</entry>
13213
13214 <entry><xref linkend="PARTS"/>.<xref
13215 linkend="Parts-Participant"/></entry>
13216
13217 <entry>The identifier or alternate identifier of the
13218 <quote>first</quote> individual.</entry>
13219 </row>
13220
13221 <row xml:id="Social_Events-Part1" xreflabel="Part1">
13222 <entry>Part1</entry>
13223
13224 <entry><xref linkend="PARTS"/>.<xref
13225 linkend="Parts-Part"/></entry>
13226
13227 <entry>The role the <quote>first</quote> individual plays
13228 in the behavior.</entry>
13229 </row>
13230
13231 <row xml:id="Social_Events-Part2Role" xreflabel="Part2Role">
13232 <entry>Part2Role (Role in Follow of Second Chimp)</entry>
13233
13234 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13235 linkend="Followparts-Role"/></entry>
13236
13237 <entry>Code for the role, i.e. mom, sib,
13238 infant played by the individual designated
13239 as <quote>the second</quote> in the behavioral
13240 event.</entry>
13241 </row>
13242
13243 <row xml:id="Social_Events-Participant2" xreflabel="Partcipant2">
13244 <entry>Participant2</entry>
13245
13246 <entry><xref linkend="PARTS"/>.<xref
13247 linkend="Parts-Participant"/></entry>
13248
13249 <entry>The identifier or alternate identifier of the
13250 <quote>second</quote> individual.</entry>
13251 </row>
13252
13253 <row xml:id="Social_Events-Part2" xreflabel="Part2">
13254 <entry>Part2</entry>
13255
13256 <entry><xref linkend="PARTS"/>.<xref
13257 linkend="Parts-Part"/></entry>
13258
13259 <entry>The role the <quote>second</quote> individual plays
13260 in the behavior.</entry>
13261 </row>
13262
13263 <row xml:id="Social_Events-Comment" xreflabel="Comment">
13264 <entry>Comment</entry>
13265
13266 <entry><xref linkend="EVENTS"/>.<xref
13267 linkend="Events-Comment"/></entry>
13268
13269 <entry>Textual remarks regarding the behavioral
13270 event.</entry>
13271 </row>
13272
13273 </tbody>
13274 </tgroup>
13275 </informaltable>
13276
13277 </section>
13278
13279
13280 <section xml:id="SOCIAL_EVENTS-Usage-Guidelines">
13281 <title>SOCIAL_EVENTS Usage Guidelines</title>
13282
13283 <para>Only <literal>SELECT</literal> is allowed on
13284 SOCIAL_EVENTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
13285 and <literal>DELETE</literal> are not allowed.</para>
13286 </section>
13287 </section>
13288
13289 <section xml:id="SOCIAL_EVENTS_W_BABOONS"
13290 xreflabel="SOCIAL_EVENTS_W_BABOONS">
13291 <title>SOCIAL_EVENTS_W_BABOONS (Dyadic Behavioral Events Including Baboons)</title>
13292
13293 <para>SOCIAL_EVENTS_W_BABOONS contains one row per
13294 <xref linkend="EVENTS"/> row per animal involved in the behavioral
13295 event per individual involved in the exhibited behavior, including
13296 baboons. SOCIAL_EVENTS_W_BABOONS provides a direct way to analyze
13297 social behaviors regardless of whether a chimpanzee is a focal in
13298 the follow.</para>
13299
13300 <caution>
13301 <para>SOCIAL_EVENTS_W_BABOONS has 0 or 2 rows per behavioral
13302 event -- per <xref linkend="EVENTS"/> row -- depending on
13303 whether there are 2 animals involved in the event.</para>
13304 </caution>
13305
13306 <para>The two SOCIAL_EVENTS rows for each <xref linkend="EVENTS"/>
13307 row are reciprocal, the individuals arbitrarily
13308 designated <quote>first</quote> and <quote>second</quote> are
13309 reversed. This can be convenient when querying; all individuals
13310 involved in a behavior can be tested against, joined with, etc.,
13311 regardless of whether the <quote>first</quote>
13312 or <quote>second</quote> column content is examined.</para>
13313
13314 <section xml:id="SOCIAL_EVENTS_W_BABOONS-Definition">
13315 <title>SOCIAL_EVENTS_W_BABOONS Definition</title>
13316
13317 <xi:include
13318 href="views/social_events_w_baboons.xml"
13319 xmlns:xi="http://www.w3.org/2001/XInclude"/>
13320 </section>
13321
13322 <section xml:id="Social_Events_W_Baboons-Columns">
13323 <title>SOCIAL_EVENTS_W_BABOONS Columns</title>
13324
13325 <informaltable frame="topbot">
13326 <tgroup cols="3" colsep="0" rowsep="0">
13327 <colspec colnum="3" rowsep="1"/>
13328 <thead>
13329 <row rowsep="1">
13330 <entry>Column</entry>
13331 <entry>From</entry>
13332 <entry>Description</entry>
13333 </row>
13334 </thead>
13335
13336 <tbody>
13337 <row xml:id="Social_Events_W_Baboons-EID" xreflabel="EID">
13338 <entry>EID</entry>
13339
13340 <entry><xref linkend="EVENTS"/>.<xref
13341 linkend="Events-EID"/></entry>
13342
13343 <entry>Identifier of the
13344 behavioral event row.</entry>
13345 </row>
13346
13347 <row xml:id="Social_Events_W_Baboons-IntID" xreflabel="IntID">
13348 <entry>IntID</entry>
13349
13350 <entry><xref linkend="EVENTS"/>.<xref
13351 linkend="Events-IntID"/></entry>
13352
13353 <entry>Identifier of the observation interval during
13354 which the event was recorded.</entry>
13355 </row>
13356
13357 <row xml:id="Social_Events_W_Baboons-Part1PID"
13358 xreflabel="Part1PID">
13359 <entry>Part1PID</entry>
13360
13361 <entry><xref linkend="PARTS"/>.<xref
13362 linkend="Parts-PID"/></entry>
13363
13364 <entry>Identifier of the behavioral participant row
13365 which records behavioral data regarding <quote>the
13366 first</quote> of the animals in the behavioral
13367 event.</entry>
13368 </row>
13369
13370 <row xml:id="Social_Events_W_Baboons-Part2PID"
13371 xreflabel="Part2PID">
13372 <entry>Part2PID</entry>
13373
13374 <entry><xref linkend="PARTS"/>.<xref
13375 linkend="Parts-PID"/></entry>
13376
13377 <entry>Identifier of the behavioral participant row
13378 which records behavioral data regarding <quote>the
13379 second</quote> of the animals in the behavioral
13380 event.</entry>
13381 </row>
13382
13383 <row xml:id="Social_Events_W_Baboons-Behavior"
13384 xreflabel="Behavior">
13385 <entry>Behavior</entry>
13386
13387 <entry><xref linkend="EVENTS"/>.<xref
13388 linkend="Events-Behavior"/></entry>
13389
13390 <entry>Code indicating the behavior observed.</entry>
13391 </row>
13392
13393 <row xml:id="Social_Events_W_Baboons-Position"
13394 xreflabel="Position">
13395 <entry>Position</entry>
13396
13397 <entry><xref linkend="EVENTS"/>.<xref
13398 linkend="Events-Position"/></entry>
13399
13400 <entry>Position within the canopy where the event
13401 occurred.</entry>
13402 </row>
13403
13404 <row xml:id="Social_Events_W_Baboons-Uncertain"
13405 xreflabel="Uncertain">
13406 <entry>Uncertain</entry>
13407
13408 <entry><xref linkend="EVENTS"/>.<xref
13409 linkend="Events-Uncertain"/></entry>
13410
13411 <entry>Whether or not the behavior was observed with
13412 certainty.</entry>
13413 </row>
13414
13415 <row xml:id="Social_Events_W_Baboons-Part1Role"
13416 xreflabel="Part1Role">
13417 <entry>Part1Role (Role in Follow of First Animal)</entry>
13418
13419 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13420 linkend="Followparts-Role"/> or <literal>NF</literal>
13421 in the case of baboons or nonfocal chimpanzees</entry>
13422
13423 <entry>Code for the role, i.e. mom, sib,
13424 infant, played by the animal designated
13425 as <quote>the first</quote> in the behavioral
13426 event.</entry>
13427 </row>
13428
13429 <row xml:id="Social_Events_W_Baboons-Part1Baboon"
13430 xreflabel="Part1Baboon">
13431 <entry>Part1Baboon</entry>
13432
13433 <entry>Computed</entry>
13434
13435 <entry>A Boolean value, true when
13436 the <quote>first</quote> animal is a baboon.</entry>
13437 </row>
13438
13439 <row xml:id="Social_Events_W_Baboons-Participant1"
13440 xreflabel="Partcipant1">
13441 <entry>Participant1</entry>
13442
13443 <entry><xref linkend="PARTS"/>.<xref
13444 linkend="Parts-Participant"/></entry>
13445
13446 <entry>The identifier or alternate identifier of the
13447 <quote>first</quote> animal, or &null; if the individual
13448 is a baboon.</entry>
13449 </row>
13450
13451 <row xml:id="Social_Events_W_Baboons-Part1"
13452 xreflabel="Part1">
13453 <entry>Part1</entry>
13454
13455 <entry><xref linkend="PARTS"/>.<xref
13456 linkend="Parts-Part"/> or computed based
13457 on the 2nd individual's role if the animal is a
13458 baboon</entry>
13459
13460 <entry>The role the <quote>first</quote> animal plays
13461 in the behavior.</entry>
13462 </row>
13463
13464 <row xml:id="Social_Events_W_Baboons-Part2Role"
13465 xreflabel="Part2Role">
13466 <entry>Part2Role (Role in Follow of Second Animal)</entry>
13467
13468 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13469 linkend="Followparts-Role"/> or <literal>NF</literal>
13470 in the case of baboons or nonfocal chimpanzees</entry>
13471
13472 <entry>Code for the role, i.e. mom, sib,
13473 infant, played by the animal designated
13474 as <quote>the second</quote> in the behavioral
13475 event.</entry>
13476 </row>
13477
13478 <row xml:id="Social_Events_W_Baboons-Part2Baboon"
13479 xreflabel="Part2Baboon">
13480 <entry>Part2Baboon</entry>
13481
13482 <entry>Computed</entry>
13483
13484 <entry>A Boolean value, true when
13485 the <quote>second</quote> animal is a baboon.</entry>
13486 </row>
13487
13488 <row xml:id="Social_Events_W_Baboons-Participant2"
13489 xreflabel="Partcipant2">
13490 <entry>Participant2</entry>
13491
13492 <entry><xref linkend="PARTS"/>.<xref
13493 linkend="Parts-Participant"/></entry>
13494
13495 <entry>The identifier or alternate identifier of the
13496 <quote>second</quote> animal, or &null; if the individual
13497 is a baboon.</entry>
13498 </row>
13499
13500 <row xml:id="Social_Events_W_Baboons-Part2"
13501 xreflabel="Part2">
13502 <entry>Part2</entry>
13503
13504 <entry><xref linkend="PARTS"/>.<xref
13505 linkend="Parts-Part"/> or computed based
13506 on the 2nd individual's role if the animal is a
13507 baboon</entry>
13508
13509 <entry>The role the <quote>second</quote> animal plays
13510 in the behavior.</entry>
13511 </row>
13512
13513 <row xml:id="Social_Events_W_Baboons-Comment"
13514 xreflabel="Comment">
13515 <entry>Comment</entry>
13516
13517 <entry><xref linkend="EVENTS"/>.<xref
13518 linkend="Events-Comment"/></entry>
13519
13520 <entry>Textual remarks regarding the behavioral
13521 event.</entry>
13522 </row>
13523
13524 </tbody>
13525 </tgroup>
13526 </informaltable>
13527
13528 </section>
13529
13530
13531 <section xml:id="SOCIAL_EVENTS_W_BABOONS-Usage-Guidelines">
13532 <title>SOCIAL_EVENTS_W_BABOONS Usage Guidelines</title>
13533
13534 <para>Only <literal>SELECT</literal> is allowed on
13535 SOCIAL_EVENTS_W_BABOONS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
13536 and <literal>DELETE</literal> are not allowed.</para>
13537 </section>
13538 </section>
13539
13540 </section>
13541
13542 <section xml:id="distance_views">
13543 <title>&distance_section; Views</title>
13544
13545
13546 <section xml:id="DISTS" xreflabel="DISTS">
13547 <title>DISTS (Distance Measurements Between
13548 Chimpanzees)</title>
13549
13550 <para>DISTS contains one row per <xref linkend="DISTANCES"/> row
13551 per related <xref linkend="DISTANCEPARTS"/> row. DISTS provides a
13552 general way to analyze chimp inter-familial distances -- based on
13553 either <xref linkend="ChimpIDs-ChimpID"/> or role played in the
13554 follow.</para>
13555
13556 <caution>
13557 <para>DISTS has 2 rows per inter-familial distance measurement
13558 -- per <xref linkend="DISTANCES"/> row.</para>
13559 </caution>
13560
13561 <tip>
13562 <para>The two DISTS rows for each
13563 <xref linkend="DISTANCES"/> row are reciprocal, the individuals
13564 arbitrarily designated <quote>first</quote>
13565 and <quote>second</quote> are reversed. So, either querying for
13566 the first individual as the mother and the 2nd as the infant or
13567 querying for the second individual as the mother and the 1st as
13568 the infant will eliminate double counting of events; each query
13569 returning <quote>one side</quote> of the <quote>duplicated
13570 pair</quote>.</para>
13571 </tip>
13572
13573 <para>The mutual placement of each participant in the distance
13574 measurements in both the <quote>first</quote>
13575 and <quote>second</quote> columns can be convenient when querying;
13576 all individuals involved in a measurement can be tested against,
13577 joined with, etc., regardless of whether the <quote>first</quote>
13578 or <quote>second</quote> column content is examined.</para>
13579
13580 <section xml:id="DISTS-Definition">
13581 <title>DISTS Definition</title>
13582
13583 <xi:include
13584 href="views/dists.xml"
13585 xmlns:xi="http://www.w3.org/2001/XInclude"/>
13586 </section>
13587
13588 <section xml:id="Dists-Columns">
13589 <title>DISTS Columns</title>
13590
13591 <informaltable frame="topbot">
13592 <tgroup cols="3" colsep="0" rowsep="0">
13593 <colspec colnum="3" rowsep="1"/>
13594 <thead>
13595 <row rowsep="1">
13596 <entry>Column</entry>
13597 <entry>From</entry>
13598 <entry>Description</entry>
13599 </row>
13600 </thead>
13601
13602 <tbody>
13603 <row xml:id="Dists-DistID" xreflabel="DistID">
13604 <entry>DistID</entry>
13605
13606 <entry><xref linkend="DISTANCES"/>.<xref
13607 linkend="Distances-DistID"/></entry>
13608
13609 <entry>Identifier of the
13610 distance measurement row.</entry>
13611 </row>
13612
13613 <row xml:id="Dists-IntID" xreflabel="IntID">
13614 <entry>IntID</entry>
13615
13616 <entry><xref linkend="DISTANCES"/>.<xref
13617 linkend="Distances-IntID"/></entry>
13618
13619 <entry>Identifier of the observation interval during
13620 which the distance measurement was recorded.</entry>
13621 </row>
13622
13623 <row xml:id="Dists-Part1DPID" xreflabel="Part1DPID">
13624 <entry>Part1DPID</entry>
13625
13626 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13627 linkend="Distanceparts-DPID"/></entry>
13628
13629 <entry>Identifier of the distance measurement participant
13630 row which records data regarding <quote>the
13631 first</quote> of the individuals between which distance
13632 was measured.</entry>
13633 </row>
13634
13635 <row xml:id="Dists-Part2DPID" xreflabel="Part2DPID">
13636 <entry>Part2DPID</entry>
13637
13638 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13639 linkend="Distanceparts-DPID"/></entry>
13640
13641 <entry>Identifier of the distance measurement participant
13642 row which records data regarding <quote>the
13643 second</quote> of the individuals between which
13644 distance was measured.</entry>
13645 </row>
13646
13647 <row xml:id="Dists-Uncertain" xreflabel="Uncertain">
13648 <entry>Uncertain</entry>
13649
13650 <entry><xref linkend="DISTANCES"/>.<xref
13651 linkend="Distances-Uncertain"/></entry>
13652
13653 <entry>Whether or not the inter-familial distance was
13654 observed with certainty.</entry>
13655 </row>
13656
13657 <row xml:id="Dists-DPart1Role" xreflabel="DPart1Role">
13658 <entry>DPart1Role (Role in Follow of First Chimp)</entry>
13659
13660 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13661 linkend="Distanceparts-Role"/></entry>
13662
13663 <entry>Code for the role, i.e. mom, sib, infant, played
13664 by the individual designated as <quote>the
13665 first</quote> individual involved in the
13666 measurement.</entry>
13667 </row>
13668
13669 <row xml:id="Dists-Participant1" xreflabel="Partcipant1">
13670 <entry>Participant1</entry>
13671
13672 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13673 linkend="Distanceparts-Participant"/></entry>
13674
13675 <entry>The identifier or alternate identifier of the
13676 <quote>first</quote> individual.</entry>
13677 </row>
13678
13679 <row xml:id="Dists-DPart2Role" xreflabel="DPart2Role">
13680 <entry>DPart2Role (Role in Follow of Second Chimp)</entry>
13681
13682 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13683 linkend="Distanceparts-Role"/></entry>
13684
13685 <entry>Code for the role, i.e. mom, sib, infant, played by
13686 the individual designated as <quote>the second</quote>
13687 in the measurement.</entry>
13688 </row>
13689
13690 <row xml:id="Dists-Participant2" xreflabel="Partcipant2">
13691 <entry>Participant2</entry>
13692
13693 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13694 linkend="Distanceparts-Participant"/></entry>
13695
13696 <entry>The identifier or alternate identifier of the
13697 <quote>second</quote> individual.</entry>
13698 </row>
13699
13700 <row xml:id="Dists-Distance" xreflabel="Distance">
13701 <entry>Distance</entry>
13702
13703 <entry><xref linkend="DISTANCES"/>.<xref
13704 linkend="Distances-Distance"/></entry>
13705
13706 <entry>Code designating the distance between the 2
13707 individuals.</entry>
13708 </row>
13709
13710 </tbody>
13711 </tgroup>
13712 </informaltable>
13713
13714 </section>
13715
13716
13717 <section xml:id="DISTS-Usage-Guidelines">
13718 <title>DISTS Usage Guidelines</title>
13719
13720 <para>Only <literal>SELECT</literal> is allowed on
13721 DISTS. <literal>INSERT</literal>, <literal>UPDATE</literal>,
13722 and <literal>DELETE</literal> are not allowed.</para>
13723 </section>
13724 </section>
13725
13726 <section xml:id="FAMILY_DISTS" xreflabel="FAMILY_DISTS">
13727 <title>FAMILY_DISTS (Inter-Chimp Distance Measurements With the
13728 Focals Identified by Column)</title>
13729 <titleabbrev>FAMILY_DISTS (Inter-Chimp Distance Measurements,
13730 Focals Identified by Column)</titleabbrev>
13731
13732 <para>FAMILY_DISTS contains one row per
13733 <xref linkend="DISTANCES"/> row. FAMILY_DISTS provides a way to
13734 review recorded inter-familial distances in a way similar to the
13735 way data is recorded in the field. It is also useful for
13736 changing database content, since this is often done based on
13737 data recorded in the field.</para>
13738
13739 <note>
13740 <para>The FAMILY_DISTS view is neither particularly efficient
13741 nor always well suited to data analysis. Other views will
13742 very likely be faster and more appropriate when analyzing
13743 data.</para>
13744 </note>
13745
13746 <note>
13747 <para>The <xref linkend="Family_Dists-D_Momrole"/>,
13748 <xref linkend="Family_Dists-D_Infantrole"/>, and
13749 <xref linkend="Family_Dists-D_Sibrole"/> columns are not
13750 useful from a query standpoint but are, at present, needed
13751 when changing some database content; notably, but not
13752 exclusively, when inserting new rows.</para>
13753 </note>
13754
13755 <section xml:id="FAMILY_DISTS-Definition">
13756 <title>FAMILY_DISTS Definition</title>
13757
13758 <xi:include
13759 href="views/family_dists.xml"
13760 xmlns:xi="http://www.w3.org/2001/XInclude"/>
13761 </section>
13762
13763 <section xml:id="Family_Dists-Columns">
13764 <title>FAMILY_DISTS Columns</title>
13765
13766 <informaltable frame="topbot">
13767 <tgroup cols="3" colsep="0" rowsep="0">
13768 <colspec colnum="3" rowsep="1"/>
13769 <thead>
13770 <row rowsep="1">
13771 <entry>Column</entry>
13772 <entry>From</entry>
13773 <entry>Description</entry>
13774 </row>
13775 </thead>
13776
13777 <tbody>
13778 <row xml:id="Family_Dists-FollowID" xreflabel="FollowID">
13779 <entry>FollowID</entry>
13780
13781 <entry><xref linkend="FOLLOWS"/>.<xref
13782 linkend="Follows-FollowID"/></entry>
13783
13784 <entry>Identifier of the follow.</entry>
13785 </row>
13786
13787 <row xml:id="Family_Dists-IntID" xreflabel="IntID">
13788 <entry>IntID</entry>
13789
13790 <entry><xref linkend="EVENTS"/>.<xref
13791 linkend="Events-IntID"/></entry>
13792
13793 <entry>Identifier of the observation interval during
13794 which the inter-familial distance was recorded.</entry>
13795 </row>
13796
13797 <row xml:id="Family_Dists-DistID" xreflabel="DistID">
13798 <entry>DistID</entry>
13799
13800 <entry><xref linkend="DISTANCES"/>.<xref
13801 linkend="Distances-DistID"/></entry>
13802
13803 <entry>Identifier of the
13804 row recording inter-familial distance.</entry>
13805 </row>
13806
13807 <row xml:id="Family_Dists-D_MomDPID" xreflabel="D_MomDPID">
13808 <entry>D_MomDPID</entry>
13809
13810 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13811 linkend="Distanceparts-DPID"/></entry>
13812
13813 <entry>Identifier of the distance participant row
13814 which records distance data regarding the mother
13815 in the follow, or &null;.</entry>
13816 </row>
13817
13818 <row xml:id="Family_Dists-D_InfantDPID" xreflabel="D_InfantDPID">
13819 <entry>D_InfantDPID</entry>
13820
13821 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13822 linkend="Distanceparts-DPID"/></entry>
13823
13824 <entry>Identifier of the distance participant row
13825 which records distance data regarding the infant
13826 in the follow, or &null;.</entry>
13827 </row>
13828
13829 <row xml:id="Family_Dists-D_SibDPID" xreflabel="D_SibDPID">
13830 <entry>D_SibDPID</entry>
13831
13832 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13833 linkend="Distanceparts-DPID"/></entry>
13834
13835 <entry>Identifier of the distance participant row
13836 which records distance data regarding the sibling
13837 in the follow, or &null;.</entry>
13838 </row>
13839
13840 <row xml:id="Family_Dists-Date" xreflabel="Date">
13841 <entry>Date</entry>
13842
13843 <entry><xref linkend="FOLLOWS"/>.<xref
13844 linkend="Follows-Date"/></entry>
13845
13846 <entry>The date of the follow.</entry>
13847 </row>
13848
13849 <row xml:id="Family_Dists-Time" xreflabel="Time">
13850 <entry>Time</entry>
13851
13852 <entry><xref linkend="INTERVALS"/>.<xref
13853 linkend="Intervals-Time"/></entry>
13854
13855 <entry>The time of the interval.</entry>
13856 </row>
13857
13858 <row xml:id="Family_Dists-Mom" xreflabel="Mom">
13859 <entry>Mom</entry>
13860
13861 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13862 linkend="Followparts-ChimpID"/></entry>
13863
13864 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of the
13865 mother in the follow.</entry>
13866 </row>
13867
13868 <row xml:id="Family_Dists-Infant" xreflabel="Infant">
13869 <entry>Infant</entry>
13870
13871 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13872 linkend="Followparts-ChimpID"/></entry>
13873
13874 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of an
13875 infant in the follow.</entry>
13876 </row>
13877
13878 <row xml:id="Family_Dists-Infant2" xreflabel="Infant2">
13879 <entry>Infant2</entry>
13880
13881 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13882 linkend="Followparts-ChimpID"/></entry>
13883
13884 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
13885 second infant in the follow, or &null; if the infant
13886 is not a twin.</entry>
13887 </row>
13888
13889 <row xml:id="Family_Dists-Sib" xreflabel="Sib">
13890 <entry>Sib</entry>
13891
13892 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13893 linkend="Followparts-ChimpID"/></entry>
13894
13895 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
13896 sibling in the follow, or &null; if there is no
13897 sibling focal.</entry>
13898 </row>
13899
13900 <row xml:id="Family_Dists-Sib2" xreflabel="Sib2">
13901 <entry>Sib2</entry>
13902
13903 <entry><xref linkend="FOLLOWPARTS"/>.<xref
13904 linkend="Followparts-ChimpID"/></entry>
13905
13906 <entry>The <xref linkend="ChimpIDs-ChimpID"/> of a
13907 second sibling in the follow, or &null; if the sibling
13908 is not a twin.</entry>
13909 </row>
13910
13911 <row xml:id="Family_Dists-Uncertain" xreflabel="Uncertain">
13912 <entry>Uncertain</entry>
13913
13914 <entry><xref linkend="DISTANCES"/>.<xref
13915 linkend="Distances-Uncertain"/></entry>
13916
13917 <entry>Whether or not the distance was observed with
13918 certainty.</entry>
13919 </row>
13920
13921 <row xml:id="Family_Dists-D_Mom" xreflabel="D_Mom">
13922 <entry>D_Mom</entry>
13923
13924 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13925 linkend="Distanceparts-Participant"/></entry>
13926
13927 <entry>The identifier or alternate identifier of the mom,
13928 or &null; if the mother is not involved in the
13929 distance measurement.</entry>
13930 </row>
13931
13932 <row xml:id="Family_Dists-D_Momrole" xreflabel="D_Momrole">
13933 <entry>D_Momrole</entry>
13934
13935 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13936 linkend="Distanceparts-Role"/></entry>
13937
13938 <entry>The <xref linkend="Distanceparts-Role"/> of the
13939 mother in the inter-familial distance measurement.
13940 See above regards inter-familial distance measurement
13941 roles.</entry>
13942 </row>
13943
13944 <row xml:id="Family_Dists-D_Infant" xreflabel="D_Infant">
13945 <entry>D_Infant</entry>
13946
13947 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13948 linkend="Distanceparts-Participant"/></entry>
13949
13950 <entry>The identifier or alternate identifier of the
13951 infant, or &null; when the infant is not involved in the
13952 distance measurement.</entry>
13953 </row>
13954
13955 <row xml:id="Family_Dists-D_Infantrole" xreflabel="D_Infantrole">
13956 <entry>D_Infantrole</entry>
13957
13958 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13959 linkend="Distanceparts-Role"/></entry>
13960
13961 <entry>The <xref linkend="Distanceparts-Role"/> of the
13962 infant in the inter-familial distance measurement.
13963 See above regards inter-familial distance measurement
13964 roles.</entry>
13965 </row>
13966
13967 <row xml:id="Family_Dists-D_Sib" xreflabel="D_Sib">
13968 <entry>D_Sib</entry>
13969
13970 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13971 linkend="Distanceparts-Participant"/></entry>
13972
13973 <entry>The identifier or alternate identifier of the
13974 sibling, or &null; when the sibling is not involved in
13975 the distance measurement.</entry>
13976 </row>
13977
13978 <row xml:id="Family_Dists-D_Sibrole" xreflabel="D_Sibrole">
13979 <entry>D_Sibrole</entry>
13980
13981 <entry><xref linkend="DISTANCEPARTS"/>.<xref
13982 linkend="Distanceparts-Role"/></entry>
13983
13984 <entry>The <xref linkend="Distanceparts-Role"/> of the
13985 sibling in the inter-familial distance measurement.
13986 See above regards inter-familial distance measurement
13987 roles.</entry>
13988 </row>
13989
13990 <row xml:id="Family_Dists-Distance" xreflabel="Distance">
13991 <entry>Distance</entry>
13992
13993 <entry><xref linkend="DISTANCES"/>.<xref
13994 linkend="Distances-Distance"/></entry>
13995
13996 <entry>Code designating the distance between the
13997 individuals.</entry>
13998 </row>
13999
14000 <row xml:id="Family_Dists-I_Comment" xreflabel="I_Comment">
14001 <entry>I_Comment (Interval Comment)</entry>
14002
14003 <entry><xref linkend="INTERVALS"/>.<xref
14004 linkend="Intervals-Comment"/></entry>
14005
14006 <entry>Textual remarks regarding the interval.</entry>
14007 </row>
14008
14009 </tbody>
14010 </tgroup>
14011 </informaltable>
14012
14013 </section>
14014
14015
14016 <section xml:id="FAMILY_DISTS-Usage-Guidelines">
14017 <title>FAMILY_DISTS Usage Guidelines</title>
14018
14019 <para>Altering the FAMILY_DISTS view alters the content of the
14020 underlying <xref linkend="DISTANCES"/> and
14021 <xref linkend="DISTANCEPARTS"/> tables in the fashion
14022 described below. The <xref linkend="INTERVALS"/> and related
14023 <xref linkend="FOLLOWS"/> and <xref linkend="FOLLOWPARTS"/>
14024 rows must exist; the content of these tables is never
14025 altered.</para>
14026
14027 <section xml:id="Family_Dists-Insert">
14028 <title>INSERT</title>
14029
14030 <para>Inserting a row into the FAMILY_DISTS view inserts
14031 a row into the <xref linkend="DISTANCES"/> table, as
14032 expected.</para>
14033
14034 <para>When inserting into FAMILY_DISTS the interval of the
14035 follow must be specified. The interval may be specified in
14036 either or both of the following 2 ways:</para>
14037
14038 <itemizedlist>
14039 <listitem>
14040 <para>A <xref linkend="Family_Dists-IntID"/> may be
14041 supplied.</para>
14042 </listitem>
14043
14044 <listitem>
14045 <para>A <xref linkend="Family_Dists-Time"/> may be
14046 supplied and the follow specified. The follow may be
14047 specified in either or both of the following 2
14048 ways:</para>
14049
14050 <itemizedlist>
14051 <listitem>
14052 <para>A <xref linkend="Family_Dists-FollowID"/> may be
14053 supplied.</para>
14054 </listitem>
14055
14056 <listitem>
14057 <para><xref linkend="Family_Dists-Date"/>,
14058 <xref linkend="Family_Dists-Mom"/> and,
14059 <xref linkend="Family_Dists-Infant"/>
14060 values <emphasis>all</emphasis> may be supplied.</para>
14061
14062 <note>
14063 <para>See <link linkend="follow_intervals-twins">the
14064 note regards twins</link>
14065 when <link linkend="Follow_Intervals-Insert">inserting
14066 into FOLLOW_INTERVALS</link>.</para>
14067 </note>
14068 </listitem>
14069 </itemizedlist>
14070 </listitem>
14071 </itemizedlist>
14072
14073 <caution>
14074 <para>FAMILY_DISTS inserts rows into the database only
14075 when there is a <xref linkend="INTERVALS"/> row that
14076 matches the above selection criteria. If no row matches
14077 the database content is not altered. Note that no row
14078 will match if conflicting information is supplied.</para>
14079 </caution>
14080
14081 <note>
14082 <para>When inserting into FAMILY_DISTS it is not
14083 recommended to set any of the
14084 <xref linkend="Family_Dists-DistID"/>,
14085 <xref linkend="Family_Dists-D_MomDPID"/>,
14086 <xref linkend="Family_Dists-D_InfantDPID"/> or,
14087 <xref linkend="Family_Dists-D_SibDPID"/> values.
14088 Omitting these columns or supplying &null; values will
14089 allow the system to automatically generate ids.</para>
14090 </note>
14091 </section>
14092
14093 <section xml:id="Family_Dists-Update">
14094 <title>Update</title>
14095
14096 <para>Updating the FAMILY_DISTS view updates
14097 <xref linkend="DISTANCES"/>, as expected.</para>
14098
14099 <para>Updating FAMILY_DISTS can update, insert into, or
14100 delete rows from <xref linkend="DISTANCEPARTS"/>.</para>
14101
14102 <note>
14103 <para>The examples below explicitly specify an
14104 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
14105 value. This is solely for the purpose of brevity. Any
14106 valid
14107 <code>WHERE</code> clause could be used instead to
14108 designate the desired row in
14109 <xref linkend="DISTANCES"/>.</para>
14110 </note>
14111
14112 <note>
14113 <para>Although the initial examples show how to insert and
14114 delete individual <xref linkend="DISTANCEPARTS"/> rows
14115 this is never done, at least not without other changes,
14116 because <xref linkend="DISTANCEPARTS"/> rows always come
14117 in pairs. An example combining insertion and deletion
14118 follows.</para>
14119 </note>
14120
14121 <para>If the old values for a mom, infant, sib or nonfocal
14122 <xref linkend="DISTANCEPARTS"/> row are not &null; and the new
14123 values are all &null; then the old row is deleted.<footnote>
14124
14125 <para>Since every distance measurement is between two
14126 focals there is not a lot of point in deleting a focal's
14127 row unless another focal's row is inserted -- at which
14128 point you may as well have changed the chimpid of the
14129 focal and re-used the existing row.</para>
14130
14131 </footnote> The following example removes the mother as a
14132 participant in the inter-familial distance measurement with
14133 a
14134 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
14135 of <literal>1234</literal>:</para>
14136
14137 <example>
14138 <title>Deleting The Mother's DISTANCEPARTS Row</title>
14139
14140 <literallayout>
14141 <code>UPDATE family_dists
14142 SET d_mom = NULL
14143 , d_momrole = NULL
14144 , d_momdpid = NULL
14145 WHERE distid = 1234;</code></literallayout>
14146 </example>
14147
14148 <para>If the old values for a mom, infant, sib, or nonfocal
14149 are &null;, i.e. if the mom, infant, sib, or nonfocal has no
14150 <xref linkend="DISTANCEPARTS"/> row then a new
14151 <xref linkend="DISTANCEPARTS"/> row can be inserted by
14152 supplying values. The following example adds, to the
14153 inter-familial distance measurement with a
14154 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
14155 of <literal>1234</literal>, assuming she is not already one
14156 of the individuals involved in the inter-familial distance
14157 measurement, the mother.</para>
14158
14159 <example>
14160 <title>Inserting A DISTANCEPARTS Row For The Mother</title>
14161
14162 <literallayout>
14163 <code>UPDATE family_dists
14164 SET d_mom = 'GA'
14165 , d_momrole = 'M' -- M is the mother role
14166 WHERE distid = 1234;</code></literallayout>
14167 </example>
14168
14169 <para>If old values exist, they are replaced by new values.
14170 Assuming the infant <literal>JOE</literal> is involved in
14171 the inter-familial distance measurement with an
14172 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
14173 of <literal>1234</literal>, the following example changes
14174 the infant to <literal>JAK</literal>:</para>
14175
14176 <example>
14177 <title>Changing A Inter-Familial Distance Measurement
14178 Participant In A DISTANCEPARTS Row</title>
14179
14180 <literallayout>
14181 <code>UPDATE family_dists
14182 SET d_infant = 'JAK'
14183 WHERE distid = 1234;</code></literallayout>
14184 </example>
14185
14186 <note>
14187 <para>The <xref linkend="ChimpIDs-ChimpID"/> values need
14188 not correspond to the roles the individuals play in the
14189 follow because data is associated with chimp id values,
14190 not focal roles. The presence of focal roles in the
14191 column names is, in some sense, artificial. For example,
14192 there are two ways to change the infant
14193 (<literal>INF</literal>) to a sibling
14194 (<literal>SB</literal>) in the inter-familial distance
14195 measurement with an
14196 <xref linkend="DISTANCES"/>.<xref linkend="Distances-DistID"/>
14197 of <literal>1234</literal>. The first is to delete the
14198 <xref linkend="DISTANCEPARTS"/> row for the infant and
14199 insert a new <xref linkend="DISTANCEPARTS"/> row for the
14200 sibling:</para>
14201
14202 <example>
14203 <title>Deleting the Infant's DISTANCEPARTS row and
14204 Inserting a New DISTANCEPARTS Row for the Sibling
14205 </title>
14206 <titleabbrev>Deleting Infant's DISTANCEPARTS row and
14207 Inserting a New Row for the Sibling</titleabbrev>
14208
14209 <literallayout>
14210 <code>UPDATE family_dists
14211 SET d_infant = NULL
14212 , d_infantrole = NULL
14213 , d_infantdpid = NULL
14214 , d_sib = 'SB'
14215 , d_sibrole = 'S' -- S is the sibling role
14216 WHERE dpid = 1234;</code></literallayout>
14217 </example>
14218
14219 <para>Deleting and re-adding rows is somewhat inefficient
14220 and error prone. It is probably better to simply replace
14221 the infant's <xref linkend="ChimpIDs-ChimpID"/> value with
14222 the siblings. Simply changing the
14223 <xref linkend="DISTANCEPARTS"/>.<xref
14224 linkend="Distanceparts-Participant"/>
14225 value is enough; being the sibling is a property of a
14226 ChimpID with respect to a follow and, again, when updating
14227 the database there is no correspondence between the column
14228 names and the roles played by the individual chimps. The
14229 following is sufficient to re-use the exiting
14230 <xref linkend="DISTANCEPARTS"/> row and change the infant's
14231 <xref linkend="ChimpIDs-ChimpID"/> value to the
14232 siblings:</para>
14233
14234 <example>
14235 <title>Changing an Infant's DISTANCEPARTS row Into A
14236 DISTANCEPARTS Row for the Sibling </title>
14237
14238 <literallayout>
14239 <code>UPDATE family_dists
14240 SET d_infant = 'SB' -- SB is the sibling
14241 , d_infantrole = 'S' -- S is the sibling role
14242 WHERE distid = 1234;</code></literallayout>
14243 </example>
14244
14245 <para>When the result is queried <literal>SB</literal>
14246 will show up as a sibling, not an infant.</para>
14247 </note>
14248
14249 <para>It is an error to attempt to update the values of any
14250 columns not derived from the <xref linkend="DISTANCES"/> or
14251 <xref linkend="DISTANCEPARTS"/> tables.</para>
14252
14253 <para>When updated, FAMILY_DISTS raises a notice containing
14254 the number of rows altered. A row is counted only once,
14255 when updating the row changes the database content in any
14256 way.</para>
14257 </section>
14258
14259 <section xml:id="Family_Dists-Delete">
14260 <title>Delete</title>
14261
14262 <para>Deleting rows from the FAMILY_DISTS view deletes rows
14263 from <xref linkend="DISTANCES"/> and
14264 <xref linkend="DISTANCEPARTS"/>, as expected.</para>
14265 </section>
14266 </section>
14267 </section>
14268
14269 </section>
14270
14271 <section xml:id="group_views">
14272 <title>&group_section; Views</title>
14273
14274 <para><remark>To be filled in.</remark></para>
14275
14276 </section>
14277 </chapter>
14278
14279 <chapter xml:id="The_Gombe-MI-Functions">
14280
14281 <title>The Gombe-MI Functions</title>
14282
14283 <section xml:id="query-functions">
14284 <title>Query Functions</title>
14285
14286 <para>The functions in this section are suitable for use in SQL
14287 queries.</para>
14288
14289 <refentry xml:id="followfunc" xreflabel="followfunc()">
14290 <refmeta>
14291 <refentrytitle>followfunc</refentrytitle>
14292 </refmeta>
14293
14294 <refnamediv>
14295 <refname>followfunc</refname>
14296 <refpurpose>return the function (role) of a chimp in a
14297 follow</refpurpose>
14298 </refnamediv>
14299
14300 <refsynopsisdiv>
14301 <funcsynopsis>
14302 <funcprototype>
14303 <funcdef>
14304 <type>VARCHAR</type>
14305 <function>followfunc</function>
14306 </funcdef>
14307 <paramdef>
14308 <type>INT</type>
14309 <parameter>followid</parameter>
14310 </paramdef>
14311 <paramdef>
14312 <type>VARCHAR(&gmi_animid_len;)</type>
14313 <parameter>chimpid</parameter>
14314 </paramdef>
14315 </funcprototype>
14316 </funcsynopsis>
14317 </refsynopsisdiv>
14318
14319 <refsection xml:id="followfunc_input">
14320 <title>Input</title>
14321 <refsection xml:id="followfunc_followid">
14322 <title>followid</title>
14323
14324 <para>A
14325 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-FollowID"/>
14326 value.</para>
14327 </refsection>
14328
14329 <refsection xml:id="followfunc_chimpid">
14330 <title>chimpid</title>
14331
14332 <para>A
14333 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14334 value.</para>
14335 </refsection>
14336 </refsection>
14337
14338 <refsection xml:id="followfunc_description">
14339 <title>Description</title>
14340
14341 <para>A function which returns the function (role,
14342 i.e. <literal>&gmi_mom;</literal>, <literal>&gmi_infant;</literal>,
14343 or <literal>&gmi_sib;</literal>) of a chimpid in a follow,
14344 or <literal>&gmi_nonfocal;</literal> if the chimp is not a focal
14345 in the follow.</para>
14346
14347 <para>A &null; is returned if any of the input arguments are
14348 &null;.</para>
14349
14350 </refsection>
14351 </refentry>
14352
14353 <refentry xml:id="followrole" xreflabel="followrole()">
14354 <refmeta>
14355 <refentrytitle>followrole</refentrytitle>
14356 </refmeta>
14357
14358 <refnamediv>
14359 <refname>followrole</refname>
14360 <refpurpose>return the role of a chimp in a
14361 follow</refpurpose>
14362 </refnamediv>
14363
14364 <refsynopsisdiv>
14365 <funcsynopsis>
14366 <funcprototype>
14367 <funcdef>
14368 <type>VARCHAR</type>
14369 <function>followrole</function>
14370 </funcdef>
14371 <paramdef>
14372 <type>INT</type>
14373 <parameter>followid</parameter>
14374 </paramdef>
14375 <paramdef>
14376 <type>VARCHAR(&gmi_animid_len;)</type>
14377 <parameter>chimpid</parameter>
14378 </paramdef>
14379 </funcprototype>
14380 </funcsynopsis>
14381 </refsynopsisdiv>
14382
14383 <refsection xml:id="followrole_input">
14384 <title>Input</title>
14385 <refsection xml:id="followrole_followid">
14386 <title>followid</title>
14387
14388 <para>A
14389 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-FollowID"/>
14390 value.</para>
14391 </refsection>
14392
14393 <refsection xml:id="followrole_chimpid">
14394 <title>chimpid</title>
14395
14396 <para>A
14397 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14398 value.</para>
14399 </refsection>
14400 </refsection>
14401
14402 <refsection xml:id="followrole_description">
14403 <title>Description</title>
14404
14405 <para>A function which returns the role,
14406 i.e. <literal>&gmi_mom;</literal>, <literal>&gmi_infant;</literal>,
14407 or <literal>&gmi_sib;</literal> of a chimpid in a follow,
14408 or <literal>&gmi_nonfocal;</literal> if the chimp is not a focal
14409 in the follow.</para>
14410
14411 <para>Note that the role, returned by <code>followrole()</code>,
14412 is able to distinguish twins from other infants or siblings
14413 whereas the function, returned by <code>followfunc()</code>, does
14414 not make this distinction.</para>
14415
14416 <para>A &null; is returned if any of the input arguments are
14417 &null;.</para>
14418
14419 </refsection>
14420 </refentry>
14421 </section>
14422 <section xml:id="utliity-functions">
14423 <title>Utility Functions</title>
14424
14425 <para>The functions in this section are intended for use within
14426 programs or other code. The typical user will not have need of
14427 these functions.</para>
14428
14429 <refentry xml:id="add_social_partners" xreflabel="add_social_partners()">
14430 <refmeta>
14431 <refentrytitle>add_social_partners</refentrytitle>
14432 </refmeta>
14433
14434 <refnamediv>
14435 <refname>add_social_partners</refname>
14436 <refpurpose>Ensure that all social interaction partners are in
14437 the group composition data</refpurpose>
14438 </refnamediv>
14439
14440 <refsynopsisdiv>
14441 <funcsynopsis>
14442 <funcprototype>
14443 <funcdef>
14444 <type>INT</type>
14445 <function>add_social_partners</function>
14446 </funcdef>
14447 <paramdef>
14448 <type>VARCHAR(&gmi_animid_len;)</type>
14449 <parameter>chimpid</parameter>
14450 </paramdef>
14451 <paramdef>
14452 <type>BIGINT</type>
14453 <parameter>rgid</parameter>
14454 </paramdef>
14455 </funcprototype>
14456 </funcsynopsis>
14457 </refsynopsisdiv>
14458
14459 <refsection xml:id="add_social_partners_input">
14460 <title>Input</title>
14461 <refsection xml:id="add_social_partners_chimpid">
14462 <title>chimpid</title>
14463
14464 <para>A
14465 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14466 value of a chimp in a group composition who may have social
14467 partners.</para>
14468 </refsection>
14469 <refsection xml:id="add_social_partners_rgid">
14470 <title>rgid</title>
14471
14472 <para>A
14473 <xref linkend="RAW_GROUPS"/>.<xref linkend="Raw_Groups-RGID"/>
14474 value identifying the group composition.</para>
14475 </refsection>
14476 </refsection>
14477
14478 <refsection xml:id="add_social_partners_description">
14479 <title>Description</title>
14480
14481 <para><function>add_social_partners</function> adds all
14482 non-<literal>&gmi_unk_animid;</literal> social partners, and the
14483 mother's of young infant social partners and the young infants
14484 of mother social partners, of the specified chimp to the group
14485 composition data identified by the <code>rgid</code>. Social
14486 partners are those individuals (or baboons<footnote>
14487
14488 <para>While baboons are not individually identified
14489 anywhere the <xref linkend="RAW_GROUPS"/> table does have
14490 a flag indicating whether baboons are present.</para>
14491
14492 </footnote>) which interact with the given
14493 individual in any way during the time period starting with the
14494 time of the group composition (inclusive of endpoint) and ending
14495 with the time of the follow's next group composition (exclusive
14496 of endpoint). The group composition is unchanged if all social
14497 partners are already in the group composition.</para>
14498
14499 <para><function><xref linkend="add_social_partners"/></function>
14500 calls <function><xref linkend="mom_in_gc"/></function>
14501 and <function><xref linkend="infants_in_gc"/></function> on the
14502 added social partners to ensure that young infants are in the
14503 group composition with their mothers and vice versa.</para>
14504
14505 <caution>
14506 <para>This function does not check it's arguments. It assumes
14507 that the supplied chimpid is in the supplied group
14508 composition.</para>
14509 </caution>
14510
14511 <para>When inserting a <xref linkend="RAW_GROUPMEMBERS"/> row
14512 the <xref linkend="Raw_Groupmembers-ChimpID"/> value used is the
14513 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
14514 of a social partner
14515
14516 <footnote>
14517 <para>This matters in the case of twins.</para>
14518 </footnote>, the
14519 <xref linkend="Raw_Groupmembers-Origin"/> value used is
14520 always <literal>&gmi_automatic_origin;</literal>, and the
14521 <xref linkend="Raw_Groupmembers-Uncertain"/> value always
14522 &false;</para>
14523
14524 <para>This function always returns <literal>0</literal>.</para>
14525
14526 </refsection>
14527 </refentry>
14528
14529 <refentry xml:id="delete_gc" xreflabel="delete_gc()">
14530 <refmeta>
14531 <refentrytitle>delete_gc</refentrytitle>
14532 </refmeta>
14533
14534 <refnamediv>
14535 <refname>delete_gc</refname>
14536 <refpurpose>Delete a follow's group composition data</refpurpose>
14537 </refnamediv>
14538
14539 <refsynopsisdiv>
14540 <funcsynopsis>
14541 <funcprototype>
14542 <funcdef>
14543 <type>BOOLEAN</type>
14544 <function>delete_gc</function>
14545 </funcdef>
14546 <paramdef>
14547 <type>DATE</type>
14548 <parameter>followdate</parameter>
14549 </paramdef>
14550 <paramdef>
14551 <type>VARCHAR(&gmi_animid_len;)</type>
14552 <parameter>chimpid</parameter>
14553 </paramdef>
14554 </funcprototype>
14555 <funcprototype>
14556 <funcdef>
14557 <type>BOOLEAN</type>
14558 <function>delete_gc</function>
14559 </funcdef>
14560 <paramdef>
14561 <type>INT</type>
14562 <parameter>followid</parameter>
14563 </paramdef>
14564 </funcprototype>
14565 </funcsynopsis>
14566 </refsynopsisdiv>
14567
14568 <refsection xml:id="delete_gc_input">
14569 <title>Input</title>
14570
14571 <para>The follow for which group composition should be deleted
14572 may be designated either by supplying the date and mother of
14573 the follow or by supplying the id of the follow.</para>
14574
14575 <refsection xml:id="delete_gc_followdate">
14576 <title>followdate</title>
14577
14578 <para>The date of the follow for which group composition
14579 should be deleted.</para>
14580 </refsection>
14581 <refsection xml:id="delete_gc_chimpid">
14582 <title>chimpid</title>
14583
14584 <para>The
14585 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14586 of the mother in the follow for which group composition
14587 should be deleted.</para>
14588 </refsection>
14589
14590 <refsection xml:id="delete_gc_followid">
14591 <title>followid</title>
14592
14593 <para>The
14594 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-FollowID"/>
14595 of the follow for which group composition should be
14596 deleted.</para>
14597 </refsection>
14598 </refsection>
14599
14600 <refsection xml:id="delete_gc_description">
14601 <title>Description</title>
14602
14603 <para><function>delete_gc</function> deletes all of a follow's
14604 related group composition information -- the related rows in
14605 <xref linkend="RAW_GROUPS"/>,
14606 <xref linkend="RAW_GROUPMEMBERS"/>, <xref linkend="GROUPS"/>,
14607 and <xref linkend="GROUPMEMBERS"/> are deleted.</para>
14608
14609 <note>
14610 <para>This function orders the deletes in such a way that
14611 performance may be improved by orders of magnitude. It is
14612 therefore the preferred way to delete group
14613 composition.</para>
14614 </note>
14615
14616 <para>This function returns &true; if the supplied follow
14617 exists and group comp rows are deleted and &false;
14618 otherwise.</para>
14619
14620 <para>The following example demonstrates how to delete all of
14621 the automatically generated group compositions.</para>
14622
14623 <example>
14624 <title>Deleting Automatically Generated Group
14625 Compositions</title>
14626
14627 <para><literallayout><code>SELECT delete_gc(follows.followid)
14628 FROM follows
14629 WHERE EXISTS (SELECT 1
14630 FROM intervals
14631 JOIN sheets
14632 ON (sheets.sheetid = intervals.sheetid)
14633 JOIN fieldfollows
14634 ON (fieldfollows.ffid = sheets.ffid)
14635 WHERE intervals.followid = follows.followid
14636 AND fieldfollows.gcstatus = '&gmi_automatic_gcstatus;');</code></literallayout>
14637 </para>
14638 </example>
14639
14640 </refsection>
14641 </refentry>
14642
14643 <refentry xml:id="infants_in_gc" xreflabel="infants_in_gc()">
14644 <refmeta>
14645 <refentrytitle>infants_in_gc</refentrytitle>
14646 </refmeta>
14647
14648 <refnamediv>
14649 <refname>infants_in_gc</refname>
14650 <refpurpose>Ensure that the (biological or adopted) young
14651 infants of a mom are the group composition data</refpurpose>
14652 </refnamediv>
14653
14654 <refsynopsisdiv>
14655 <funcsynopsis>
14656 <funcprototype>
14657 <funcdef>
14658 <type>BOOLEAN</type>
14659 <function>infants_in_gc</function>
14660 </funcdef>
14661 <paramdef>
14662 <type>VARCHAR(&gmi_animid_len;)</type>
14663 <parameter>chimpid</parameter>
14664 </paramdef>
14665 <paramdef>
14666 <type>BIGINT</type>
14667 <parameter>rgid</parameter>
14668 </paramdef>
14669 <paramdef>
14670 <type>DATE</type>
14671 <parameter>date</parameter>
14672 </paramdef>
14673 </funcprototype>
14674 </funcsynopsis>
14675 </refsynopsisdiv>
14676
14677 <refsection xml:id="infants_in_gc_input">
14678 <title>Input</title>
14679 <refsection xml:id="infants_in_gc_chimpid">
14680 <title>chimpid</title>
14681
14682 <para>A
14683 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14684 value of a possible (biological or adoptive) mother.</para>
14685
14686 <para>There are no restrictions regards sex or age of the
14687 given chimp.<footnote>
14688
14689 <para>In theory, any individual can adopt. Regardless,
14690 the caller should not need to worry about such
14691 details.</para>
14692
14693 </footnote></para>
14694 </refsection>
14695 <refsection xml:id="infants_in_gc_rgid">
14696 <title>rgid</title>
14697
14698 <para>A
14699 <xref linkend="RAW_GROUPS"/>.<xref linkend="Raw_Groups-RGID"/>
14700 value identifying a group composition.</para>
14701 </refsection>
14702 <refsection xml:id="infants_in_gc_date">
14703 <title>date</title>
14704
14705 <para>The date of the group composition.</para>
14706 </refsection>
14707 </refsection>
14708
14709 <refsection xml:id="infants_in_gc_description">
14710 <title>Description</title>
14711
14712 <para><function>infants_in_gc</function> adds the (biological or
14713 adopted) infants of a possible mother identified
14714 by <code>chimpid</code> to the group composition data identified
14715 by the <code>rgid</code> when the infant is less than
14716 &gmi_min_alone_age; old as of the date supplied in
14717 the <code>date</code> argument and in the study population and
14718 the possible mom is either the biological mother or an adoptive
14719 mother and the adoption occurred on or before the given date and
14720 the infant has not been adopted subsequently (but before the
14721 given date). The group composition is unchanged when the infant
14722 is already in the group composition.</para>
14723
14724 <caution>
14725 <para>Because adoptions can happen at any time during a day,
14726 when the given group composition date is the date of adoption
14727 the infant is added to all group compositions where either
14728 mother is found.</para>
14729 </caution>
14730
14731 <caution>
14732 <para>This function does not check it's arguments. It assumes
14733 that the supplied date is the date of the supplied group
14734 composition and that the supplied chimpid is in the supplied
14735 group composition.</para>
14736 </caution>
14737
14738 <para>When inserting a <xref linkend="RAW_GROUPMEMBERS"/> row
14739 the <xref linkend="Raw_Groupmembers-ChimpID"/> value used is the
14740 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
14741 of the (biological or adopted) infant
14742
14743 <footnote>
14744 <para>This matters in the case of twins.</para>
14745 </footnote>, the
14746 <xref linkend="Raw_Groupmembers-Origin"/> value used is
14747 always <literal>&gmi_automatic_origin;</literal>, and the
14748 <xref linkend="Raw_Groupmembers-Uncertain"/> value always
14749 &false;</para>
14750
14751 <para>A &true; value is returned if a row for any infant is
14752 added to <xref linkend="RAW_GROUPMEMBERS"/>, &false; is returned
14753 if not.</para>
14754
14755 </refsection>
14756 </refentry>
14757
14758 <refentry xml:id="infer_gc" xreflabel="infer_gc()">
14759 <refmeta>
14760 <refentrytitle>infer_gc</refentrytitle>
14761 </refmeta>
14762
14763 <refnamediv>
14764 <refname>infer_gc</refname>
14765 <refpurpose>Infer group composition from social
14766 relationships</refpurpose>
14767 </refnamediv>
14768
14769 <refsynopsisdiv>
14770 <funcsynopsis>
14771 <funcprototype>
14772 <funcdef>
14773 <type>BOOLEAN</type>
14774 <function>infer_gc</function>
14775 </funcdef>
14776 <paramdef>
14777 <type>DATE</type>
14778 <parameter>followdate</parameter>
14779 </paramdef>
14780 <paramdef>
14781 <type>VARCHAR(&gmi_animid_len;)</type>
14782 <parameter>chimpid</parameter>
14783 </paramdef>
14784 </funcprototype>
14785 <funcprototype>
14786 <funcdef>
14787 <type>BOOLEAN</type>
14788 <function>infer_gc</function>
14789 </funcdef>
14790 <paramdef>
14791 <type>INT</type>
14792 <parameter>followid</parameter>
14793 </paramdef>
14794 </funcprototype>
14795 </funcsynopsis>
14796 </refsynopsisdiv>
14797
14798 <refsection xml:id="infer_gc_input">
14799 <title>Input</title>
14800
14801 <para>The follow for which group composition should be inferred
14802 may be designated either by supplying the date and mother of
14803 the follow or by supplying the id of the follow.</para>
14804
14805 <refsection xml:id="infer_gc_followdate">
14806 <title>followdate</title>
14807
14808 <para>The date of the follow for which group composition
14809 should be inferred.</para>
14810 </refsection>
14811 <refsection xml:id="infer_gc_chimpid">
14812 <title>chimpid</title>
14813
14814 <para>The
14815 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14816 of the mother in the follow for which group composition
14817 should be inferred.</para>
14818 </refsection>
14819
14820 <refsection xml:id="infer_gc_followid">
14821 <title>followid</title>
14822
14823 <para>The
14824 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-FollowID"/>
14825 of the follow for which group composition should be
14826 inferred.</para>
14827 </refsection>
14828 </refsection>
14829
14830 <refsection xml:id="infer_gc_description">
14831 <title>Description</title>
14832
14833 <para><function>infer_gc</function> adds all
14834 non-<literal>&gmi_unk_animid;</literal> social partners,
14835 including baboons, and the mother's of young infant social
14836 partners and the young infants of mother social partners, of
14837 the focals of the specified follow to the group composition
14838 tables. It does so by first ensuring that the focals are in
14839 the group composition and then calling
14840 <xref linkend="add_social_partners"/> and
14841 <xref linkend="infants_in_gc"/> on all of the focals. Social
14842 interaction with baboons is also checked for. See the
14843 documentation of <xref linkend="add_social_partners"/> for
14844 further information.</para>
14845
14846 <tip>
14847 <para>This function does not remove any data from the group
14848 composition tables. If an existing group composition is to
14849 be re-inferred based on changes to database content the old
14850 group composition data must first be deleted.</para>
14851 </tip>
14852
14853 <para>It is an error to attempt to infer group composition
14854 where group composition already exists -- as determined by
14855 whether
14856 <xref linkend="FIELDFOLLOWS"/>.<xref linkend="Fieldfollows-GCStatus"/>
14857 is &null;</para>
14858
14859 <para>The group compositions, the <xref linkend="RAW_GROUPS"/>
14860 rows, are created at intervals of &gmi_gc_interval;, starting
14861 at the time of the first behavioral observation, the first
14862 <xref linkend="INTERVALS"/>.<xref linkend="Intervals-Time"/>
14863 value. Periods of no observation, periods during which there
14864 are no <xref linkend="INTERVALS"/> rows, lasting
14865 &gmi_gc_reset_interval; or longer cause a new set group
14866 compositions to start beginning at the time of the next
14867 observation, at the time of the next
14868 <xref linkend="INTERVALS"/>. <xref linkend="Intervals-Time"/>
14869 value.</para>
14870
14871 <para>This function returns &true; if the supplied follow
14872 exists and group comp rows were created and &false;
14873 otherwise.</para>
14874
14875 <para>The following example demonstrates how to infer group
14876 composition of all the follows which have none. All of the
14877 <xref linkend="INTERVALS"/> rows of any follow having a group
14878 composition have a <xref linkend="Intervals-GID"/> value.
14879 Those with no group composition have a &null;
14880 <xref linkend="Intervals-GID"/> value, and this is used to
14881 identify all the follows with no group composition.</para>
14882
14883 <example>
14884 <title>Inferring the group composition of follows that have
14885 none</title>
14886
14887 <para><literallayout><code>SELECT infer_gc(follows.followid)
14888 FROM follows
14889 WHERE NOT EXISTS (SELECT 1
14890 FROM intervals
14891 WHERE intervals.followid = follows.followid
14892 AND intervals.gid IS NOT NULL);</code></literallayout>
14893 </para>
14894 </example>
14895
14896 </refsection>
14897 </refentry>
14898
14899 <refentry xml:id="mom_in_gc" xreflabel="mom_in_gc()">
14900 <refmeta>
14901 <refentrytitle>mom_in_gc</refentrytitle>
14902 </refmeta>
14903
14904 <refnamediv>
14905 <refname>mom_in_gc</refname>
14906 <refpurpose>Ensure that the (biological or adoptive) mother of a
14907 young chimp, and all the mom's young infants, are in the group
14908 composition data</refpurpose>
14909 </refnamediv>
14910
14911 <refsynopsisdiv>
14912 <funcsynopsis>
14913 <funcprototype>
14914 <funcdef>
14915 <type>BOOLEAN</type>
14916 <function>mom_in_gc</function>
14917 </funcdef>
14918 <paramdef>
14919 <type>VARCHAR(&gmi_animid_len;)</type>
14920 <parameter>chimpid</parameter>
14921 </paramdef>
14922 <paramdef>
14923 <type>BIGINT</type>
14924 <parameter>rgid</parameter>
14925 </paramdef>
14926 <paramdef>
14927 <type>DATE</type>
14928 <parameter>date</parameter>
14929 </paramdef>
14930 </funcprototype>
14931 </funcsynopsis>
14932 </refsynopsisdiv>
14933
14934 <refsection xml:id="mom_in_gc_input">
14935 <title>Input</title>
14936 <refsection xml:id="mom_in_gc_chimpid">
14937 <title>chimpid</title>
14938
14939 <para>A
14940 <xref linkend="CHIMPIDS"/>.<xref linkend="ChimpIDs-ChimpID"/>
14941 value of a possible infant.</para>
14942
14943 <para>Any <quote>in-group</quote>
14944 <xref linkend="ChimpIDs-ChimpID"/> may be supplied. The
14945 function performs all necessary filtering regards age,
14946 existence of mother, and so forth.</para>
14947 </refsection>
14948 <refsection xml:id="mom_in_gc_rgid">
14949 <title>rgid</title>
14950
14951 <para>A
14952 <xref linkend="RAW_GROUPS"/>.<xref linkend="Raw_Groups-RGID"/>
14953 value identifying a group composition.</para>
14954 </refsection>
14955 <refsection xml:id="mom_in_gc_date">
14956 <title>date</title>
14957
14958 <para>The date of the group composition.</para>
14959 </refsection>
14960 </refsection>
14961
14962 <refsection xml:id="mom_in_gc_description">
14963 <title>Description</title>
14964
14965 <para><function>mom_in_gc</function> adds the (biological or
14966 adoptive) mother, as well as all of the mother's young infants,
14967 of the chimp identified by <code>chimpid</code> to the group
14968 composition data identified by the <code>rgid</code> when the
14969 chimp is less than &gmi_min_alone_age; old as of the date
14970 supplied in the <code>date</code> argument. The group
14971 composition is unchanged when the chimp is older than
14972 &gmi_min_alone_age; old, and also unchanged if the mother is
14973 already in the group composition. The mother added must be in
14974 the study population as of the supplied date. When there are
14975 multiple (in-study) adoptive parents the most recent adopter, on
14976 or prior to the supplied date, is added to the group
14977 composition, regardless of the presence or absence of other
14978 parents in the group composition.</para>
14979
14980 <para><function>mom_in_gc</function>
14981 calls <function><xref linkend="infants_in_gc"/></function> on
14982 the added mother to ensure that young infants are in the group
14983 composition with their mothers.</para>
14984
14985 <caution>
14986 <para>This function does not check it's arguments. It assumes
14987 that the supplied date is the date of the supplied group
14988 composition and that the supplied chimpid is in the supplied
14989 group composition.</para>
14990 </caution>
14991
14992 <para>When inserting a <xref linkend="RAW_GROUPMEMBERS"/> row
14993 the <xref linkend="Raw_Groupmembers-ChimpID"/> value used is the
14994 <xref linkend="BIOGRAPHY_DATA"/>.<xref linkend="Biography_Data-AnimID"/>
14995 of the (biological or adoptive) mother, the
14996 <xref linkend="Raw_Groupmembers-Origin"/> value used is
14997 always <literal>&gmi_automatic_origin;</literal>, and the
14998 <xref linkend="Raw_Groupmembers-Uncertain"/> value always
14999 &false;</para>
15000
15001 <para>A &true; value is returned if a row for the mother is
15002 added to <xref linkend="RAW_GROUPMEMBERS"/>, &false; is returned
15003 if not.</para>
15004
15005 </refsection>
15006 </refentry>
15007 </section>
15008 </chapter>
15009
15010 <chapter xml:id="Data-Entry">
15011 <title>Data Entry</title>
15012
15013 <section xml:id="Data-Entry-Overview">
15014 <title>Data Entry Overview</title>
15015
15016 <para>The prototypical way to import data into Gombe-MI is in
15017 bulk, via a plain text file having columns delimited by the tab
15018 character. These are easily produced by almost any spreadsheet
15019 program; it is expected that most data imported into Gombe-MI will
15020 be typed into a spreadsheet and then exported to tab-delimited
15021 text for upload.</para>
15022
15023 <para>Most data are uploaded into Gombe-MI via the
15024 <xref linkend="Upload"/> program, most often directly into
15025 <xref linkend="Views"/>. The &ppa; program's import function can
15026 also be used, although it aborts as soon as it encounters an
15027 error. Data may also be entered row by row directly into the
15028 database, either via the &ppa; web interface, or by entering SQL
15029 into either &ppa; or any other &postgresql; front-end.</para>
15030
15031 <tip>
15032 <para>Typically when uploading data into &postgresql;
15033 encountering an error causes the upload to abort. This can be a
15034 problem when uploading large amounts of data since it results in
15035 a repeated cycle of upload-fix-re-upload. Gombe-MI contains
15036 some bespoke programs that address this issue by attempting to
15037 continue uploading after an error is encountered in order to
15038 deliver back to the user as many errors as possible from a
15039 single upload.</para>
15040
15041 <para>The nature of the data validation built into Gombe-MI has
15042 an impact on the efficient use of these sorts of upload
15043 programs. Data validation occurs in two stages. First, as much
15044 validation as possible takes place as each row is inserted into
15045 each table. This phase of the data validation process is called
15046 here, for lack of a better term, <quote>before commit</quote>
15047 data validation. The second phase of data validation occurs
15048 once all the data has been inserted into the database. In this
15049 phase additional validation occurs to check for consistency
15050 throughout the data as a whole. This second phase of data
15051 validation is called here the <quote>on commit</quote> data
15052 validation phase.</para>
15053
15054 <para>The two phases of data validation can be distinguished by
15055 the errors messages they produce. <quote>Before commit</quote>
15056 data validation error messages do not contain the
15057 phrase <quote>on commit</quote> in their text, <quote>on
15058 commit</quote> error messages do contain this phrase.</para>
15059
15060 <para>The upload programs can recover and continue to upload
15061 additional rows if a data validation error is found during the
15062 <quote>before commit</quote> phase of data validation. In this
15063 case it can be beneficial to upload large files in order to
15064 produce large numbers of error messages and minimize the number
15065 of upload-fix-re-upload cycles.</para>
15066
15067 <para>However once the data is clean enough that the upload
15068 program ceases to produce <quote>before commit</quote> error
15069 messages, once the <quote>on commit</quote> validation phase has
15070 been entered, only a single error message at a time can be
15071 returned. Encountering an error during the <quote>on
15072 commit</quote> validation phase always immediately aborts the
15073 upload. When the data is clean enough that only <quote>on
15074 commit</quote> errors are returned then it can be beneficial to
15075 upload small files in order to reduce the amount of time it
15076 takes to produce an error and increase the speed of the
15077 upload-fix-re-upload cycle.</para>
15078 </tip>
15079
15080 <para>Gombe-MI contains a minimal number
15081 of <link linkend="The-Gombe-MI-Custom-Programs">bespoke
15082 programs</link>. Some few of these programs are utility in
15083 nature: a program to logout, a program to automate the steps
15084 involved in the creation of a new database user, and so forth.
15085 Most of the data entered into Gombe-MI is collected in tabular,
15086 row-and-column, format suitable for entry into a relational
15087 database. As mentioned previously, this data can be imported
15088 directly.<!-- The purpose of most of the bespoke Gombe-MI programs
15089 is to transform data files, as part of the data upload process,
15090 from the formats easily collected in the field into a tabular
15091 format.--></para>
15092
15093 <para>Most errors in computer data entry can be caught by the
15094 wwwdiff program. This program compares files. Typos are
15095 detected by entering the data twice, preferably by 2 different
15096 people, and comparing the result. Errors made in the field are
15097 more likely to be detected by manual checks of the data, or by
15098 the data validation built into Gombe-MI.</para>
15099 </section>
15100
15101 <section xml:id="Automatically-Generated-Ids">
15102 <title>Automatically Generated IDs</title>
15103
15104 <para>The system will automatically generate id columns whenever
15105 a new row is inserted and an id column is not supplied. When an
15106 id value is supplied the system does not check to see that it is
15107 indeed the next id in sequence, nor does it update the sequence
15108 number to be automatically supplied the next time a row is
15109 inserted without an id column. Should an id value be manually
15110 supplied, it may be necessary to update the internal id counter
15111 so that future system generated ids will not conflict with an id
15112 already used.</para>
15113
15114 <para>See the <link
15115 xlink:href="http://www.postgresql.org/docs/">PostgreSQL
15116 documentation</link> section on <link
15117 xlink:href="http://www.postgresql.org/docs/&pgrelease;/interactive/functions-sequence.html">sequence
15118 functions</link> for reference material on the requisite
15119 &postgresql; functions.</para>
15120
15121 <tip>
15122 <para>Don't supply id values manually unless you know what
15123 your doing.</para>
15124 </tip>
15125
15126 <para>Automatically generated ids are not guaranteed to be
15127 contiguous.</para>
15128 </section>
15129 </chapter>
15130
15131 <chapter xml:id="The-Gombe-MI-Custom-Programs">
15132 <title>The Gombemi-MI Custom Programs</title>
15133
15134 <para>To reduce cost the number of custom programs are minimal.</para>
15135
15136 <section xml:id="Data-Maintenance-Programs">
15137 <title>Data Maintenance Programs</title>
15138
15139 <para>These are the programs that are used in the entry and
15140 maintenance of the Gombe-MI Master tables. Their use should be
15141 fully documented elsewhere in manuals describing how the system is
15142 used when performing specific tasks. The summary written here
15143 provides a statement of purpose and a mention of all updated
15144 data. The operation and behavior of the programs supports the
15145 table and program characteristics documented in this manual. For
15146 more information on the actual capabilities of the programs see
15147 the documentation in the programs' source code.</para>
15148
15149 <para>Some programs are designed to upload data in
15150 <quote>batch</quote> -- each run of a program uploads a single
15151 file containing multiple lines of data, each of which is then
15152 inserted into the database as a row of data in one (or
15153 more<footnote>
15154
15155 <para>Uploading into a single row of a view can update
15156 multiple tables, and programs designed to handle specialized
15157 input data formats may update arbitrary portions of the
15158 database as needed.</para>
15159
15160 </footnote>) database tables. Other programs provide
15161 utility functions.</para>
15162
15163 <para>The upload programs take as input a file of data
15164 arranged in tabular format. The file is expected to contain
15165 plain text, with rows on separate lines and columns separated by
15166 a single tab character. This data structure can be produced by
15167 exporting data from a spreadsheet as tab delimited text.</para>
15168
15169 <para>The programs upload the data into the database in an
15170 all-or-nothing fashion. Ether all the data in a uploaded file
15171 is inserted into the database or, should any error occur, none
15172 of it is. After an error each program continues to process the
15173 uploaded file so as to catch additional errors. However the
15174 input line containing the erroneous data is ignored so the
15175 <quote>trial</quote><footnote>
15176
15177 <para>Once an error occurs no changes will be committed to
15178 the database.</para>
15179
15180 </footnote> insertion into the database of the subsequent lines
15181 in the uploaded file may result in spurious errors due to the
15182 <quote>missing</quote> data. It is left to the operator to
15183 distinguish the real errors from the false positives.</para>
15184
15185 <tip>
15186 <para>When in doubt simply correct the errors that are clearly
15187 problems, notably the first error reported, and re-run the
15188 program.</para>
15189 </tip>
15190
15191 <tip>
15192 <para>For reasons of security most browsers will remove
15193 pathnames from forms. Should a program which imports data
15194 into Gombe-MI from a file find an error in the data, rather than
15195 re-enter the pathname of the file to be uploaded simply press
15196 the browser's &quot;reload&quot; button. This (usually,
15197 depending on the browser) redoes the upload using the
15198 previously entered file name -- but with the new,
15199 now-corrected, data content.</para>
15200 </tip>
15201
15202 <para>Each time any of the Gombe-MI web programs successfully
15203 uploads a file into a database Gombe-MI remembers the name of the
15204 file and the database. The Gombe-MI programs raise an error to
15205 warn a user who has upload a file of the same name into the same
15206 database twice in a row. Re-uploading a third time overrides the
15207 warning, allowing the re-upload to complete.</para>
15208
15209 <para>For more information on whether data is required to
15210 present, as well as other required characteristics of the data
15211 values, see the documentation of the specific column into which
15212 the data is stored.</para>
15213
15214 <section xml:id="UPLOAD_BEHAVIORS-program" xreflabel="UPLOAD_BEHAVIORS">
15215 <title>UPLOAD_BEHAVIORS: View to upload follow data</title>
15216
15217 <para>The <xref linkend="UPLOAD_BEHAVIORS"/> view takes the place
15218 of a custom web-based upload program. The
15219 <xref linkend="Upload"/> program can be used to insert data into
15220 this view and thence into the various follow related
15221 tables.</para>
15222 </section>
15223
15224 <section xml:id="Upload" xreflabel="Upload">
15225 <title>Upload: Upload Into Any Table or View</title>
15226
15227 <para><link xlink:href="&programsurl;/upload/">Upload</link>
15228 uploads data into any table or view. Its primary purpose is to
15229 report as many data errors as possible during a single
15230 upload.<footnote>
15231
15232 <para>Many other upload facilities will abort on the first
15233 error.</para>
15234
15235 <para>Upload also provides an assured way to upload into
15236 views. At the time of this writing most &postgresql; front
15237 ends are unable to import data into views, although this is in
15238 the process of being addressed.</para>
15239
15240 </footnote></para>
15241 <section>
15242 <title>Table and Column Names</title>
15243 <tip>
15244 <para>The name of the table uploaded into may be qualified with a
15245 schema name to upload data into tables or views that are not in
15246 the gombemi schema.</para>
15247 </tip>
15248
15249 <para>Both the table name, entered into the web browser, and the
15250 column names, appearing as column headings in the uploaded file,
15251 are taken exactly as written. Capital characters, spaces, or
15252 other unusual characters are taken exactly as written. This is
15253 in contrast to typical occurrences of table and column names
15254 within &postgresql; SQL statements, where such identifiers are
15255 normalized and automatically converted to lower case. The Upload
15256 program can therefore insert into tables with unusual names or
15257 columns, at the cost of being persnickety about table and column
15258 names.</para>
15259
15260 <para>The one exception to the above rule is that when the
15261 Upload program is told to trim leading and trailing spaces from
15262 the data in each uploaded column. In this case leading and
15263 trailing spaces are also trimmed from the column names
15264 appearing in the first line of the uploaded file.</para>
15265 </section>
15266
15267 <section>
15268 <title>Trim Leading and Trailing Spaces</title>
15269
15270 <para>The upload program has a checkbox which determines
15271 whether or not it removes (<quote>trims</quote>) leading and
15272 trailing spaces from each uploaded datum -- from each column of
15273 each row in the uploaded file.</para>
15274 </section>
15275
15276 <section>
15277 <title>&null; Values</title>
15278
15279 <para>There are 2 ways to upload &null; data values. The easiest
15280 is to omit the column. Columns without some other default value
15281 will be given &null; values. The second is to check the checkbox
15282 labeled &quot;Upload NULL Values&quot; and supply a input value
15283 for &null;. Data values that match the given &null;
15284 representation will then be given a &null; value in the
15285 database.</para>
15286
15287 <para>The default &null; representation is the empty string, no
15288 data at all. When this representation is used (and the
15289 &quot;Upload NULL Values&quot; checkbox is checked) data that are
15290 omitted in the input file becomes &null; when uploaded into the
15291 database.</para>
15292
15293 <tip>
15294 <para><literal>\N</literal> is sometimes used to represent the
15295 &null; value.</para>
15296 </tip>
15297
15298 <caution>
15299 <para>A space (or multiple spaces) may be chosen as the &null;
15300 representation. This can be difficult to discern while
15301 operating the program.</para>
15302 </caution>
15303 </section>
15304
15305 <section xml:id="upload-input">
15306 <title>Upload Data Input Format</title>
15307
15308 <para>The uploaded data must be in either CSV or tab delimited
15309 format. When in tab delimited format the first line of the
15310 input file must contain the column names, each separated by a
15311 tab. The remaining lines of the file contain the data to be
15312 uploaded. Each line is a row of data, each column is separated
15313 from its neighbor with a tab character.</para>
15314
15315 <caution>
15316 &csv_description;
15317 </caution>
15318
15319 <para>A line need not contain as many data elements as there
15320 are column names given in the first line. All unspecified data
15321 elements will be given a blank value, the empty string, just as
15322 if, with tab delimited data, the tabs occurred but no data were
15323 specified.<footnote>
15324
15325 <para>This may or may not result in a &null; value in the
15326 database, depending on how the program is invoked.</para>
15327
15328 </footnote>
15329 </para>
15330
15331 <para>A line must not have more data elements than
15332 there are column names given in the first line.</para>
15333 </section>
15334 </section>
15335
15336 <section xml:id="Upload_GC" xreflabel="Upload_GC">
15337 <title>Upload_GC: Upload Group Composition Data</title>
15338
15339 <para>The Upload_GC program uploads group composition data into
15340 the database. The program creates rows in the
15341 <xref linkend="RAW_GROUPS"/> and
15342 <xref linkend="RAW_GROUPMEMBERS"/> tables and the database
15343 itself then creates the necessary rows in
15344 <xref linkend="GROUPS"/> and
15345 <xref linkend="GROUPMEMBERS"/>.</para>
15346
15347 <caution>
15348 <para>Upload_GC
15349 calls <link linkend="mom_in_gc"><code>mom_in_gc()</code></link>,
15350 <link linkend="infants_in_gc"><code>infants_in_gc()</code></link>,
15351 and
15352 <link linkend="add_social_partners"><code>add_social_partners()</code></link>
15353 on the uploaded follows. Use of any other means to add group
15354 composition data to the database or modify group composition
15355 data can result in failure to meet the assurances provided by
15356 the aforementioned functions.</para>
15357
15358 <para>One way to correctly approach such <quote>manual</quote>
15359 group composition alterations is to alter the group
15360 composition in the database, delete all the
15361 <xref linkend="RAW_GROUPMEMBERS"/> rows having an
15362 <xref linkend="Raw_Groupmembers-Origin"/> value
15363 of <literal>&gmi_automatic_origin;</literal>, and then
15364 re-run <link linkend="mom_in_gc"><code>mom_in_gc()</code></link>,
15365 <link linkend="infants_in_gc"><code>infants_in_gc()</code></link>,
15366 and
15367 <link linkend="add_social_partners"><code>add_social_partners()</code></link>
15368 on the altered follows.</para>
15369 </caution>
15370
15371 <para>There must be no existent information on an uploaded
15372 follow's group composition in the database.<footnote>
15373
15374 <para>This is due to the need to call the aforementioned
15375 functions. Uploading a single follow's group composition in
15376 multiple uploads would result in incorrect group composition
15377 inference.</para>
15378
15379 </footnote></para>
15380
15381 <section xml:id="upload_gc-input">
15382 <title>Upload_GC Data Input Format</title>
15383
15384 <para>The uploaded data must be in either CSV or Tab delimited
15385 format (each column separated from the next by a tab
15386 character). Leading and trailing spaces are removed from the
15387 data contained in each column before any other processing is
15388 performed.</para>
15389
15390 &csv_description;
15391
15392 <para>The overall layout of the uploaded data is similar to
15393 that of the data sheet collected in the field, described in the
15394 &gcdbh;. The first line of the file contains column headings
15395 and each of the remaining lines contains the group composition
15396 recorded for a given time interval of a specified
15397 follow.</para>
15398
15399 <para>All of the group composition information related to a
15400 follow must be in contiguous lines of the uploaded file. There
15401 must be no group composition information of a different follow
15402 interspersed among the lines which comprise any follow's group
15403 composition data.</para>
15404
15405 <para>The first line of the file, as mentioned, contains the
15406 column headings. Column headings may appear in any order.
15407 There are 2 kinds of column headings, those to which the
15408 program assigns specific uses and those which represent
15409 <xref linkend="ChimpIDs-ChimpID"/>s.</para>
15410
15411 <para>All non-<xref linkend="ChimpIDs-ChimpID"/> columns,
15412 unless otherwise noted, are required. Character case is
15413 significant, unless otherwise noted, both in column headings
15414 and elsewhere. Although the
15415 non-<xref linkend="ChimpIDs-ChimpID"/> columns listed below are
15416 shown in mixed-case<footnote>
15417
15418 <para>For legibility and for consistency in style with the
15419 manner in which other column names are written in this
15420 document.</para>
15421
15422 </footnote> in the uploaded file all of these column headings
15423 must be lower case.</para>
15424 </section>
15425
15426 <section xml:id="Upload_GC-Columns">
15427 <title>Upload_GC non-ChimpID Columns</title>
15428
15429 <informaltable frame="topbot">
15430
15431 <tgroup cols="3" colsep="0" rowsep="0">
15432 <colspec colnum="3" rowsep="1"/>
15433 <thead>
15434 <row rowsep="1">
15435 <entry>Column</entry>
15436 <entry>Description</entry>
15437 <entry>Purpose</entry>
15438 </row>
15439 </thead>
15440
15441 <tbody>
15442 <row xml:id="Upload_GC-Researcher" xreflabel="Researcher">
15443 <entry>Researcher</entry>
15444
15445 <entry>The <xref linkend="PEOPLE"/>.Descr value
15446 identifying the field researcher who collected the
15447 data. The comparison is done in a case-insensitive
15448 fashion.</entry>
15449
15450 <entry>One of the columns which must match (the
15451 <xref linkend="FIELDFOLLOWS"/>.<xref
15452 linkend="Fieldfollows-Collector"/>
15453 value) when determining the follow to which the group
15454 composition belongs.</entry>
15455 </row>
15456
15457 <row xml:id="Upload_GC-Date" xreflabel="Date">
15458 <entry>Date</entry>
15459
15460 <entry>The date of the follow. The date may be
15461 formatted in any manner acceptable to
15462 &postgresql;.</entry>
15463
15464 <entry>One of the columns which must match (the
15465 <xref linkend="FOLLOWS"/>.<xref linkend="Follows-Date"/>
15466 value) when determining the follow to which the group
15467 composition belongs.</entry>
15468 </row>
15469
15470 <row xml:id="Upload_GC-Mother" xreflabel="Mother">
15471 <entry>Mother</entry>
15472
15473 <entry>A <xref linkend="ChimpIDs-ChimpID"/> of the
15474 mother in the follow.</entry>
15475
15476 <entry>
15477 <para>One of the columns which must match (the
15478 <xref linkend="FOLLOWPARTS"/>.<xref
15479 linkend="Followparts-ChimpID"/>
15480 value in the row identifying the chimp who is the
15481 mother in the follow) when determining the follow to
15482 which the group composition belongs.</para>
15483
15484 <para>The supplied <xref linkend="ChimpIDs-ChimpID"/>
15485 must match exactly the value recorded in the
15486 <xref linkend="FOLLOWPARTS"/>.<xref
15487 linkend="Followparts-ChimpID"/> of the
15488 row identifying the chimp who is the mother in
15489 the follow. Other <xref linkend="ChimpIDs-ChimpID"/>s
15490 which the mother may have are not allowed.</para>
15491 </entry>
15492 </row>
15493
15494 <row xml:id="Upload-GC-Page" xreflabel="Page">
15495 <entry>Page</entry>
15496
15497 <entry>The page number written on the field data
15498 collection sheet recording the group
15499 composition.</entry>
15500
15501 <entry>One of the columns which must match
15502 (<xref linkend="SHEETS"/>.<xref linkend="Sheets-Page"/>)
15503 when determining the follow to which the group
15504 composition belongs. The uploaded value must be blank
15505 when the page numbers on the sheets were not entered
15506 into the database -- when the
15507 <xref linkend="SHEETS"/>.<xref linkend="Sheets-Page"/>
15508 value of the follow is &null;.</entry>
15509 </row>
15510
15511 <row xml:id="Upload_GC-Time_On_Sheet" xreflabel="Time_On_Sheet">
15512 <entry>Time_On_Sheet</entry>
15513
15514 <entry>The time of the group comp as it was written on
15515 the data entry sheet.</entry>
15516
15517 <entry>The value entered into this column is ignored.
15518 The presence of this column in the uploaded file is
15519 optional.</entry>
15520 </row>
15521
15522 <row xml:id="Upload_GC-Time_Converted_Mil"
15523 xreflabel="Time_Converted_Mil">
15524 <entry>Time_Converted_Mil</entry>
15525
15526 <entry>The time of the group composition, written in
15527 military time form.</entry>
15528
15529 <entry>The time value used in the
15530 <xref linkend="RAW_GROUPS"/>. <xref linkend="Raw_Groups-Time"/>
15531 column, and consequently the value used to relate the
15532 group composition to the intervals during which
15533 behavioral data was collected. Although defined by
15534 protocol to be military time the program will accept a
15535 time value formatted in any manner acceptable to
15536 &postgresql;.</entry>
15537 </row>
15538
15539 <row xml:id="Upload_GC-Time_Type" xreflabel="Time_Type">
15540 <entry>Time_Type</entry>
15541
15542 <entry>The time encoding scheme used when the data was
15543 collected in the field.</entry>
15544
15545 <entry>The value entered into this column is
15546 ignored.</entry>
15547 </row>
15548
15549 <row xml:id="Upload_GG-Entered" xreflabel="Entered">
15550 <entry>Entered</entry>
15551
15552 <entry>Whether or not the group comp information was
15553 entered into the MS Access version of the
15554 database.</entry>
15555
15556 <entry>The value entered into this column is ignored.
15557 The presence of this column in the uploaded file is
15558 optional.</entry>
15559 </row>
15560
15561 <row xml:id="Upload_GC-GCStatus" xreflabel="GCStatus">
15562 <entry>GCStatus</entry>
15563
15564 <entry>The status code assigned to the group
15565 composition information collected on the follow, per
15566 field researcher who collected the information.</entry>
15567
15568
15569 <entry>The value to record in the
15570 <xref linkend="FIELDFOLLOWS"/>.<xref
15571 linkend="Fieldfollows-GCStatus"/>
15572 column. All of the uploaded GCStatus values for a
15573 given follow for a given field researcher must
15574 match.</entry>
15575 </row>
15576
15577 <row xml:id="Upload_GC-&gmi_animid_baboon;"
15578 xreflabel="&gmi_animid_baboon;">
15579 <entry>&gmi_animid_baboon;</entry>
15580
15581 <entry>A column for recording baboon presence.</entry>
15582
15583 <entry>Unlike regular
15584 <xref linkend="ChimpIDs-ChimpID"/> columns this column
15585 may never contain information on paracallosal
15586 swelling.</entry>
15587 </row>
15588
15589 <row xml:id="Upload_GC-Blank" xreflabel="Blank">
15590 <entry></entry>
15591
15592 <entry>An entirely empty column.</entry>
15593
15594 <entry>For purposes of visual formatting the uploaded
15595 file may, but is not required to, contain (at most) a
15596 single column that contains no data what so
15597 ever.</entry>
15598 </row>
15599 </tbody>
15600 </tgroup>
15601 </informaltable>
15602
15603 <para>All column headings not listed above are expected to be
15604 valid <xref linkend="ChimpIDs-ChimpID"/> values. The entries
15605 in the rows for the <xref linkend="ChimpIDs-ChimpID"/> columns
15606 must contain values found in
15607 <xref linkend="GC_TRANS"/>.<xref linkend="GC_Trans-Mark"/>.
15608 When the mark indicates that the individual identified in the
15609 column heading is present a row is created in the
15610 <xref linkend="RAW_GROUPMEMBERS"/> table.<footnote>
15611
15612 <para>The database then, in turn, creates a
15613 <xref linkend="GROUPMEMBERS"/> row.</para>
15614 </footnote></para>
15615
15616 <tip>
15617 <para>The <xref linkend="GC_TRANS"/> table should contain a
15618 row having a <xref linkend="GC_Trans-Mark"/> value which is
15619 the empty string (a blank value) because the group
15620 composition sheet collected in the field uses a blank to
15621 indicate absence.</para>
15622 </tip>
15623
15624 <note>
15625 <para>A <xref linkend="ChimpIDs-ChimpID"/> column heading is
15626 not tested for validity unless at least one of marks
15627 contained in the column indicates presence in the
15628 group.</para>
15629 </note>
15630
15631 <para>At least one <xref linkend="ChimpIDs-ChimpID"/> column
15632 must exist in the uploaded file.</para>
15633
15634 </section>
15635 </section>
15636
15637 <section xml:id="Logout" xreflabel="logout">
15638 <title>Logout: Logout From Gombe-MI Custom Programs</title>
15639
15640 <para>The <link xlink:href="&programsurl;/logout/">logout</link>
15641 program logs the user out of the Gombe-MI web based collection of
15642 programs.</para>
15643
15644 <note>
15645 <para>Gombe-MI consists of many programs, only some of which are
15646 web based programs written specifically for Gombe-MI. The
15647 logout program only controls access to those programs written
15648 specifically for Gombe-MI, other <quote>off the shelf</quote>
15649 programs (notably &ppa;) have their own logout
15650 mechanisms.</para>
15651 </note>
15652
15653 <note>
15654 <para>Logout from Gombe-MI is automatic after a period of
15655 inactivity.<footnote>
15656
15657 <para>Currently 1 hour.</para>
15658 </footnote></para>
15659 </note>
15660 </section>
15661
15662 <section xml:id="Wwwdiff" xreflabel="Wwwdiff">
15663 <title>Wwwdiff: World Wide Web based Difference program</title>
15664
15665 <para>The <link xlink:href="&programsurl;/wwwdiff/">wwwdiff</link>
15666 program compares two text files. It can be found on the
15667 &gombemiwebsite;.</para>
15668
15669 <para>Among other uses, this program provides a useful data
15670 validation mechanism. To validate data, have two different
15671 individuals enter the data and compare the results with the
15672 wwwdiff program. It is unlikely that both individuals will make
15673 identical errors and so almost all data transcription errors
15674 should be caught using this method.</para>
15675
15676 <tip>
15677 <para>The program uploads the two files to be compared. For
15678 security reasons most web browsers will always clear the names
15679 of the uploaded files once they have been uploaded. This makes
15680 it difficult to repeatedly upload the same or similar files, as
15681 when re-comparing two files after correcting errors. The
15682 situation is not as bad as it might sound because browsers will
15683 often provide a
15684 <quote>browse</quote> button and keep track of the directory
15685 last accessed, removing the need to re-navigate to the location
15686 of the data files. But it is still awkward to have to
15687 repeatedly point and click.</para>
15688
15689 <para>One solution is to use the browser's
15690 <quote>reload</quote> button. This will repeat the upload and
15691 comparison of the two files, but using the new, corrected, file
15692 content. A second, less desirable possibility is to have the
15693 have the pathnames of the files handy in a text document and cut
15694 and paste them as needed. A third possibility might be to use
15695 the browser's
15696 <quote>back</quote> button, but browsers will often clear the
15697 file upload information in this case in the same fashion they
15698 would with password information.</para>
15699 </tip>
15700
15701 <para>The wwwdiff program provides 4 comparison methods:
15702 <variablelist>
15703 <varlistentry>
15704 <term>Tabular by Word</term>
15705
15706 <listitem>
15707 <para>Useful where the data consists of individual words
15708 aligned as rows and columns of data. Compares the files
15709 contents on a word-by-word basis and displays the entire
15710 content of both files as a table with differences
15711 marked.</para>
15712
15713 <caution>
15714 <para>When one file contains whitespace<footnote>
15715
15716 <para>Spaces, tabs, and whatever other
15717 characters that can't been seen.</para>
15718
15719 </footnote> that is not in the other, this comparison
15720 method shows extra cells in the output. Words are
15721 separated by whitespace but because there
15722 is <emphasis>only</emphasis> extra whitespace the cells
15723 are empty. Thus, when one file contains more whitespace
15724 than the other those rows will contain more columns.
15725 Normally the data in the extra cells would be color
15726 coded to inform as to whence they came, but because the
15727 cells are empty there is nothing to color code. The
15728 operator must compare the files by hand to determine
15729 which file contains the extra whitespace.</para>
15730 </caution>
15731
15732 </listitem>
15733 </varlistentry>
15734
15735 <varlistentry>
15736 <term>By Word</term>
15737
15738 <listitem>
15739 <para>Useful where the data consists of words and there
15740 are relatively few changes or where paragraphs have been
15741 refilled and words have moved from line to line. Compares
15742 the file contents on a word-by-word basis displaying the
15743 entire content of both files as plain text.</para>
15744 </listitem>
15745 </varlistentry>
15746
15747 <varlistentry>
15748 <term>By Line</term>
15749
15750 <listitem>
15751 <para>Useful when there is a large amount of textual data.
15752 Compares the file contents on a line-by-line basis and
15753 displays only a small amount of context surrounding those
15754 portions of the text which differ between the
15755 files.</para>
15756 </listitem>
15757 </varlistentry>
15758
15759 <varlistentry>
15760 <term>By File</term>
15761
15762 <listitem>
15763 <para>Useful when comparing non-text files. Reports the
15764 location (by line and byte offset from the beginning of
15765 the files) of the first difference found.</para>
15766 </listitem>
15767 </varlistentry>
15768
15769 </variablelist></para>
15770 </section>
15771 </section>
15772
15773 <section xml:id="System-Management-Programs">
15774 <title>System Management Programs</title>
15775
15776 <para>The programs in this section are of use to the
15777 administrators that manage the system. These programs require
15778 login be done using a username having administrative authority.
15779 These programs automatically logout upon completion; usernames
15780 and passwords must be re-entered each invocation.</para>
15781
15782 <section xml:id="Add_User">
15783 <title>Add_User: Create a database user</title>
15784
15785 <para>The Add_User program provides a convenient way to add
15786 database users, users who have access to the database. This
15787 program is something of a non-essential convenience, as it's
15788 possible to do everything the Add_User program does with SQL
15789 statements. Add_User provides a convenient web interface which
15790 adds a user, constructs an initial password, creates a private
15791 schema for the user in both the <literal>gombemi</literal> and
15792 the <literal>gombemi_test</literal> databases, and gives the new
15793 user appropriate permissions to database content.</para>
15794
15795 <note>
15796 <para>Every person should have their own username. Usernames
15797 (and passwords) should never be shared.</para>
15798 </note>
15799
15800 <para>Either ordinary database usernames
15801 or <link linkend="Administrative-Users">administrative
15802 usernames</link> may be created. Ordinary usernames have either
15803 read-only access to the <literal>gombemi</literal> schema or
15804 read/write access to the <literal>gombemi</literal> schema.
15805 Ordinary users always have read/write access to their own
15806 private schemas. For further information see:
15807 <xref linkend="roles"/></para>
15808
15809 <para>Only administrative logins (administrative users) can
15810 create new users.</para>
15811
15812 <caution>
15813 <para>Passwords should not be known to anyone but the person
15814 to whom the username belongs. Once given the initial password
15815 by the administrator who created the username, the person
15816 receiving the new username/password should immediately replace
15817 the password by one of their own choosing. This can be done
15818 with &ppa; or manually via the <command>ALTER ROLE</command>
15819 SQL statement.</para>
15820 </caution>
15821
15822 <warning>
15823 <para>People who have administrative privileges to the
15824 database should have separate usernames for ordinary and
15825 administrative use. Ordinary use of the database should be
15826 done with a non-administrative login to avoid the risk of
15827 accidental database destruction.<footnote>
15828
15829 <para>You know the rule: <quote>With great power comes
15830 great responsibility.</quote></para>
15831
15832 </footnote></para>
15833
15834 <para><link linkend="Administrative-Users">Administrative
15835 users</link> have the permissions necessary to do great
15836 damage. Enable those permissions only at need.</para>
15837 </warning>
15838
15839 <para>All usernames are created in lower case. Leading and
15840 trailing spaces are removed.</para>
15841
15842 <para>When a new username is created the program generates a
15843 password and reports the generated password. If the generated
15844 password is lost a new password must be manually assigned to the
15845 user in &ppa;.</para>
15846
15847 <tip>
15848 <para>Reassignment of a
15849 username's <link linkend="roles">database role</link> (whether
15850 the username is a member of <xref linkend="gombemi_readers"/>
15851 or <xref linkend="gombemi_editors"/>) can be done either with
15852 the SQL <code>GRANT ROLE</code> and <code>DROP ROLE</code>
15853 statements or via the administrative facilities of
15854 &ppa;.<footnote>
15855
15856 <para>Either way the operation must be performed by
15857 an <link linkend="Administrative-Users">Administrative
15858 user</link>.</para>
15859 </footnote></para>
15860 </tip>
15861
15862 </section>
15863
15864 <section xml:id="Copy_Schema" xreflabel="Copy_Schema">
15865 <title>Copy_Schema: Copy Schemas Between Databases</title>
15866
15867 <para>The Copy_Schema program copies schemas between databases.
15868 The schema and all it's content is copied. Permissions are
15869 preserved.</para>
15870
15871 <para>An <link linkend="Administrative-Users">administrative
15872 login</link> must be used to copy a schema between
15873 databases.</para>
15874
15875 <para>The Copy_Schema interface has 2 checkboxs that control
15876 it's behavior:
15877
15878 <itemizedlist>
15879 <listitem>
15880 <para>Copy_Schema will not copy a schema on top of an
15881 existing schema of the same name, destroying the
15882 original schema in the target database, unless
15883 explicitly asked to do so.</para>
15884 </listitem>
15885
15886 <listitem>
15887 <para>Copy_Schema will not alter
15888 the <literal>gombemi</literal> database, potentially
15889 destroying production data, unless explicitly asked to do
15890 so.</para>
15891 </listitem>
15892 </itemizedlist>
15893 </para>
15894
15895 <note>
15896 <para>It can take some time, depending on the size of the
15897 schema to copy and the size of the target database, to copy a
15898 schema. Expect execution times that may be in the 10s of
15899 minutes.</para>
15900 </note>
15901
15902 <para>The Copy_Schema program performs a <command>VACUUM
15903 ANALYZE</command> on the target database, which contributes to
15904 the amount of time it takes to perform the copy.</para>
15905
15906 </section>
15907 </section>
15908 </chapter>
15909
15910 <appendix>
15911 <title>Restrictions: Things Not To Do</title>
15912
15913 <para>Using the <code>SET CONSTRAINTS</code> statement to change
15914 the timing of constraints can reduce Gombe-MI's functionality.
15915 Constraints must be checked when expected for the proper operation
15916 of the system.</para>
15917
15918 <para>Many data integrity checks are not performed on truncate.
15919 Do not truncate the tables.</para>
15920 </appendix>
15921
15922
15923 <xi:include
15924 href="transactions.xml"
15925 xmlns:xi="http://www.w3.org/2001/XInclude"/>
15926
15927 <appendix xml:id="one_minute_interval_assumptions">
15928 <title>One Minute Interval Assumptions</title>
15929
15930 <para>There are some elements of the Gombe-MI system which assume
15931 that the follows have a 1 minute interval duration. This appendix
15932 documents these system elements.</para>
15933
15934 <itemizedlist>
15935 <listitem>
15936 <para>The test for non-overlapping follow intervals.</para>
15937 </listitem>
15938
15939 <listitem>
15940 <para>The test which requires that a mother's offspring who
15941 are less than &gmi_min_alone_age; old be with the mother in
15942 the group composition survey relies on all intervals being the
15943 same duration when checking whether the offspring is with a
15944 different (adopted) mother.</para>
15945 </listitem>
15946 </itemizedlist>
15947 </appendix>
15948
15949 <xi:include
15950 href="warnings.xml"
15951 xmlns:xi="http://www.w3.org/2001/XInclude"/>
15952
15953 <xi:include
15954 href="fdlv13-db50_1.xml"
15955 xmlns:xi="http://www.w3.org/2001/XInclude"/>
15956
15957 <xi:include
15958 href="gplv3-db50_1.xml"
15959 xmlns:xi="http://www.w3.org/2001/XInclude"/>
15960
15961 </book>