[TW5] TiddlyMap: visualise imported data

672 views
Skip to first unread message

UBi

unread,
Jul 22, 2015, 6:58:55 AM7/22/15
to TiddlyWiki
Hi!

I discovered TiddlyMap recently. Great piece of work, thank you, Felix!
I started using it the way described in the introductory videos, e.g. entering/developing dependency networks directly with the UI provided.

Now I'm wondering if there is a way to visualise data imported from, say, JSON or CSV files.

As long as the relationship between Tiddlers is pure TiddlyWiki functionality, it works as expected. Importing the following JSON file yields the two nodes "Tiddler" and "Glossar", nicely linked with a "tagged with" edge.

[
    {
        "text": "kleinste sinnvolle Texteinheit",
        "tags": "Glossar",
        "title": "Tiddler"
    },
    {
        "text": "TiddlyWiki-Begriffe",
        "title": "Glossar",
        "tags": ""
    }
]

But what if I wand to import Tiddler relations like "uses" or "related to"?
How would I have to write my JSON file?

Thanks,
Uwe

Felix Küppers

unread,
Jul 22, 2015, 7:41:05 AM7/22/15
to TiddlyWiki
Hi Uwe,


I discovered TiddlyMap recently. Great piece of work, thank you, Felix!

Thanks :)
 
But what if I wand to import Tiddler relations like "uses" or "related to"?
How would I have to write my JSON file?

To answer your question: there are two possibilites for that:

1) The simple way: Use magic edge-type namespaces

In the docs section, have a look at Magic Edge-Type Namespaces.

You need to go to the edge-type manager and create the edge-types first!
Then you can enter tiddler titles into custom fields to have them displayed as edges in graphs.
Make sure you read about the drawbacks of this technique in the docs article above!

2) The advanced way: Create a "tmap.edges" field for edges in each tiddler that holds outgoing edges.

In the docs section, have a look at "Storage of Edges" (http://tiddlymap.org/#Storage%20of%20Edges).
Just export a tiddler as ".tid" file after you created some outgoing edges and you'll see how the tiddlymap edges are stored in JSON format.

The same way you could do it if you don't want to use the gui...

Maybe have a look at this github discussion "How to link tiddlers progragmatically" (https://github.com/felixhayashi/TW5-TiddlyMap/issues/141)

--------------

Hope this helps

-Felix

PMario

unread,
Jul 22, 2015, 8:42:17 AM7/22/15
to TiddlyWiki
On Wednesday, July 22, 2015 at 1:41:05 PM UTC+2, Felix Küppers wrote:
Hope this helps

An example JSON, that could be drag and drop imported imo would help a lot ;)

-mario

UBi

unread,
Jul 22, 2015, 9:58:49 AM7/22/15
to TiddlyWiki
Bittesehr:

[
   
{ "title": "$:/plugins/felixhayashi/tiddlymap/graph/edgeTypes/tw-list:child-of" },
   
{ "title": "$:/plugins/felixhayashi/tiddlymap/graph/edgeTypes/tw-list:sibling-of" },
   
{ "title": "$:/plugins/felixhayashi/tiddlymap/graph/edgeTypes/tw-list:parent-of" },
   
{ "title": "$:/plugins/felixhayashi/tiddlymap/graph/edgeTypes/tw-list:married-with" },
   
{
       
"title": "Tom",
       
"married-with": "Tina",
       
"parent-of": "Timmy Tamara",
       
"tags": "Family"
   
},
   
{
       
"title": "Tina",
       
"married-with": "Tom",
       
"parent-of": "Timmy Tamara",
       
"tags": "Family"
   
},
   
{
       
"title": "Timmy",
       
"child-of": "Tom Tina",
       
"sibling-of": "Tamara",
       
"tags": "Family"
   
},
   
{
       
"title": "Tamara",
       
"child-of": "Tom Tina",
       
"sibling-of": "Timmy",
       
"tags": "Family"
   
}
]


A small, working genealogy example :-)

In my use case, edge types are known in advance, so the simple way suffices. Phew! No UUID mess :-)

Thanks again!

Uwe

Felix Küppers

unread,
Jul 22, 2015, 11:02:19 AM7/22/15
to tiddl...@googlegroups.com

> A small, working genealogy example :-)

Now that is a highly connected graph! I like that all Names start with
"T" :)

> In my use case, edge types are known in advance, so the simple way
> suffices.

Glad you also figured out how to include the edge-types in your json!

> Phew! No UUID mess :-)

