forked from jdf/processing-py-site
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathTable.xml
More file actions
44 lines (31 loc) · 1.02 KB
/
Table.xml
File metadata and controls
44 lines (31 loc) · 1.02 KB
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
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<root>
<name>Table</name>
<category>Data</category>
<subcategory>Composite</subcategory>
<type></type>
<example>
<code><![CDATA[
def setup():
table = Table()
table.addColumn("id")
table.addColumn("species")
table.addColumn("name")
newRow = table.addRow()
newRow.setInt("id", table.lastRowIndex())
newRow.setString("species", "Panthera leo")
newRow.setString("name", "Lion")
saveTable(table, "data/new.csv")
# Sketch saves the following to a file called "new.csv":
# id,species,name
# 0,Panthera leo,Lion
]]></code>
</example>
<description><![CDATA[
<b>Table</b> objects store data with multiple rows and columns, much like in a traditional spreadsheet. Tables can be generated from scratch, dynamically, or using data from an existing file. Tables can also be output and saved to disk, as in the example above.
]]></description>
<type>class</type>
<related>loadTable</related>
<related>saveTable</related>
<related>TableRow</related>
</root>