Created
April 2, 2013 12:42
-
-
Save weidagang/5291910 to your computer and use it in GitHub Desktop.
graphviz probability tree
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generate image by: dot -Tpng -o probability_tree.png probability_tree.dot | |
digraph probability_tree { | |
s [label=""] | |
male [label="男"] | |
female [label="女"] | |
y1 [label="穿凉鞋"] | |
y2 [label="穿凉鞋"] | |
n1 [label="不穿凉鞋"] | |
n2 [label="不穿凉鞋"] | |
s -> male [label="2/3"]; | |
s -> female [label="1/3"]; | |
male -> y1 [label="1/2"]; | |
male -> n1 [label="1/2"]; | |
female -> y2 [label="2/3"]; | |
female -> n2 [label="1/3"]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment