Page 1 of 1

can I use dada.catart with any database?

Posted: Fri Oct 12, 2018 11:00 am
by tremblap
Hello

My formated table has the instantiation message at loadtime:
addtable segments (start f) (duration f) (energy f) (pitch f) (centroid f) (spread f)

I can fill the dada.base object fine, but I don't seem to be able to connect it to the dada.catart object. I tried to analyse the help patch but I get querying errors...

I presume I'm missing a step here, but I cannot find a tutorial yet ;-)

thanks for any pointer.

Re: can I use dada.catart with any database?

Posted: Fri Oct 12, 2018 3:22 pm
by tremblap
Thanks to Hans's help,I found out i needed to change the contentfield of dada.catart to something that was actually in my database otherwise I got many unhappy max messages ;-)

Re: can I use dada.catart with any database?

Posted: Fri Oct 12, 2018 4:26 pm
by danieleghisi
Hi,

you are right... No tutorial yet :)

You should define *at least* the attributes setting the database, the table name, the xfield the yfield and the content field (= which columns are output upon click/hover/etc.). These attributes are all in the "basic" tab.

Once you do that, you are connected :)

d

Re: can I use dada.catart with any database?

Posted: Sat Oct 13, 2018 7:50 am
by tremblap
indeed this is what I found out.

Can you give me such a troubleshooting list for the dada.distance visualiser? I saw you have a subpatch that computes the distances first... that is where I stalled but I'll give it another shot!

Re: can I use dada.catart with any database?

Posted: Mon Oct 15, 2018 2:12 pm
by danieleghisi
Hi, dada.distances pretty much in the same way, except that instead of the x/y fields you need to define both an element table and a distance table.
The basic concept is explained in the "distance table" tab of the [dada.base] help file.

The idea is that you have a database, say DB and you define a table (say CITIES, with a unique field, say, "name"), and a distance table (via "adddistancetable", say DISTS), and then you add distance entries. A distance table is a special kind of table (well, it's a super normal SQL table, only it is interpreted differently by dada) that only has as values distances between elements of some other table.

If your table CITIES has

NAME
Rome
Paris
London

you can send messages for each couple of cities such as
adddistanceentry DB CITIES NAME Rome Paris 1421
adddistanceentry DB CITIES NAME Rome London 1873
adddistanceentry DB CITIES NAME Paris London 1421

Then you can display it in dada.distances, plugging in in the inspector DB as database, CITIES as table and DISTS as distance table.

Hope this helps...
Daniele