Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Sorting variables in bar char

    Dear Statalist,

    I am trying to sort the medians of a variable descending, using command : graph hbar (median) GR, over(COUNTRY, sort(GR) descending) blabel(bar)
    but it doesn't seem to work perfectly.. ( i have attached a print screen). Nevertheless, there won't be a problem when variable is sorted descending by mean.
    Could you please give me a clue?

    Thank you very much.
    V.P


    Attached Files

  • #2
    The FAQ Advice explains that Word attachments are deprecated. As suggested there, please post graphs as .png attachments.

    Comment


    • #3
      Looking at the output of help hbar suggests that the following is necessary to sort by the median value of GR.
      Code:
      graph hbar (median) GR, over(COUNTRY, sort((median) GR) descending) blabel(bar)

      Comment


      • #4
        Thank you for your help.

        Comment

        Working...
        X