1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532
|
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
This file shows encodings of character state data.
-->
<!--
For more discussion of the structure of the root element,
refer to 'taxa.xml'
-->
<nex:nexml
version="0.9"
xml:base="http://example.org/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.nexml.org/2009 ../xsd/nexml.xsd"
xmlns:nex="http://www.nexml.org/2009"
xmlns="http://www.nexml.org/2009">
<!--
For more discussion of the structure of the taxa
element, refer to 'taxa.xml'
-->
<otus id="taxa1" label="Primary taxa block">
<otu id="t1" label="Homo sapiens"/>
<otu id="t2" label="Pan paniscus"/>
<otu id="t3" label="Pan troglodytes"/>
<otu id="t4" label="Gorilla gorilla"/>
<otu id="t5" label="Pongo pygmaeus"/>
</otus>
<!--
This characters block encodes restriction site data, i.e.
presence (1) / absence (0) observations. Because the states
that can occur - and what they mean - are known, there is no
'format' element to define states (see below for examples of
that). In this example, restriction site data is encoded
as a sequence of characters (rather than individual cells),
hence we use the subclass xsi:type="RestrictionSeqs".
All characters blocks must have an id attribute and a
reference to a taxa block that precedes it. In addition,
it may have the same additional attributes (label, xml:base,
xml:lang, xml:id, xlink:href and class) as the taxa element.
-->
<characters otus="taxa1" id="m1" xsi:type="nex:RestrictionSeqs" label="Restriction site sequences">
<format>
<states id="RestrictionSiteStateSet">
<state id="Absent" symbol="0"/>
<state id="Present" symbol="1"/>
</states>
<char id="Site1" states="RestrictionSiteStateSet"/>
<char id="Site2" states="RestrictionSiteStateSet"/>
<char id="Site3" states="RestrictionSiteStateSet"/>
<char id="Site4" states="RestrictionSiteStateSet"/>
</format>
<matrix>
<!--
The matrix element is a container for row elements.
-->
<!--
Each row element must have an id and a reference
to a taxon element that precedes it.
-->
<row otu="t1" id="RestrictionSiteRow1">
<!--
Because this characters block is an instance
of the subclass RestrictionSeqs it contains
'seq' elements with 1's and 0's.
-->
<seq>0101</seq>
</row>
<row otu="t2" id="RestrictionSiteRow2">
<seq>0101</seq>
</row>
<row otu="t3" id="RestrictionSiteRow3">
<seq>0101</seq>
</row>
<row otu="t4" id="RestrictionSiteRow4">
<seq>0101</seq>
</row>
<row otu="t5" id="RestrictionSiteRow5">
<seq>0101</seq>
</row>
</matrix>
</characters>
<!--
This characters block encodes 'standard' categorical characters,
marked up granularly, as cells.
-->
<characters otus="taxa1" id="m2" xsi:type="nex:StandardCells" label="Categorical characters">
<!--
Because categorical characters in instances of this subclass
don't have a priori known numbers of states, they must be
defined using the 'format' element.
-->
<format>
<!--
The first elements inside a format element are stateset
definitions. In this example, there is a set of four
states, each tagged with an id. The symbol attribute is
a shorthand token that would be used when serializing to
NEXUS, for example.
-->
<states id="StandardCategoricalStateSet1">
<state id="StandardCategoricalState1" symbol="1"/>
<state id="StandardCategoricalState2" symbol="2"/>
<state id="StandardCategoricalState3" symbol="3"/>
<polymorphic_state_set symbol="4" id="StandardCategoricalState4">
<member state="StandardCategoricalState2"/>
<member state="StandardCategoricalState3"/>
</polymorphic_state_set>
<uncertain_state_set symbol="5" id="StandardCategoricalState5">
<member state="StandardCategoricalState1"/>
<member state="StandardCategoricalState2"/>
</uncertain_state_set>
</states>
<!--
The matrix in this example contains two columns, both
referring to the same stateset - and so cells in both
columns can occupy one of four states.
-->
<char states="StandardCategoricalStateSet1" id="StandardCharacter1"/>
<char states="StandardCategoricalStateSet1" id="StandardCharacter2"/>
</format>
<!--
In this subclass, the matrix contains rows consisting of
individual cells.
-->
<matrix>
<row id="StandardCategoricalStateCellsRow1" otu="t1">
<!--
Each cell must contain a reference to the column
it belongs to, and to a state allowed within that
column.
-->
<cell char="StandardCharacter1" state="StandardCategoricalState1"/>
<cell char="StandardCharacter2" state="StandardCategoricalState2"/>
</row>
<row id="StandardCategoricalStateCellsRow2" otu="t2">
<cell char="StandardCharacter1" state="StandardCategoricalState2"/>
<cell char="StandardCharacter2" state="StandardCategoricalState2"/>
</row>
<row id="StandardCategoricalStateCellsRow3" otu="t3">
<cell char="StandardCharacter1" state="StandardCategoricalState3"/>
<cell char="StandardCharacter2" state="StandardCategoricalState4"/>
</row>
<row id="StandardCategoricalStateCellsRow4" otu="t4">
<cell char="StandardCharacter1" state="StandardCategoricalState2"/>
<cell char="StandardCharacter2" state="StandardCategoricalState3"/>
</row>
<row id="StandardCategoricalStateCellsRow5" otu="t5">
<cell char="StandardCharacter1" state="StandardCategoricalState4"/>
<cell char="StandardCharacter2" state="StandardCategoricalState1"/>
</row>
</matrix>
</characters>
<!--
This example is a characters block for continuous characters, marked
up as individual cells.
-->
<characters otus="taxa1" id="m3" xsi:type="nex:ContinuousCells" label="Continuous characters">
<format>
<!--
Because in this subclass, characters are marked up granularly -
as cells - we must define the columns these cells belong to.
Because this is continuous data, we don't (can't) define the
states cells in these columns may occupy, hence there are no
'states' elements in this subclass.
-->
<char id="ContinuousCharacter1" label="this is character 1"/>
<char id="ContinuousCharacter2"/>
<char id="ContinuousCharacter3"/>
<char id="ContinuousCharacter4"/>
<char id="ContinuousCharacter5"/>
</format>
<matrix>
<row id="ContinuousCellsRow1" otu="t1">
<!--
In this subclass, the 'state' attribute holds the raw
value of the cell (i.e. a floating point number), not
a reference to a state defined previously.
-->
<cell char="ContinuousCharacter1" state="-1.545414144070023"/>
<cell char="ContinuousCharacter2" state="-2.3905621575431044"/>
<cell char="ContinuousCharacter3" state="-2.9610221833467265"/>
<cell char="ContinuousCharacter4" state="0.7868662069161243"/>
<cell char="ContinuousCharacter5" state="0.22968509237534918"/>
</row>
<row id="ContinuousCellsRow2" otu="t2">
<cell char="ContinuousCharacter1" state="-1.6259836379710066"/>
<cell char="ContinuousCharacter2" state="3.649352410850134"/>
<cell char="ContinuousCharacter3" state="1.778885099660406"/>
<cell char="ContinuousCharacter4" state="-1.2580877968480846"/>
<cell char="ContinuousCharacter5" state="0.22335354995610862"/>
</row>
<row id="ContinuousCellsRow3" otu="t3">
<cell char="ContinuousCharacter1" state="-1.5798979984134964"/>
<cell char="ContinuousCharacter2" state="2.9548251411133157"/>
<cell char="ContinuousCharacter3" state="1.522005675256233"/>
<cell char="ContinuousCharacter4" state="-0.8642016921755289"/>
<cell char="ContinuousCharacter5" state="-0.938129801832388"/>
</row>
<row id="ContinuousCellsRow4" otu="t4">
<cell char="ContinuousCharacter1" state="2.7436692306788086"/>
<cell char="ContinuousCharacter2" state="-0.7151148143399818"/>
<cell char="ContinuousCharacter3" state="4.592207937774776"/>
<cell char="ContinuousCharacter4" state="-0.6898841440534845"/>
<cell char="ContinuousCharacter5" state="0.5769509574453064"/>
</row>
<row id="ContinuousCellsRow5" otu="t5">
<cell char="ContinuousCharacter1" state="3.1060827493657683"/>
<cell char="ContinuousCharacter2" state="-1.0453787389160105"/>
<cell char="ContinuousCharacter3" state="2.67416332763427"/>
<cell char="ContinuousCharacter4" state="-1.4045634106692808"/>
<cell char="ContinuousCharacter5" state="0.019890469925520196"/>
</row>
</matrix>
</characters>
<!--
This subclass encodes DNA as sequences (not cells). Like the restriction
site data block shown above, the states are known (being IUPAC single
character nucleotide symbols), hence there is no 'format' element. In
addition to the IUPAC symbols, '-' is used for gaps, '?' is used for
missing. Spaces are allowed (so that long lines can be broken up, some
parsers might otherwise complain) but have no meaning.
-->
<characters otus="taxa1" id="characters3" xsi:type="nex:DnaSeqs" label="DNA sequences">
<format>
<states id="IUPACDNAStateSet1">
<state id="NucA" symbol="A" />
<state id="NucC" symbol="C" />
<state id="NucG" symbol="G" />
<state id="NucT" symbol="T" />
<uncertain_state_set id="SymK" symbol="K">
<member state="NucG" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymM" symbol="M">
<member state="NucA" />
<member state="NucC" />
</uncertain_state_set>
<uncertain_state_set id="SymR" symbol="R">
<member state="NucA" />
<member state="NucG" />
</uncertain_state_set>
<uncertain_state_set id="SymS" symbol="S">
<member state="NucC" />
<member state="NucG" />
</uncertain_state_set>
<uncertain_state_set id="SymW" symbol="W">
<member state="NucA" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymY" symbol="Y">
<member state="NucC" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymB" symbol="B">
<member state="NucC" />
<member state="NucG" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymD" symbol="D">
<member state="NucA" />
<member state="NucG" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymH" symbol="H">
<member state="NucA" />
<member state="NucC" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymV" symbol="V">
<member state="NucA" />
<member state="NucC" />
<member state="NucG" />
</uncertain_state_set>
<uncertain_state_set id="SymN" symbol="N">
<member state="NucA" />
<member state="NucC" />
<member state="NucG" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymX" symbol="X">
<member state="NucA" />
<member state="NucC" />
<member state="NucG" />
<member state="NucT" />
</uncertain_state_set>
<uncertain_state_set id="SymGap" symbol="-" />
<uncertain_state_set id="SymMiss" symbol="?">
<member state="NucA" />
<member state="NucC" />
<member state="NucG" />
<member state="NucT" />
<member state="SymK" />
<member state="SymM" />
<member state="SymR" />
<member state="SymS" />
<member state="SymW" />
<member state="SymY" />
<member state="SymB" />
<member state="SymD" />
<member state="SymH" />
<member state="SymV" />
<member state="SymN" />
<member state="SymX" />
<member state="SymGap" />
</uncertain_state_set>
</states>
<char id="ResidueCol1" states="IUPACDNAStateSet1" />
<char id="ResidueCol2" states="IUPACDNAStateSet1" />
<char id="ResidueCol3" states="IUPACDNAStateSet1" />
<char id="ResidueCol4" states="IUPACDNAStateSet1" />
<char id="ResidueCol5" states="IUPACDNAStateSet1" />
<char id="ResidueCol6" states="IUPACDNAStateSet1" />
<char id="ResidueCol7" states="IUPACDNAStateSet1" />
<char id="ResidueCol8" states="IUPACDNAStateSet1" />
<char id="ResidueCol9" states="IUPACDNAStateSet1" />
<char id="ResidueCol10" states="IUPACDNAStateSet1" />
<char id="ResidueCol11" states="IUPACDNAStateSet1" />
<char id="ResidueCol12" states="IUPACDNAStateSet1" />
<char id="ResidueCol13" states="IUPACDNAStateSet1" />
<char id="ResidueCol14" states="IUPACDNAStateSet1" />
<char id="ResidueCol15" states="IUPACDNAStateSet1" />
<char id="ResidueCol16" states="IUPACDNAStateSet1" />
</format>
<matrix>
<row otu="t1" id="DNASequence1"><seq>A C G C T C G C A T C G C A T C</seq></row>
<row otu="t2" id="DNASequence2"><seq>A C G C T C G C A T C G C A T C</seq></row>
<row otu="t3" id="DNASequence3"><seq>A C G C T C G C A T C G C A T C</seq></row>
</matrix>
</characters>
<!--
RNA only differs from the previous example by using U instead of T
-->
<characters otus="taxa1" id="rnaseqs4" xsi:type="nex:RnaSeqs" label="RNA sequences">
<format>
<states id="rnastates">
<state id="rna1" symbol="A"/>
<state id="rna2" symbol="C"/>
<state id="rna3" symbol="G"/>
<state id="rna4" symbol="U"/>
<uncertain_state_set id="rna5" symbol="K">
<member state="rna3"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna6" symbol="M">
<member state="rna1"/>
<member state="rna2"/>
</uncertain_state_set>
<uncertain_state_set id="rna7" symbol="R">
<member state="rna1"/>
<member state="rna3"/>
</uncertain_state_set>
<uncertain_state_set id="rna8" symbol="S">
<member state="rna2"/>
<member state="rna3"/>
</uncertain_state_set>
<uncertain_state_set id="rna9" symbol="W">
<member state="rna1"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna10" symbol="Y">
<member state="rna2"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna11" symbol="B">
<member state="rna2"/>
<member state="rna3"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna12" symbol="D">
<member state="rna1"/>
<member state="rna3"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna13" symbol="H">
<member state="rna1"/>
<member state="rna2"/>
<member state="rna4"/>
</uncertain_state_set>
<uncertain_state_set id="rna14" symbol="V">
<member state="rna1"/>
<member state="rna2"/>
<member state="rna3"/>
</uncertain_state_set>
<uncertain_state_set id="rna15" symbol="N">
<member state="rna3"/>
<member state="rna1"/>
<member state="rna4"/>
<member state="rna2"/>
</uncertain_state_set>
<uncertain_state_set id="rna16" symbol="X">
<member state="rna3"/>
<member state="rna1"/>
<member state="rna4"/>
<member state="rna2"/>
</uncertain_state_set>
<uncertain_state_set id="rna17" symbol="-"/>
<uncertain_state_set id="rna18" symbol="?">
<member state="rna1"/>
<member state="rna2"/>
<member state="rna3"/>
<member state="rna4"/>
<member state="rna5"/>
<member state="rna6"/>
<member state="rna7"/>
<member state="rna8"/>
<member state="rna9"/>
<member state="rna10"/>
<member state="rna11"/>
<member state="rna12"/>
<member state="rna13"/>
<member state="rna14"/>
<member state="rna15"/>
<member state="rna16"/>
<member state="rna17"/>
</uncertain_state_set>
</states>
<char id="rnachar1" states="rnastates"/>
<char id="rnachar2" states="rnastates"/>
<char id="rnachar3" states="rnastates"/>
<char id="rnachar4" states="rnastates"/>
<char id="rnachar5" states="rnastates"/>
<char id="rnachar6" states="rnastates"/>
<char id="rnachar7" states="rnastates"/>
<char id="rnachar8" states="rnastates"/>
<char id="rnachar9" states="rnastates"/>
<char id="rnachar10" states="rnastates"/>
<char id="rnachar11" states="rnastates"/>
<char id="rnachar12" states="rnastates"/>
<char id="rnachar13" states="rnastates"/>
<char id="rnachar14" states="rnastates"/>
<char id="rnachar15" states="rnastates"/>
<char id="rnachar16" states="rnastates"/>
<char id="rnachar17" states="rnastates"/>
<char id="rnachar18" states="rnastates"/>
<char id="rnachar19" states="rnastates"/>
<char id="rnachar20" states="rnastates"/>
</format>
<matrix>
<row otu="t1" id="rnarow1">
<seq>ACGCUCGCAUCGCAUC</seq>
</row>
<row otu="t2" id="rnarow2">
<seq>ACGCUCGCAUCGCAUC</seq>
</row>
<row otu="t3" id="rnarow3">
<seq>ACGCUCGCAUCGCAUC</seq>
</row>
</matrix>
</characters>
<!--
A more compact example of encoding of continuous characters as raw sequences.
-->
<characters otus="taxa1" id="contchars5" xsi:type="nex:ContinuousSeqs" label="Continuous sequences">
<format>
<char id="contchar1"/>
<char id="contchar2"/>
<char id="contchar3"/>
<char id="contchar4"/>
<char id="contchar5"/>
</format>
<matrix>
<row id="controw1" otu="t1">
<seq>-1.545414144070023 -2.3905621575431044 -2.9610221833467265 0.7868662069161243 0.22968509237534918</seq>
</row>
<row id="controw2" otu="t2">
<seq>-1.6259836379710066 3.649352410850134 1.778885099660406 -1.2580877968480846 0.22335354995610862</seq>
</row>
<row id="controw3" otu="t3">
<seq>-1.5798979984134964 2.9548251411133157 1.522005675256233 -0.8642016921755289 -0.938129801832388</seq>
</row>
<row id="controw4" otu="t4">
<seq>2.7436692306788086 -0.7151148143399818 4.592207937774776 -0.6898841440534845 0.5769509574453064</seq>
</row>
<row id="controw5" otu="t5">
<seq>3.1060827493657683 -1.0453787389160105 2.67416332763427 -1.4045634106692808 0.019890469925520196</seq>
</row>
</matrix>
</characters>
<!--
A more compact example of encoding of standard data. Note that the symbols used here
are integers (also above 9) and so characters must be space-separated. The symbols used
here are the same as the symbol attributes used in characters block m2, earlier.
-->
<characters otus="taxa1" id="standardchars6" xsi:type="nex:StandardSeqs" label="Standard sequences">
<format>
<!--
The first elements inside a format element are stateset
definitions. In this example, there is a set of four
states, each tagged with an id. The symbol attribute is
a shorthand token.
-->
<states id="standardstateset1">
<state id="standardstates1" symbol="1"/>
<state id="standardstates2" symbol="2"/>
<state id="standardstates3" symbol="3"/>
<polymorphic_state_set symbol="4" id="standardstates4">
<member state="standardstates1"/>
<member state="standardstates2"/>
</polymorphic_state_set>
<uncertain_state_set symbol="5" id="standardstates5">
<member state="standardstates3"/>
<member state="standardstates1"/>
</uncertain_state_set>
</states>
<!--
The matrix in this example contains two columns, both
referring to the same stateset - and so cells in both
columns can occupy one of four states.
-->
<char states="standardstateset1" id="standardc1"/>
<char states="standardstateset1" id="standardc2"/>
</format>
<matrix>
<row id="standardr1" otu="t1">
<seq>1 2</seq>
</row>
<row id="standardr2" otu="t2">
<seq>2 2</seq>
</row>
<row id="standardr3" otu="t3">
<seq>3 4</seq>
</row>
<row id="standardr4" otu="t4">
<seq>2 3</seq>
</row>
<row id="standardr5" otu="t5">
<seq>4 1</seq>
</row>
</matrix>
</characters>
</nex:nexml>
|