Announcement

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

  • variable question

    Hi everyone. I have a data set with questions on a Likert scale. so I assigned the categorical variables numbers with their corresponding categories labeled. I.E. sometimes (3), often (4), nearly always (5). Then I created a new variable that sums two of these answers, but it's giving me incorrect sums. Any idea why this may be or what I can do about it?

  • #2
    It really depends on what you mean with "it is giving me incorrect results".
    If you post an excerpt of your data (using dataex), and describe in detailed the problem you think you are facing, then it would be easier to provide some advice.

    Comment


    • #3
      It seems so simple. I want to create a new variable that's just a summation of two other variables (they were categorical but I changed them to numeric with labels) and the totals I'm getting are wrong. And I'm sorry, I'm not familiar with dataex.

      Comment


      • #4
        It indeed seems simple to you, because you can see your data, and you can see your code, and you can see your results. We can see none of those, and without seeing them, have no hope of telling you what you need to change in the code we cannot see so that when its used on data we have not seen it will produce the answer you expect but have not shared with us.

        Please take a few moments to review the Statalist FAQ linked to from the top of the page, as well as from the Advice on Posting link on the page you used to create your post. Note especially sections 9-12 on how to best pose your question. It's particularly helpful to copy commands and output from your Stata Results window and paste them into your Statalist post using code delimiters [CODE] and [/CODE], and to use the dataex command to provide sample data, as described in section 12 of the FAQ.

        The more you help others understand your problem, the more likely others are to be able to help you solve your problem.

        Section 12.1 is particularly pertinent

        12.1 What to say about your commands and your problem

        Say exactly what you typed and exactly what Stata typed (or did) in response. N.B. exactly!
        ...
        Never say just that something "doesn't work" or "didn't work", but explain precisely in what sense you didn't get what you wanted.

        Comment


        • #5
          Hi Tanya,

          Welcome to Statalist!

          If you're not familiar with dataex (and most Stata users aren't) I created a Youtube tutorial here. (I made it too long--feel free to watch at 2x speed, and you may only need the first 6 minutes) .

          Hope this helps!
          --David

          Comment

          Working...
          X