Note that there are some explanatory texts on larger screens.

plurals
  1. POorganization chart triangle plot
    primarykey
    data
    text
    <p>I would like to create a triangle plot with organization structure (hierarchy) showing the number of employees at each level in different companies. </p> <p>Here is some example data:</p> <pre><code>mylabd &lt;- data.frame (company = rep(c("A", "B", "C"), each = 7), skillsDg = rep(c("Basic", "HighSc", "Undgd", "MAST", "PHD", "EXPD", "EXECT"), 3), number = c(200, 100, 40, 30, 10, 0, 0, 220, 110, 35, 10, 0, 4, 1, 140, 80, 120, 50, 52, 52, 3) ) company skillsDg number 1 A Basic 200 2 A HighSc 100 3 A Undgd 40 4 A MAST 30 5 A PHD 10 6 A EXPD 0 7 A EXECT 0 8 B Basic 220 9 B HighSc 110 10 B Undgd 35 11 B MAST 10 12 B PHD 0 13 B EXPD 4 14 B EXECT 1 15 C Basic 140 16 C HighSc 80 17 C Undgd 120 18 C MAST 50 19 C PHD 52 20 C EXPD 52 21 C EXECT 3 </code></pre> <p>The objective is to reflect how different companies hire different skilled or degree workers. </p> <p>The hypothetical figure is this (although color fill is not perfect). <img src="https://i.stack.imgur.com/F26OM.jpg" alt="enter image description here"> The idea is that the width of line at each stage is proportional and then lines are connected. If there is no category in subsequent level, it will not be connected (like in company B). I couldn't find a program that can do this and neither could figure out. Any idea ? </p> <p>Edit: </p> <p>I do not alot about R, but here is my how my idea is shaping. It divides each line segment into two from a point to make it symetical. The drawn horizontal lines are then connected.</p> <p><img src="https://i.stack.imgur.com/iKaP5.jpg" alt="enter image description here"></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload