Comments (9)
Please try the latest release (0.0.3). It appears to work for me.
https://github.com/mdaines/viz.js/releases/tag/0.0.3
from viz-js.
It doesn't work anymore.
The only version usable is used by the website http://www.webgraphviz.com/
from viz-js.
Paste the following code at the bottom of example.html, right after 'document.body.innerHTML += example("cluster", "xdot");':
data = "digraph G {" +
"16 -> 4;" +
"16 -> 8;" +
"16 -> 20;" +
"16 -> 24;" +
"16 -> 32; "+
"20 -> 32;" +
"}";
var svg = Viz(data, "svg");
document.body.innerHTML += svg;
It works for me, producing
Looks like you are using Viz function wrong, since the second parameter specifies the output format, and the third one ("dot" by default) is optional.
from viz-js.
I want to use "dot" in output format and it doesn't generate the positions.
When i use "svg" in output format, it generate the positions, i agree with that.
So what's wrong?
from viz-js.
Input:
"digraph G {
graph[layout=dot];
16 -> 4;
16 -> 8;
16 -> 20;
16 -> 24;
16 -> 32;
20 -> 32;
}"
Output (with latest release):
"digraph G {
graph [layout=dot];
node [label="\N"];
16 [height=
pos=
width=;
4 [height=
pos=
width=;
16 -> 4 [pos="��������;
8 [height=
pos=
width=;
16 -> 8 [pos="��������;
20 [height=
pos=
width=;
16 -> 20 [pos="��������;
24 [height=
pos=
width=;
16 -> 24 [pos="��������;
32 [height=
pos=
width=;
16 -> 32 [pos="��������������;
20 -> 32 [pos="��������;
}
"
Output (with webgraphviz website):
"digraph G {
graph [layout=dot];
node [label="\N"];
graph [bb="0,0,283.94,180"];
16 [pos="171,162", width="0.75", height="0.5"];
4 [pos="27,90", width="0.75", height="0.5"];
8 [pos="99,90", width="0.75", height="0.5"];
20 [pos="171,90", width="0.75", height="0.5"];
24 [pos="243,90", width="0.75", height="0.5"];
32 [pos="234,18", width="0.75", height="0.5"];
16 -> 4 [pos="e,48.335,101.37 149.75,150.67 125.4,138.83 85.281,119.33 57.572,105.86"];
16 -> 8 [pos="e,113.8,105.38 156.43,146.83 146.25,136.94 132.48,123.55 120.97,112.36"];
16 -> 20 [pos="e,171,108.1 171,143.7 171,135.98 171,126.71 171,118.11"];
16 -> 24 [pos="e,228.2,105.38 185.57,146.83 195.75,136.94 209.52,123.55 221.03,112.36"];
16 -> 32 [pos="e,249.8,32.675 196.75,156.43 222.61,150.31 261.1,136.72 279,108 292.94,85.628 274.38,58.387 257.05,39.982"];
20 -> 32 [pos="e,220.66,33.824 184.36,74.155 192.88,64.689 204.09,52.238 213.69,41.563"];
}
"
from viz-js.
I have updated the GitHub pages branch to 0.0.3, as it was behind, and added an form similar to the one you linked to:
http://mdaines.github.io/viz.js/form.html
Please try the graph you posted on that page.
from viz-js.
Works for me. @MilWolf what browser and version are you using? I have tested it with Chromium 33.0.1750.152 Ubuntu 13.10 (256984) and Firefox 28.0.
from viz-js.
It works for me too.
I generate the graph with this code:
//generate digraph
this.digraph="digraph G {\n";
this.digraph+="graph[layout=dot];\n";
for(edge in edges){
this.digraph+=edges[edge].startVertex.id;
this.digraph+=" -> ";
this.digraph+=edges[edge].endVertex.id;
this.digraph+=";\n";
}
this.digraph+="}";
//generate dot file
var dotFile = Viz(this.digraph, "dot");
who give me the outputs above, so i think the problem is my code, but it doesn't appear with the release on the website http://www.webgraphviz.com/ .
I use chrome 26.0.1410.63 with fedora 64 bit.
from viz-js.
I redownloaded the latest release again and now it works.
I don't understand what i did because i tried again and again.
So i can clause the issue.
Congratulations for your job and thank you for helped me.
from viz-js.
Related Issues (20)
- Add type definitions HOT 4
- Publish lang-dot package
- Figure out why pkg-config doesn't work as expected for Expat
- Investigate distributing a non-WASM build
- Investigate support for separate WebAssembly instantiation
- Support -x (reduce) option
- Image support in v3 HOT 6
- RuntimeError with long label starting with newline HOT 1
- Android Project HOT 1
- Types can not be imported with current package.json HOT 2
- Dynamic font Family HOT 2
- Strict mode but merge labels HOT 1
- Text not rendering in nodes HOT 11
- Question about usage without Webassembly and some other questions HOT 1
- I need to remove tooltip i.e title for entire graph. How can it be done HOT 4
- Having trouble with new image support - can't use same image URL in two different places HOT 3
- Positions will never change HOT 3
- DockerFile uses Expat 2.5.0 which is vulnerable for CVE-2023-52425 HOT 2
- Different Results with same Graph HOT 2
- Status of the viz-js OSS project HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from viz-js.