To be honest, you are not forced to use UUID when using the advanced
tiddlymap edge-format. The only criterion is that you ensure edge and
node ids are and will be unique.

Just be aware of the fact that when using magic edge-types a title
change will result in broken connections when any tiddlers were linked
to this tiddler.

-Felix

UBi

unread,
Jul 22, 2015, 11:32:44 AM7/22/15
to TiddlyWiki
Thank you for your kind comments.

My intention is to import a programmatically created JSON file describing the object relationships in a BI environment, so uniqueness is granted. Hopefully, since I still have yet to write that program :-) I'm very anxious about how TiddlyMap will handle those hundreds of nodes.

Speaking of mass node display: is there a way to assign nodes to groups? It would be nice to see related nodes clustered in a way. In my genealogy example, I could think of relatives grouped by country :-)

Thanks again,
Uwe

Danielo Rodríguez

unread,
Jul 23, 2015, 3:40:50 AM7/23/15
to TiddlyWiki, u...@kefc.de


El miércoles, 22 de julio de 2015, 17:32:44 (UTC+2), UBi escribió:
Thank you for your kind comments.

My intention is to import a programmatically created JSON file describing the object relationships in a BI environment, so uniqueness is granted. Hopefully, since I still have yet to write that program :-) I'm very anxious about how TiddlyMap will handle those hundreds of nodes.

Speaking of mass node display: is there a way to assign nodes to groups? It would be nice to see related nodes clustered in a way. In my genealogy example, I could think of relatives grouped by country :-)

Thanks again,
Uwe

There was also a "search" feature that have been removed. I miss it a lot for some scenarios. 

Felix Küppers

unread,
Jul 23, 2015, 1:25:48 PM7/23/15
to tiddl...@googlegroups.com
Hi Uwe

> My intention is to import a programmatically created JSON file
> describing the object relationships in a BI environment, so uniqueness
> is granted.

Thanks for sharing the intention with me.

> Hopefully, since I still have yet to write that program :-) I'm very
> anxious about how TiddlyMap will handle those hundreds of nodes.

Well, if you visualize a lot of data in a single, TiddlyMap might crash
or become slow :D, you may need to do some adjustments, but we can talk
about that when it is necessary.

Generally speaking, if graphs are large and also highly connected,
everything is too twisted and complex to have a good overview (unless
your graph has a snowflake structure).

Anyhow, this is just my personal experience, I would be curious how
things work out for you. So in case you can share the result or the
experience, please do so here or on GitHub.

> Speaking of mass node display: is there a way to assign nodes to
> groups? It would be nice to see related nodes clustered in a way. In
> my genealogy example, I could think of relatives grouped by country :-)

Yes, vis.js supports clustering but I did not manage to implement this
for TiddlyMap yet. It's on my agenda but it might take a while.

-Felix

Felix Küppers

unread,
Jul 23, 2015, 2:11:22 PM7/23/15
to tiddl...@googlegroups.com
Hi Danielo,

just insert these two tiddlers and you'll have the search again.

-Felix
--
You received this message because you are subscribed to the Google Groups "TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/e87177ae-18fb-4915-a9f3-a8cd40c4375f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

$--Graph search.tid
view.search.tid

Felix Küppers

unread,
Jul 23, 2015, 2:13:45 PM7/23/15
to TiddlyWiki, u...@kefc.de, rdan...@gmail.com
$--Graph search.tid
view.search.tid

Danielo Rodríguez

unread,
Jul 24, 2015, 2:17:30 AM7/24/15
to TiddlyWiki
Thank you very much Felix! Any chance to include them as individual files in the github repo?

Felix Küppers

unread,
Jul 24, 2015, 5:08:09 AM7/24/15
to tiddl...@googlegroups.com

> Thank you very much Felix!

No problemo

> Any chance to include them as individual files in the github repo?

Hmm, yes, I could do that. I could also add an option that
enables/disables the search (disabled per default with a warning that it
is not good and still experimental).

myfta

unread,
Mar 2, 2020, 5:02:09 PM3/2/20
to TiddlyWiki
Can I re-open this topic? It's probably me as a noobie and misunderstanding the principles here. 

I would like to be able to create these TiddlyMap links automatically and not dependent on the tiddler name rather the UUID. In the OP it's referred to as the "Advanced way" but I cannot get it to work. Would someone be able to write a suitable sample json so I can see how it is intended to work or explain if I have just got it wrong!?

Thanks
Reply all
Reply to author
Forward
0 new messages