+ Reply to Thread
Results 1 to 4 of 4

How do I convert text answers to numeric

  1. #1
    Tonny
    Guest

    How do I convert text answers to numeric

    I want to convert some 'Yes/No' answers into numeric (i.e. Yes=1; No=0).

    These will then be inputted into SPSS.

    How do you convert text to numeric in Excel?

    Thanks in advance

  2. #2
    David McRitchie
    Guest

    Re: How do I convert text answers to numeric

    If you want to convert them in place with no fuss, you can use a
    macro to work off of a selection of cells.

    For a worksheet solution you can insert a new column (helper column)
    the worksheet below is not case sensitive
    =IF(A1="Yes",1,IF(A1="No",0, A1))
    or a variation
    =IF(LEFT(A1,1)="Y",1,IF(LEFT(A1,1)="N",0, A1))

    ---
    HTH,
    David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
    My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
    Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

    "Tonny" <[email protected]> wrote in message news:[email protected]...
    > I want to convert some 'Yes/No' answers into numeric (i.e. Yes=1; No=0).
    >
    > These will then be inputted into SPSS.
    >
    > How do you convert text to numeric in Excel?
    >
    > Thanks in advance




  3. #3
    Ron Rosenfeld
    Guest

    Re: How do I convert text answers to numeric

    On Thu, 29 Sep 2005 02:56:02 -0700, "Tonny" <[email protected]>
    wrote:

    >I want to convert some 'Yes/No' answers into numeric (i.e. Yes=1; No=0).
    >
    >These will then be inputted into SPSS.
    >
    >How do you convert text to numeric in Excel?
    >
    >Thanks in advance


    For a formula:

    =--(A1="yes")

    will give a result of 1 for Yes and 2 for No.


    --ron

  4. #4
    Dave Peterson
    Guest

    Re: How do I convert text answers to numeric

    One more...

    Select the range to fix:
    edit|Replace
    what: Yes
    with: 1
    replace all

    do the similar thing for No.

    Tonny wrote:
    >
    > I want to convert some 'Yes/No' answers into numeric (i.e. Yes=1; No=0).
    >
    > These will then be inputted into SPSS.
    >
    > How do you convert text to numeric in Excel?
    >
    > Thanks in advance


    --

    Dave Peterson

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1